Re: [PATCH net-next v2 4/7] ice: Implement iidc operations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, May 27, 2021 at 05:12:41PM -0700, Jakub Kicinski wrote:
> On Thu, 27 May 2021 10:30:11 -0700 Tony Nguyen wrote:
> > +static enum ice_status
> > +ice_aq_add_rdma_qsets(struct ice_hw *hw, u8 num_qset_grps,
> > +		      struct ice_aqc_add_rdma_qset_data *qset_list,
> > +		      u16 buf_size, struct ice_sq_cd *cd)
> > +{
> > +	struct ice_aqc_add_rdma_qset_data *list;
> > +	struct ice_aqc_add_rdma_qset *cmd;
> > +	struct ice_aq_desc desc;
> > +	u16 i, sum_size = 0;
> > +
> > +	cmd = &desc.params.add_rdma_qset;
> > +
> > +	ice_fill_dflt_direct_cmd_desc(&desc, ice_aqc_opc_add_rdma_qset);
> > +
> > +	if (!qset_list)
> 
> defensive programming
> 
> > +		return ICE_ERR_PARAM;
> 
> RDMA folks, are you okay with drivers inventing their own error
> codes?

Not really, I was ignoring it because it looks like big part of their
netdev driver layer.

> Having had to make tree-wide changes and deal with this cruft in 
> the past I've developed a strong dislike for it. But if you're okay
> I guess it can stay, these are RDMA functions after all.

I don't think it is a "RDMA" issue:

$ git grep ICE_ERR_PARAM | wc -l
168
$ git grep -l ICE_ERR_PARAM
drivers/net/ethernet/intel/ice/ice_common.c
drivers/net/ethernet/intel/ice/ice_controlq.c
drivers/net/ethernet/intel/ice/ice_dcb.c
drivers/net/ethernet/intel/ice/ice_fdir.c
drivers/net/ethernet/intel/ice/ice_flex_pipe.c
drivers/net/ethernet/intel/ice/ice_flow.c
drivers/net/ethernet/intel/ice/ice_lib.c
drivers/net/ethernet/intel/ice/ice_main.c
drivers/net/ethernet/intel/ice/ice_nvm.c
drivers/net/ethernet/intel/ice/ice_sched.c
drivers/net/ethernet/intel/ice/ice_sriov.c
drivers/net/ethernet/intel/ice/ice_status.h
drivers/net/ethernet/intel/ice/ice_switch.c
drivers/net/ethernet/intel/ice/ice_virtchnl_pf.c

Jason



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Photo]     [Yosemite News]     [Yosemite Photos]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux