diff for duplicates of <20140611144141.GH3429@piout.net> diff --git a/a/1.txt b/N1/1.txt index ea8abb1..e3b4573 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -35,11 +35,11 @@ Also, tested on an at91sam9g45ek. > @@ -528,15 +527,16 @@ static u8 at91_adc_get_trigger_value_by_name(struct iio_dev *idev, > return -ENOMEM; > -> if (strcmp(trigger_name, name) = 0) { +> if (strcmp(trigger_name, name) == 0) { > - value = triggers[i].value; > kfree(name); > - break; -> + if (triggers[i].value = 0) +> + if (triggers[i].value == 0) > + return -EINVAL; > + return triggers[i].value; > } @@ -63,7 +63,7 @@ Also, tested on an at91sam9g45ek. > value = at91_adc_get_trigger_value_by_name(idev, > st->trigger_list, > idev->trig->name); -> - if (value = 0) +> - if (value == 0) > - return -EINVAL; > + if (value < 0) > + return value; diff --git a/a/content_digest b/N1/content_digest index 68d4bd4..89110f0 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -2,7 +2,7 @@ "ref\020140611081317.GA29444@mwanda\0" "From\0Alexandre Belloni <alexandre.belloni@free-electrons.com>\0" "Subject\0Re: [patch v2] iio: adc: at91: signedness bug in at91_adc_get_trigger_value_by_name()\0" - "Date\0Wed, 11 Jun 2014 14:41:41 +0000\0" + "Date\0Wed, 11 Jun 2014 16:41:41 +0200\0" "To\0Dan Carpenter <dan.carpenter@oracle.com>\0" "Cc\0Jonathan Cameron <jic23@kernel.org>" Grant Likely <grant.likely@linaro.org> @@ -55,11 +55,11 @@ "> @@ -528,15 +527,16 @@ static u8 at91_adc_get_trigger_value_by_name(struct iio_dev *idev,\n" "> \t\t\treturn -ENOMEM;\n" "> \n" - "> \t\tif (strcmp(trigger_name, name) = 0) {\n" + "> \t\tif (strcmp(trigger_name, name) == 0) {\n" "> -\t\t\tvalue = triggers[i].value;\n" "> \t\t\tkfree(name);\n" "> -\t\t\tbreak;\n" - "> +\t\t\tif (triggers[i].value = 0)\n" + "> +\t\t\tif (triggers[i].value == 0)\n" "> +\t\t\t\treturn -EINVAL;\n" "> +\t\t\treturn triggers[i].value;\n" "> \t\t}\n" @@ -83,7 +83,7 @@ "> \tvalue = at91_adc_get_trigger_value_by_name(idev,\n" "> \t\t\t\t\t\t st->trigger_list,\n" "> \t\t\t\t\t\t idev->trig->name);\n" - "> -\tif (value = 0)\n" + "> -\tif (value == 0)\n" "> -\t\treturn -EINVAL;\n" "> +\tif (value < 0)\n" "> +\t\treturn value;\n" @@ -96,4 +96,4 @@ "Embedded Linux, Kernel and Android engineering\n" http://free-electrons.com -733c6ec4eef5ae12c1214bdcad3a04d445cdb57b3be1800d055a49be3ee5ed71 +9402c8af735520f0afb71a7ec709dcfd6f1cf8e142799f4fe12f39c85fb760db
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.