Lines Matching full:pf
29 nfp_devlink_fill_eth_port_from_id(struct nfp_pf *pf, unsigned int port_index, in nfp_devlink_fill_eth_port_from_id() argument
34 port = nfp_port_from_id(pf, NFP_PORT_PHYS_PORT, port_index); in nfp_devlink_fill_eth_port_from_id()
40 nfp_devlink_set_lanes(struct nfp_pf *pf, unsigned int idx, unsigned int lanes) in nfp_devlink_set_lanes() argument
45 nsp = nfp_eth_config_start(pf->cpp, idx); in nfp_devlink_set_lanes()
61 return nfp_net_refresh_port_table_sync(pf); in nfp_devlink_set_lanes()
68 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_port_split() local
73 mutex_lock(&pf->lock); in nfp_devlink_port_split()
76 ret = nfp_devlink_fill_eth_port_from_id(pf, port_index, ð_port); in nfp_devlink_port_split()
91 ret = nfp_devlink_set_lanes(pf, eth_port.index, lanes); in nfp_devlink_port_split()
93 mutex_unlock(&pf->lock); in nfp_devlink_port_split()
102 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_port_unsplit() local
107 mutex_lock(&pf->lock); in nfp_devlink_port_unsplit()
110 ret = nfp_devlink_fill_eth_port_from_id(pf, port_index, ð_port); in nfp_devlink_port_unsplit()
125 ret = nfp_devlink_set_lanes(pf, eth_port.index, lanes); in nfp_devlink_port_unsplit()
127 mutex_unlock(&pf->lock); in nfp_devlink_port_unsplit()
136 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_sb_pool_get() local
138 return nfp_shared_buf_pool_get(pf, sb_index, pool_index, pool_info); in nfp_devlink_sb_pool_get()
147 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_sb_pool_set() local
149 return nfp_shared_buf_pool_set(pf, sb_index, pool_index, in nfp_devlink_sb_pool_set()
155 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_eswitch_mode_get() local
157 return nfp_app_eswitch_mode_get(pf->app, mode); in nfp_devlink_eswitch_mode_get()
163 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_eswitch_mode_set() local
166 mutex_lock(&pf->lock); in nfp_devlink_eswitch_mode_set()
167 ret = nfp_app_eswitch_mode_set(pf->app, mode); in nfp_devlink_eswitch_mode_set()
168 mutex_unlock(&pf->lock); in nfp_devlink_eswitch_mode_set()
184 nfp_devlink_versions_get_hwinfo(struct nfp_pf *pf, struct devlink_info_req *req) in nfp_devlink_versions_get_hwinfo() argument
195 val = nfp_hwinfo_lookup(pf->hwinfo, info->hwinfo); in nfp_devlink_versions_get_hwinfo()
258 struct nfp_pf *pf = devlink_priv(devlink); in nfp_devlink_info_get() local
268 vendor = nfp_hwinfo_lookup(pf->hwinfo, "assembly.vendor"); in nfp_devlink_info_get()
269 part = nfp_hwinfo_lookup(pf->hwinfo, "assembly.partno"); in nfp_devlink_info_get()
270 sn = nfp_hwinfo_lookup(pf->hwinfo, "assembly.serial"); in nfp_devlink_info_get()
290 nsp = nfp_nsp_open(pf->cpp); in nfp_devlink_info_get()
322 return nfp_devlink_versions_get_hwinfo(pf, req); in nfp_devlink_info_get()
375 devlink = priv_to_devlink(app->pf); in nfp_devlink_port_register()