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 PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Tue, 1 Sep 2020 12:26:42 +0200 From: Heiner Kallweit <hkallweit1@...il.com> To: tongchen@....edu.cn, "netdev@...r.kernel.org" <netdev@...r.kernel.org> Subject: Re: [PATCH] drivers: reduce the param length of the line On 01.09.2020 10:11, tongchen@....edu.cn wrote: > I run the checkpatch script against the c source, and the following output says it prefers a maximum of 75 chars per-line. > That's wrong. As the name suggests, checkpatch is meant to be used with patches, not with source files. > #./scripts/checkpatch.pl drivers/net/ethernet/realtek/r8169_phy_config.c > WARNING: Possible unwrapped commit description (prefer a maximum 75 chars per line) > #1305: This refers to line length in commit description, not source file line length. > void r8169_hw_phy_config(struct rtl8169_private *tp, struct phy_device *phydev, > > ERROR: Does not appear to be a unified-diff format patch > > total: 1 errors, 1 warnings, 0 lines checked > > NOTE: For some of the reported defects, checkpatch may be able to > mechanically convert to the typical style using --fix or --fix-inplace. > > drivers/net/ethernet/realtek/r8169_phy_config.c has style problems, please review. > > NOTE: If any of the errors are false positives, please report > them to the maintainer, see CHECKPATCH in MAINTAINERS. > > 2020年9月1日 下午3:57,Heiner Kallweit <hkallweit1@...il.com>写道: > > On 01.09.2020 09:52, tongchen@....edu.cn wrote: > > 1)So the patch title should be written like this? > > "net: reduce the param length of the line" > > > > 2)I have checked the patch with the checkpatch script, no warnings or errors. > > > > 3)I saw the line length exceeded 75 chars which may look better if was written on a new line (which was what checkpatch suggeted). > > Max line length is 80 characters, therefore I don't see what should be wrong with the > current status. Can you send the checkpatch suggestion you're referring to? > > > (I'm a newbie to the patch world, know not much and feel like taking your advice sincerely) > > 2020年9月1日 下午3:29,Heiner Kallweit <hkallweit1@...il.com>写道: > > > > On 01.09.2020 04:28, Tong Chen wrote: > > > Reduce the param length of the line from 79 chars to 52 chars, > > > which complies with kernel preferences. > > > > Apart from formal issues with the patch (missing net/net-next > > annotation, wrong prefix): Did you get a checkpatch warning? > > Or what's the source of your assumed kernel preference? > > > > > Signed-off-by: Tong Chen <tongchen@....edu.cn> > > > --- > > > drivers/net/ethernet/realtek/r8169_phy_config.c | 3 ++- > > > 1 file changed, 2 insertions(+), 1 deletion(-) > > > > > > diff --git a/drivers/net/ethernet/realtek/r8169_phy_config.c b/drivers/net/ethernet/realtek/r8169_phy_config.c > > > index 913d030d73eb..f4b738cf8ad7 100644 > > > --- a/drivers/net/ethernet/realtek/r8169_phy_config.c > > > +++ b/drivers/net/ethernet/realtek/r8169_phy_config.c > > > @@ -1302,7 +1302,8 @@ static void rtl8125b_hw_phy_config(struct rtl8169_private *tp, > > > rtl8125b_config_eee_phy(phydev); > > > } > > > > > > -void r8169_hw_phy_config(struct rtl8169_private *tp, struct phy_device *phydev, > > > +void r8169_hw_phy_config(struct rtl8169_private *tp, > > > + struct phy_device *phydev, > > > enum mac_version ver) > > > { > > > static const rtl_phy_cfg_fct phy_configs[] = { > > > > > > > > >
Powered by blists - more mailing lists