lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 26 Jun 2013 17:59:30 -0700 From: Joe Perches <joe@...ches.com> To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com> Cc: "David S. Miller" <davem@...emloft.net>, netdev@...r.kernel.org, Darren Hart <dvhart@...ux.intel.com> Subject: Re: [PATCH v1 2/3] pch_gbe: convert pr_* to netdev_* On Wed, 2013-06-26 at 19:13 +0300, Andy Shevchenko wrote: > We may use nice macros to prefix our messages with proper device name. [] > diff --git a/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c b/drivers/net/ethernet/oki-semi/pch_gbe/pch_gbe_param.c [] > @@ -131,10 +133,12 @@ s32 pch_gbe_phy_get_id(struct pch_gbe_hw *hw) > */ > s32 pch_gbe_phy_read_reg_miic(struct pch_gbe_hw *hw, u32 offset, u16 *data) > { > + struct pch_gbe_adapter *adapter = pch_gbe_hw_to_adapter(hw); > struct pch_gbe_phy_info *phy = &hw->phy; > > if (offset > PHY_MAX_REG_ADDRESS) { > - pr_err("PHY Address %d is out of range\n", offset); > + netdev_err(adapter->netdev, "PHY Address %d is out of range\n", > + offset); For all the patch blocks in this set, I suggest taking these reverences only when necessary. Assigning them at the beginning of the function seems wasteful when these may not be used at all. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists