Re: [PATCH] ath6kl: fix struct hif_scatter_req list handling

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Kalle Valo <kvalo@xxxxxxxxxxxxxxxx> writes:

> Jason noticed that with Yocto GCC 4.8.1 ath6kl crashes with this iperf command:
>
> iperf -c $TARGET_IP -i 5 -t 50 -w 1M
>
> The crash was:
>

[...]

> ---[ end trace 0c038f0b8e0b67a3 ]---
> Kernel panic - not syncing: Fatal exception
>
> Jason's analysis:
>
>
>   "The GCC 4.8.1 compiler will not do the for-loop till scat_entries, instead,
>    it only run one round loop. This may be caused by that the GCC 4.8.1 thought
>    that the scat_list only have one item and then no need to do full iteration,
>    but this is simply wrong by looking at the assebly code. This will cause the sg
>    buffer not get set when scat_entries > 1 and thus lead to kernel panic.
>
>    Note: This issue not observed with GCC 4.7.2, only found on the GCC 4.8.1)"
>
> Fix this by using the normal [0] style for defining unknown number of list
> entries following the struct. This also fixes corruption with scat_q_depth, which
> was mistankely added to the end of struct and overwritten if there were more
> than item in the scat list.
>
> Reported-by: Jason Liu <r64343@xxxxxxxxxxxxx>
> Tested-by: Jason Liu <r64343@xxxxxxxxxxxxx>
> Signed-off-by: Kalle Valo <kvalo@xxxxxxxxxxxxxxxx>

Applied.

-- 
Kalle Valo

_______________________________________________
ath6kl mailing list
ath6kl@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/ath6kl




[Index of Archives]     [Linux Kernel]     [Linux Wireless]     [Linux Bluetooth]     [Linux WPAN]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]

  Powered by Linux