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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20140313.132222.536931544768069240.davem@davemloft.net>
Date:	Thu, 13 Mar 2014 13:22:22 -0400 (EDT)
From:	David Miller <davem@...emloft.net>
To:	David.Laight@...LAB.COM
Cc:	hayeswang@...ltek.com, netdev@...r.kernel.org,
	nic_swsd@...ltek.com, linux-kernel@...r.kernel.org,
	linux-usb@...r.kernel.org
Subject: Re: [PATCH net-next v3 1/2] r8152: add
 RTL8152_EARLY_AGG_TIMEOUT_SUPER

From: David Laight <David.Laight@...LAB.COM>
Date: Thu, 13 Mar 2014 13:12:35 +0000

> From: Hayes Wang
> ...
> 
> I should have spotted this before.
> 
>>  /* USB_RX_EARLY_AGG */
>> -#define EARLY_AGG_SUPPER	0x0e832981
>> +#define EARLY_AGG_SUPER	((((rx_buf_sz - 1522) / 4) << 16) | \
>> +	(u32)(CONFIG_RTL8152_EARLY_AGG_TIMEOUT_SUPER <= 0 ? 85 * 125 : \
>> +	min(CONFIG_RTL8152_EARLY_AGG_TIMEOUT_SUPER * 125, 0xffff)))
>>  #define EARLY_AGG_HIGH		0x0e837a12
>>  #define EARLY_AGG_SLOW		0x0e83ffff
>> 
>> @@ -1978,7 +1980,7 @@ static void r8153_set_rx_agg(struct r8152 *tp)
>>  			ocp_write_dword(tp, MCU_TYPE_USB, USB_RX_BUF_TH,
>>  					RX_THR_SUPPER);
>>  			ocp_write_dword(tp, MCU_TYPE_USB, USB_RX_EARLY_AGG,
>> -					EARLY_AGG_SUPPER);
>> +					EARLY_AGG_SUPER);
>>  		} else {
>>  			ocp_write_dword(tp, MCU_TYPE_USB, USB_RX_BUF_TH,
>>  					RX_THR_HIGH);
> 
> It looks as though rx_buf_sz should be a parameter to EARLY_AGG_SUPER.

And I fundamentally disagree with this being a Kconfig parameter.

Make it run-time calculated _or_ settable via ethtool.

Thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ