Gary Zambrano <[EMAIL PROTECTED]> :
[...]
> diff --git a/drivers/net/b44.c b/drivers/net/b44.c
> index b9e2462..6f4d1d4 100644
> --- a/drivers/net/b44.c
> +++ b/drivers/net/b44.c
[...]
> +static void b44_setup_pseudo_magicp(struct b44 *bp)
> +{
> +
> + u32 val;
> + int plen0, plen1, max, i, j;
> + u8 *pwol_pattern;
> + u8 *pwol_mask;
> +
> + pwol_pattern = kmalloc(B44_WOL_PATTERN_SIZE, GFP_KERNEL);
> + pwol_mask = kmalloc(B44_WOL_MASK_SIZE, GFP_KERNEL);
> +
> + /* UDP magic packet pattern */
> + memset(pwol_pattern, 0, B44_WOL_PATTERN_SIZE);
> + memset(pwol_pattern + 42, 0xff, 6); /* sync pattern */
kmalloc can fail. It should be checked.
> + max = ETH_ALEN;
> + for (i = 0; i < 14; ++i) {
> + if (i == 13)
> + max = 2;
> + for (j = 0; j < max; ++j) {
> + pwol_pattern[42 + 6 +
> + (i * ETH_ALEN) + j] =
> + bp->dev->dev_addr[j];
Indentation went strange here.
--
Ueimor
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html