Skip to content

Commit

Permalink
IPoIB: Only allow root to change between datagram and connected mode
Browse files Browse the repository at this point in the history
Change the permissions of the "mode" sysfs attribute to be S_IWUSR
instead of S_IWUGO.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
  • Loading branch information
Roland Dreier committed Feb 16, 2007
1 parent 11282b3 commit 551fd61
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/infiniband/ulp/ipoib/ipoib_cm.c
Original file line number Diff line number Diff line change
Expand Up @@ -1138,7 +1138,7 @@ static ssize_t set_mode(struct device *d, struct device_attribute *attr,
return -EINVAL;
}

static DEVICE_ATTR(mode, S_IWUGO | S_IRUGO, show_mode, set_mode);
static DEVICE_ATTR(mode, S_IWUSR | S_IRUGO, show_mode, set_mode);

int ipoib_cm_add_mode_attr(struct net_device *dev)
{
Expand Down

0 comments on commit 551fd61

Please sign in to comment.