Re: [PATCH 1/2] staging: iio replaced kmalloc with local variables.
From: Peter Hüwe
Date: Mon Jun 06 2011 - 15:21:25 EST
Am Montag 06 Juni 2011, 21:07:37 schrieb anish:
> +++ b/drivers/staging/iio/adc/max1363_core.c
> @@ -207,7 +207,7 @@ static int max1363_write_basic_config(struct i2c_client
> *client, unsigned char d2)
> {
> int ret;
> - u8 *tx_buf = kmalloc(2, GFP_KERNEL);
> + u8 tx_buf[2];
>
> if (!tx_buf)
> return -ENOMEM;
These last two lines can also be removed ;)
Thanks,
Peter
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/