Thread (2 messages) 2 messages, 2 authors, 2014-02-26

Re: [PATCH 2/3] NFC: trf7970a: Add ISO/IEC 15693 Support

From: "Mark A. Greer" <mgreer@animalcreek.com>
Date: 2014-02-26 21:53:32
Also in: linux-devicetree

On Fri, Feb 21, 2014 at 02:00:44AM +0100, Samuel Ortiz wrote:
Hi Mark,

Just one nitpick here:
quoted
+static int trf7970a_is_iso15693_write_or_lock(u8 cmd)
+{
+	int ret;
+
+	switch (cmd) {
+	case ISO15693_CMD_WRITE_SINGLE_BLOCK:
+	case ISO15693_CMD_LOCK_BLOCK:
+	case ISO15693_CMD_WRITE_MULTIPLE_BLOCK:
+	case ISO15693_CMD_WRITE_AFI:
+	case ISO15693_CMD_LOCK_AFI:
+	case ISO15693_CMD_WRITE_DSFID:
+	case ISO15693_CMD_LOCK_DSFID:
+		ret = 1;
return 1;

and return 0 on the default case.
Simpler code and you don't need the ret variable.
OK
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help