From: Johan Hovold Date: Tue, 13 Jan 2015 12:00:06 +0000 (+0100) Subject: gpio: sysfs: fix gpio attribute-creation race X-Git-Tag: v3.2.67~37 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a10ff58e82582898690f3f2328ef5ef772c2a0b1;p=pandora-kernel.git gpio: sysfs: fix gpio attribute-creation race commit ebbeba120ab2ec6ac5f3afc1425ec6ff0b77ad6f upstream. Fix attribute-creation race with userspace by using the default group to create also the contingent gpio device attributes. Fixes: d8f388d8dc8d ("gpio: sysfs interface") Signed-off-by: Johan Hovold Signed-off-by: Linus Walleij [bwh: Backported to 3.2: - Adjust filenames, context - Use gpio_to_desc(), not gpiod_to_desc(), in gpio_is_visible() - gpio_is_visible() must return mode_t] Signed-off-by: Ben Hutchings --- Reading git-diff-tree failed