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: <0beccbf6-7a29-0545-604a-8e61a86b40a6@pensando.io>
Date:   Mon, 22 Jun 2020 17:47:06 -0700
From:   Shannon Nelson <snelson@...sando.io>
To:     Jeff Kirsher <jeffrey.t.kirsher@...el.com>, davem@...emloft.net
Cc:     Jesse Brandeburg <jesse.brandeburg@...el.com>,
        netdev@...r.kernel.org, nhorman@...hat.com, sassmann@...hat.com,
        Andrew Bowers <andrewx.bowers@...el.com>
Subject: Re: [net-next 2/9] i40e: remove unused defines

On 6/22/20 3:18 PM, Jeff Kirsher wrote:
> From: Jesse Brandeburg <jesse.brandeburg@...el.com>
>
> Remove all the unused defines as they are just dead weight.
>
> Signed-off-by: Jesse Brandeburg <jesse.brandeburg@...el.com>
> Tested-by: Andrew Bowers <andrewx.bowers@...el.com>
> Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@...el.com>
> ---
>   drivers/net/ethernet/intel/i40e/i40e.h        |   20 -
>   .../net/ethernet/intel/i40e/i40e_adminq_cmd.h |  482 +-
>   drivers/net/ethernet/intel/i40e/i40e_common.c |    4 -
>   drivers/net/ethernet/intel/i40e/i40e_dcb.h    |    5 -
>   .../net/ethernet/intel/i40e/i40e_debugfs.c    |    1 -
>   drivers/net/ethernet/intel/i40e/i40e_devids.h |    3 -
>   drivers/net/ethernet/intel/i40e/i40e_hmc.h    |    1 -
>   drivers/net/ethernet/intel/i40e/i40e_main.c   |    3 -
>   drivers/net/ethernet/intel/i40e/i40e_osdep.h  |    1 -
>   .../net/ethernet/intel/i40e/i40e_register.h   | 4656 -----------------
>   drivers/net/ethernet/intel/i40e/i40e_txrx.h   |   25 -
>   drivers/net/ethernet/intel/i40e/i40e_type.h   |   81 -
>   .../ethernet/intel/i40e/i40e_virtchnl_pf.h    |    1 -
>   include/linux/net/intel/i40e_client.h         |    5 -
>   14 files changed, 1 insertion(+), 5287 deletions(-)
>
> diff --git a/drivers/net/ethernet/intel/i40e/i40e.h b/drivers/net/ethernet/intel/i40e/i40e.h
> index 5ff0828a6f50..e8a42415531a 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e.h
> +++ b/drivers/net/ethernet/intel/i40e/i40e.h
> @@ -60,17 +60,14 @@
>   		(((pf)->hw_features & I40E_HW_RSS_AQ_CAPABLE) ? 4 : 1)
>   #define I40E_DEFAULT_QUEUES_PER_VF	4
>   #define I40E_MAX_VF_QUEUES		16
> -#define I40E_DEFAULT_QUEUES_PER_TC	1 /* should be a power of 2 */
>   #define i40e_pf_get_max_q_per_tc(pf) \
>   		(((pf)->hw_features & I40E_HW_128_QP_RSS_CAPABLE) ? 128 : 64)
> -#define I40E_FDIR_RING			0
>   #define I40E_FDIR_RING_COUNT		32
>   #define I40E_MAX_AQ_BUF_SIZE		4096
>   #define I40E_AQ_LEN			256
>   #define I40E_AQ_WORK_LIMIT		66 /* max number of VFs + a little */
>   #define I40E_MAX_USER_PRIORITY		8
>   #define I40E_DEFAULT_TRAFFIC_CLASS	BIT(0)
> -#define I40E_DEFAULT_MSG_ENABLE		4
>   #define I40E_QUEUE_WAIT_RETRY_LIMIT	10
>   #define I40E_INT_NAME_STR_LEN		(IFNAMSIZ + 16)
>   
> @@ -93,8 +90,6 @@
>   #define I40E_OEM_RELEASE_MASK		0x0000ffff
>   
>   /* The values in here are decimal coded as hex as is the case in the NVM map*/
> -#define I40E_CURRENT_NVM_VERSION_HI	0x2
> -#define I40E_CURRENT_NVM_VERSION_LO	0x40

The related comments should get removed as well, as they'll only cause 
future confusion if left lying around.  There are a few more instances 
of this in the patch that you'll want to hunt down.

I think there are a bunch of AQ field and bit defines and other similar 
that are useful to have around, if nothing else but to help document the 
values.  I'd prefer to see most of them left in place, but that's more 
my opinion that a demand of any kind.

But all that crap in i40e_register.h - yeah, that makes some sense to go 
away.

sln

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ