* [PATCH] ide-features.c: unchecked kmalloc
@ 2001-01-09 18:05 Arnaldo Carvalho de Melo
2001-01-10 5:07 ` Andre Hedrick
0 siblings, 1 reply; 2+ messages in thread
From: Arnaldo Carvalho de Melo @ 2001-01-09 18:05 UTC (permalink / raw)
To: Andre Hedrick; +Cc: Alan Cox, linux-kernel
Hi,
Please consider applying.
- Arnaldo
--- linux-2.4.0-ac4/drivers/ide/ide-features.c Mon Jan 8 20:39:17 2001
+++ linux-2.4.0-ac4.acme/drivers/ide/ide-features.c Tue Jan 9 16:02:11 2001
@@ -189,6 +189,10 @@
__cli(); /* local CPU only; some systems need this */
SELECT_MASK(HWIF(drive), drive, 0);
id = kmalloc(SECTOR_WORDS*4, GFP_ATOMIC);
+ if (!id) {
+ __restore_flags(flags); /* local CPU only */
+ return 0;
+ }
ide_input_data(drive, id, SECTOR_WORDS);
(void) GET_STAT(); /* clear drive IRQ */
ide__sti(); /* local CPU only */
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] ide-features.c: unchecked kmalloc
2001-01-09 18:05 [PATCH] ide-features.c: unchecked kmalloc Arnaldo Carvalho de Melo
@ 2001-01-10 5:07 ` Andre Hedrick
0 siblings, 0 replies; 2+ messages in thread
From: Andre Hedrick @ 2001-01-10 5:07 UTC (permalink / raw)
To: Arnaldo Carvalho de Melo; +Cc: Alan Cox, linux-kernel
Please name a time or event when you would cal a setfeaturers command
without having a IDENTIFY page filled?
On Tue, 9 Jan 2001, Arnaldo Carvalho de Melo wrote:
> Hi,
>
> Please consider applying.
>
> - Arnaldo
>
> --- linux-2.4.0-ac4/drivers/ide/ide-features.c Mon Jan 8 20:39:17 2001
> +++ linux-2.4.0-ac4.acme/drivers/ide/ide-features.c Tue Jan 9 16:02:11 2001
> @@ -189,6 +189,10 @@
> __cli(); /* local CPU only; some systems need this */
> SELECT_MASK(HWIF(drive), drive, 0);
> id = kmalloc(SECTOR_WORDS*4, GFP_ATOMIC);
> + if (!id) {
> + __restore_flags(flags); /* local CPU only */
> + return 0;
> + }
> ide_input_data(drive, id, SECTOR_WORDS);
> (void) GET_STAT(); /* clear drive IRQ */
> ide__sti(); /* local CPU only */
>
Andre Hedrick
Linux ATA Development
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-01-10 5:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-01-09 18:05 [PATCH] ide-features.c: unchecked kmalloc Arnaldo Carvalho de Melo
2001-01-10 5:07 ` Andre Hedrick
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox