DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ferruh Yigit <ferruh.yigit@intel.com>
To: Andy Green <andy@warmcat.com>, dev@dpdk.org
Subject: Re: [dpdk-dev] [PATCH 1/4] net/bnx2x: do not cast function pointers as a policy
Date: Fri, 11 May 2018 17:03:53 +0100	[thread overview]
Message-ID: <47379f2d-a00d-2fd0-f550-c81b960e50ce@intel.com> (raw)
In-Reply-To: <152600347742.53624.12860056818159426243.stgit@localhost.localdomain>

On 5/11/2018 2:51 AM, Andy Green wrote:
> This is stopping the compiler telling you when you have
> done something stupid... that is something none of us
> can afford...
> 
> Now gcc 8.x can tell you did something stupid despite
> trying to hide the evidence.
> 
> Remove all the "black magic" casts.
> 
> Fix the actual problems.

Missing sign-off

<...>

> @@ -5226,9 +5228,9 @@ static elink_status_t elink_get_link_speed_duplex(struct elink_phy *phy,
>  	return ELINK_STATUS_OK;
>  }
>  
> -static elink_status_t elink_link_settings_status(struct elink_phy *phy,
> -						 struct elink_params *params,
> -						 struct elink_vars *vars)
> +static uint8_t elink_link_settings_status(struct elink_phy *phy,
> +					  struct elink_params *params,
> +					  struct elink_vars *vars)
>  {

It is possible to remove "read_status_t" casting from phy_serdes and phy_xgxs
after this change.

<...>

> @@ -5520,9 +5522,9 @@ static void elink_set_preemphasis(struct elink_phy *phy,
>  	}
>  }
>  
> -static void elink_xgxs_config_init(struct elink_phy *phy,
> -				   struct elink_params *params,
> -				   struct elink_vars *vars)
> +static uint8_t elink_xgxs_config_init(struct elink_phy *phy,
> +				      struct elink_params *params,
> +				      struct elink_vars *vars)

Same here, this change can eliminate some "config_init_t" casts.

  reply	other threads:[~2018-05-11 16:03 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-11  1:51 [dpdk-dev] [PATCH 0/4] GCC8 fixes for MLX4/5/BNX2X PMD Andy Green
2018-05-11  1:51 ` [dpdk-dev] [PATCH 1/4] net/bnx2x: do not cast function pointers as a policy Andy Green
2018-05-11 16:03   ` Ferruh Yigit [this message]
2018-05-12  0:25     ` Andy Green
2018-05-11 16:33   ` De Lara Guarch, Pablo
2018-05-11  1:51 ` [dpdk-dev] [PATCH 2/4] net/bnx2x: remove unmeetable comparison Andy Green
2018-05-11 16:32   ` De Lara Guarch, Pablo
2018-05-11 18:10     ` Stephen Hemminger
2018-05-12  1:04       ` Andy Green
2018-05-11  1:51 ` [dpdk-dev] [PATCH 3/4] net/mlx5: solve var may be used uninitialized Andy Green
2018-05-11 16:25   ` De Lara Guarch, Pablo
2018-05-13  4:45   ` Shahaf Shuler
2018-05-13  5:25     ` Andy Green
2018-05-11  1:51 ` [dpdk-dev] [PATCH 4/4] net/bnx2x: solve overruns Andy Green
2018-05-11 16:21   ` De Lara Guarch, Pablo
2018-05-11 16:04 ` [dpdk-dev] [PATCH 0/4] GCC8 fixes for MLX4/5/BNX2X PMD Ferruh Yigit

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=47379f2d-a00d-2fd0-f550-c81b960e50ce@intel.com \
    --to=ferruh.yigit@intel.com \
    --cc=andy@warmcat.com \
    --cc=dev@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).