]> git.baikalelectronics.ru Git - kernel.git/commit
rt6_probe_deferred: Do not depend on struct ordering
authorMichael Büsch <m@bues.ch>
Sun, 8 Feb 2015 09:14:07 +0000 (10:14 +0100)
committerDavid S. Miller <davem@davemloft.net>
Sun, 8 Feb 2015 21:00:43 +0000 (13:00 -0800)
commit2882c075895758aab03c595b810700eda85cda0f
treea5ce27e64f3bf2239add0b4a526aab7f85014e1c
parenta4970ab5b8eba9759dd12df6e08fd9a48f9d1114
rt6_probe_deferred: Do not depend on struct ordering

rt6_probe allocates a struct __rt6_probe_work and schedules a work handler rt6_probe_deferred.
But rt6_probe_deferred kfree's the struct work_struct instead of struct __rt6_probe_work.
This works, because struct work_struct is the first element of struct __rt6_probe_work.

Change it to kfree struct __rt6_probe_work to not implicitly depend on
struct work_struct being the first element.

This does not affect the generated code.

Signed-off-by: Michael Buesch <m@bues.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/route.c