From: martin.blumenstingl@googlemail.com (Martin Blumenstingl)
To: linus-amlogic@lists.infradead.org
Subject: patch "iio: adc: meson-saradc: use NULL instead of 0 for pointer" added to staging-testing
Date: Mon, 26 Jun 2017 23:03:16 +0200 [thread overview]
Message-ID: <CAFBinCBzh_EsvjQk+wtbwkvA6+pgnkhCjWfcftf7dxqL-Bcf7w@mail.gmail.com> (raw)
In-Reply-To: <7D7489FD-BA5C-4AA0-B490-8EDA86ADC339@jic23.retrosnub.co.uk>
On Mon, Jun 26, 2017 at 9:30 PM, Jonathan Cameron
<jic23@jic23.retrosnub.co.uk> wrote:
>
>
> On 26 June 2017 19:57:18 BST, Martin Blumenstingl <martin.blumenstingl@googlemail.com> wrote:
>>Hi Greg, Hi Jonathan,
>>
>>On Mon, Jun 26, 2017 at 7:09 AM, <gregkh@linuxfoundation.org> wrote:
>>>
>>> This is a note to let you know that I've just added the patch titled
>>>
>>> iio: adc: meson-saradc: use NULL instead of 0 for pointer
>>>
>>> to my staging git tree which can be found at
>>> git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
>>> in the staging-testing branch.
>>>
>>> The patch will show up in the next release of the linux-next tree
>>> (usually sometime within the next 24 hours during the week.)
>>>
>>> The patch will be merged to the staging-next branch sometime soon,
>>> after it passes testing, and the merge window is open.
>>>
>>> If you have any questions about this process, please let me know.
>>is there a way to drop below patch from your repo?
>>during testing I found out that the code before and after this patch
>>leads to a NULL deref. I provided a fix (see [0]) which solves the
>>crash and the warning as reported by Paolo - and that fix is already
>>part of v4.12-rc6
>>so the patch below will cause a merge conflict
>
> Sorry my mess up. Will probably fall out in the wash or Greg could revert. Will have to check
> the merge resolution in Linux next and when Linus pulls if it isn't reverted. Should be fine
> either way.
OK, I will re-check this once the everything has landed in Linus' tree
actually it's me who made the mess (by implementing broken stuff in
the first place) - but it will all be fine!
> Jonathan
>>
>>> From 6b503b216d1eff4d61a0bc34e09d1fd4d6e0ee79 Mon Sep 17 00:00:00
>>2001
>>> From: Paolo Cretaro <paolocretaro@gmail.com>
>>> Date: Sun, 28 May 2017 13:24:38 +0200
>>> Subject: iio: adc: meson-saradc: use NULL instead of 0 for pointer
>>>
>>> Fix sparse warning: Using plain integer as NULL pointer
>>>
>>> Signed-off-by: Paolo Cretaro <paolocretaro@gmail.com>
>>> Acked-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
>>> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
>>> ---
>>> drivers/iio/adc/meson_saradc.c | 2 +-
>>> 1 file changed, 1 insertion(+), 1 deletion(-)
>>>
>>> diff --git a/drivers/iio/adc/meson_saradc.c
>>b/drivers/iio/adc/meson_saradc.c
>>> index 81cd39a57fe3..fb3f67a9ae1f 100644
>>> --- a/drivers/iio/adc/meson_saradc.c
>>> +++ b/drivers/iio/adc/meson_saradc.c
>>> @@ -481,7 +481,7 @@ static void meson_sar_adc_clear_fifo(struct
>>iio_dev *indio_dev)
>>> if (!meson_sar_adc_get_fifo_count(indio_dev))
>>> break;
>>>
>>> - regmap_read(priv->regmap, MESON_SAR_ADC_FIFO_RD, 0);
>>> + regmap_read(priv->regmap, MESON_SAR_ADC_FIFO_RD,
>>NULL);
>>> }
>>> }
>>>
>>> --
>>> 2.13.1
>>>
>>>
>>
>>Regards,
>>Martin
>>
>>[0]
>>http://lists.infradead.org/pipermail/linux-amlogic/2017-June/003863.html
>
> --
> Sent from my Android device with K-9 Mail. Please excuse my brevity.
next prev parent reply other threads:[~2017-06-26 21:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <14984537865458@kroah.com>
2017-06-26 18:57 ` patch "iio: adc: meson-saradc: use NULL instead of 0 for pointer" added to staging-testing Martin Blumenstingl
2017-06-26 19:30 ` Jonathan Cameron
2017-06-26 21:03 ` Martin Blumenstingl [this message]
2017-06-27 6:43 ` Greg KH
2017-06-28 20:12 ` Martin Blumenstingl
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAFBinCBzh_EsvjQk+wtbwkvA6+pgnkhCjWfcftf7dxqL-Bcf7w@mail.gmail.com \
--to=martin.blumenstingl@googlemail.com \
--cc=linus-amlogic@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).