* Re: [PATCH] firmware/dmi_scan: Drop OOM messages [not found] <1373460424.4399.45.camel@chaos.site> @ 2013-07-10 14:51 ` Joe Perches 2013-07-10 16:17 ` Jean Delvare 0 siblings, 1 reply; 3+ messages in thread From: Joe Perches @ 2013-07-10 14:51 UTC (permalink / raw) To: Jean Delvare; +Cc: linux-kernel, Ben Hutchings, Andrew Morton even more trivial... On Wed, 2013-07-10 at 14:47 +0200, Jean Delvare wrote: > +++ linux-3.11-rc0/drivers/firmware/dmi_scan.c 2013-07-10 14:11:56.544792703 +0200 > @@ -62,8 +62,6 @@ static const char * __init dmi_string(co > str = dmi_alloc(len); > if (str != NULL) [] > @@ -219,10 +217,8 @@ static void __init dmi_save_one_device(i > dev = dmi_alloc(sizeof(*dev) + strlen(name) + 1); > + if (!dev) > return; [] > @@ -258,10 +254,8 @@ static void __init dmi_save_oem_strings_ > dev = dmi_alloc(sizeof(*dev)); > + if (!dev) > break; [] > @@ -277,18 +271,14 @@ static void __init dmi_save_ipmi_device( > data = dmi_alloc(dm->length); > + if (data == NULL) > return; [] > dev = dmi_alloc(sizeof(*dev)); > + if (!dev) > return; [] > @@ -303,10 +293,9 @@ static void __init dmi_save_dev_onboard( > onboard_dev = dmi_alloc(sizeof(*onboard_dev) + strlen(name) + 1); > + if (!onboard_dev) > return; It'd also be nice to use the same test style in all 6 uses. if (!foo) ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] firmware/dmi_scan: Drop OOM messages 2013-07-10 14:51 ` [PATCH] firmware/dmi_scan: Drop OOM messages Joe Perches @ 2013-07-10 16:17 ` Jean Delvare 2013-07-10 17:36 ` Joe Perches 0 siblings, 1 reply; 3+ messages in thread From: Jean Delvare @ 2013-07-10 16:17 UTC (permalink / raw) To: Joe Perches; +Cc: linux-kernel, Ben Hutchings, Andrew Morton Hi Joe, Le Wednesday 10 July 2013 à 07:51 -0700, Joe Perches a écrit : > even more trivial... > > On Wed, 2013-07-10 at 14:47 +0200, Jean Delvare wrote: > > +++ linux-3.11-rc0/drivers/firmware/dmi_scan.c 2013-07-10 14:11:56.544792703 +0200 > > @@ -62,8 +62,6 @@ static const char * __init dmi_string(co > > str = dmi_alloc(len); > > if (str != NULL) > [] > > @@ -219,10 +217,8 @@ static void __init dmi_save_one_device(i > > dev = dmi_alloc(sizeof(*dev) + strlen(name) + 1); > > + if (!dev) > > return; > [] > > @@ -258,10 +254,8 @@ static void __init dmi_save_oem_strings_ > > dev = dmi_alloc(sizeof(*dev)); > > + if (!dev) > > break; > [] > > @@ -277,18 +271,14 @@ static void __init dmi_save_ipmi_device( > > data = dmi_alloc(dm->length); > > + if (data == NULL) > > return; > [] > > dev = dmi_alloc(sizeof(*dev)); > > + if (!dev) > > return; > [] > > @@ -303,10 +293,9 @@ static void __init dmi_save_dev_onboard( > > onboard_dev = dmi_alloc(sizeof(*onboard_dev) + strlen(name) + 1); > > + if (!onboard_dev) > > return; > > It'd also be nice to use the same test style > in all 6 uses. > > if (!foo) Both styles are used throughout the file, and checkpatch doesn't complain. Unifying the coding style is beyond the scope of my patchset, sorry. Feel free to send a patch on top of mine if you really care. -- Jean Delvare Suse L3 ^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] firmware/dmi_scan: Drop OOM messages 2013-07-10 16:17 ` Jean Delvare @ 2013-07-10 17:36 ` Joe Perches 0 siblings, 0 replies; 3+ messages in thread From: Joe Perches @ 2013-07-10 17:36 UTC (permalink / raw) To: Jean Delvare; +Cc: linux-kernel, Ben Hutchings, Andrew Morton On Wed, 2013-07-10 at 18:17 +0200, Jean Delvare wrote: > Le Wednesday 10 July 2013 à 07:51 -0700, Joe Perches a écrit : > > even more trivial... [] > > It'd also be nice to use the same test style > > in all 6 uses. > > > > if (!foo) > > Both styles are used throughout the file, and checkpatch doesn't > complain. And it might be wrong for checkpatch to complain as there are tens of thousands of those in the kernel. I think using both styles in the same file is poor form though. > Unifying the coding style is beyond the scope of my patchset, > sorry. Feel free to send a patch on top of mine if you really care. No worries. If I remember, I'll send a patch after yours hit -next. ^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-07-10 17:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <1373460424.4399.45.camel@chaos.site>
2013-07-10 14:51 ` [PATCH] firmware/dmi_scan: Drop OOM messages Joe Perches
2013-07-10 16:17 ` Jean Delvare
2013-07-10 17:36 ` Joe Perches
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®