From: Justin Pettit Date: Thu, 2 Apr 2009 21:05:45 +0000 (-0700) Subject: Don't complain when setting STP sysfs values to the default one. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fbe31211d93dbae5fa27572f3fb2127566da6a57;p=openvswitch Don't complain when setting STP sysfs values to the default one. We don't support configuring STP through sysfs. However, Xen tries to disable STP by writing a zero value to some fields, which is our default. This change suppresses the warning that we don't support setting STP sysfs values in those circumstances. --- diff --git a/datapath/brc_sysfs_dp.c b/datapath/brc_sysfs_dp.c index a1b3c8e3..8743938c 100644 --- a/datapath/brc_sysfs_dp.c +++ b/datapath/brc_sysfs_dp.c @@ -56,8 +56,14 @@ static ssize_t store_bridge_parm(struct class_device *d, (*set)(br, val); spin_unlock_bh(&br->lock); #else - printk("%s: xxx writing dp parms not supported yet!\n", - dp->netdev->name); + /* xxx We use a default value of 0 for all fields. If the caller is + * xxx attempting to set the value to our default, just silently + * xxx ignore the request. + */ + if (val != 0) { + printk("%s: xxx writing dp parms not supported yet!\n", + dp->netdev->name); + } #endif return len; }