diff options
author | 2015-08-25 10:54:12 +0200 | |
---|---|---|
committer | 2015-10-02 04:19:32 -0700 | |
commit | 231d51b8a4d5b24e72112bbc73fdcc38759a26e3 (patch) | |
tree | f01c6b7c3fb8b477475c4ed4d917ad7d9d754088 /tools/perf/scripts/python/call-graph-from-postgresql.py | |
parent | gpio: etraxfs: use container_of() to get state container (diff) | |
download | wireguard-linux-231d51b8a4d5b24e72112bbc73fdcc38759a26e3.tar.xz wireguard-linux-231d51b8a4d5b24e72112bbc73fdcc38759a26e3.zip |
gpio: altera: use container_of() to get state container
The state container of the Altera GPIO driver is extracted from
the gpio_chip exploiting the fact that offsetof() the
struct gpio_chip inside the struct of_mm_gpio_chip are both 0, so
the container_of() is in practice a noop. However if a member
is added to struct altera_gpio_chip in front of
struct of_mm_gpio_chip, things will break. Using proper
container_of() avoids this problem.
Semantically this is a noop, the compiler will optimize it away,
but syntactically it makes me happier.
Cc: Tien Hock Loh <thloh@altera.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'tools/perf/scripts/python/call-graph-from-postgresql.py')
0 files changed, 0 insertions, 0 deletions