lkml.org 
[lkml]   [2005]   [Apr]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    From
    SubjectRe: [03/07] I2C: Fix incorrect sysfs file permissions in it87 and via686a drivers
    Date
    On Wednesday 27 April 2005 12:16, Greg KH wrote:
    > As a side note, wouldn't it make sense to check, when creating sysfs
    > files, that readable files have a non-NULL show method, and writable
    > files have a non-NULL store method? I know drivers are not supposed to
    > do stupid things, but there is already a BUG_ON for several conditions
    > in sysfs_create_file, so maybe we could add two more?

    Checking at creation time is not enough. Even with such check one could
    change permissions on a sysfs file and set write bit.

    --
    Dmitry
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-04-28 07:57    [W:4.479 / U:0.004 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site