From: Dmitry Eremin-Solenikov Date: Fri, 18 Sep 2009 12:35:06 +0000 (+0400) Subject: wpan-phy: init channel/page fields X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=37eb0edc8488fccbf601ab3e7e582373ed2a631e;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git wpan-phy: init channel/page fields Set page to zero (for compatibility w/ devices supporting only first page). Also init channel by default to -1 to disallow transfers for non-initialised devices. Signed-off-by: Dmitry Eremin-Solenikov --- diff --git a/net/ieee802154/wpan-class.c b/net/ieee802154/wpan-class.c index 0cec13842916..a10ae5be6adb 100644 --- a/net/ieee802154/wpan-class.c +++ b/net/ieee802154/wpan-class.c @@ -143,6 +143,9 @@ struct wpan_phy *wpan_phy_alloc(size_t priv_size) phy->dev.class = &wpan_phy_class; + phy->current_channel = -1; /* not initialised */ + phy->current_page = 0; /* for compatibility */ + return phy; } EXPORT_SYMBOL(wpan_phy_alloc);