[PATCH v2] mtd: gpmi: Fix NULL pointer dereference
Brian Norris
computersforpeace at gmail.com
Mon Nov 11 21:51:17 EST 2013
On Mon, Nov 11, 2013 at 6:47 PM, Brian Norris
<computersforpeace at gmail.com> wrote:
> On Mon, Nov 11, 2013 at 6:31 PM, Huang Shijie <b32955 at freescale.com> wrote:
>> 于 2013年11月12日 03:13, Fabio Estevam 写道:
>> In actually, this patch only fixes partial of the bug.
>>
>> When we login the rootfs, and erase all the mtd partitions, and reboot
>> the mx23 again,
>> you will meet a NULL pointer too. Why? because the
>> mx23_write_transcription_stamp() will work
>> again.
>
> But how is this reboot situation a different case? As far as the
> kernel is concerned, this reboot would be the same as any other
> boot...
>
> What NULL pointer are you talking about for this reboot case? AFAICT,
> the only identified NULL pointer was on the 'buffer' in
> mx23_write_transcription_stamp(), and Fabio's patch ensures that this
> buffer points to a proper memory region. So where's your NULL pointer?
I'm sorry, I just read Huang's response to the other patch, and I
realized I was mixing up mx23_check_transcription_stamp() and
mx23_write_transcription_stamp(). So Huang has a valid point: this
patch is incorrect. I'll resume discussion on Huang's version of this
patch.
Brian
More information about the linux-mtd
mailing list