drivers/net/ethernet/microchip/lan966x/lan966x_vcap_ag_api.c

Source file repositories/reference/linux-study-clean/drivers/net/ethernet/microchip/lan966x/lan966x_vcap_ag_api.c

File Facts

System
Linux kernel
Corpus path
drivers/net/ethernet/microchip/lan966x/lan966x_vcap_ag_api.c
Extension
.c
Size
71473 bytes
Lines
3271
Domain
Driver Families
Bucket
drivers/net
Inferred role
Driver Families: implementation source
Status
source implementation candidate

Why This File Exists

Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.

Dependency Surface

Detected Declarations

Annotated Snippet

// SPDX-License-Identifier: (GPL-2.0 OR MIT)

#include <linux/types.h>
#include <linux/kernel.h>

#include "lan966x_vcap_ag_api.h"

/* keyfields */
static const struct vcap_field is1_normal_keyfield[] = {
	[VCAP_KF_TYPE] = {
		.type = VCAP_FIELD_BIT,
		.offset = 0,
		.width = 1,
	},
	[VCAP_KF_LOOKUP_INDEX] = {
		.type = VCAP_FIELD_U32,
		.offset = 1,
		.width = 2,
	},
	[VCAP_KF_IF_IGR_PORT_MASK] = {
		.type = VCAP_FIELD_U32,
		.offset = 3,
		.width = 9,
	},
	[VCAP_KF_L2_MC_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 12,
		.width = 1,
	},
	[VCAP_KF_L2_BC_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 13,
		.width = 1,
	},
	[VCAP_KF_IP_MC_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 14,
		.width = 1,
	},
	[VCAP_KF_8021CB_R_TAGGED_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 15,
		.width = 1,
	},
	[VCAP_KF_8021Q_VLAN_TAGGED_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 16,
		.width = 1,
	},
	[VCAP_KF_8021Q_VLAN_DBL_TAGGED_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 17,
		.width = 1,
	},
	[VCAP_KF_8021Q_TPID0] = {
		.type = VCAP_FIELD_BIT,
		.offset = 18,
		.width = 1,
	},
	[VCAP_KF_8021Q_VID0] = {
		.type = VCAP_FIELD_U32,
		.offset = 19,
		.width = 12,
	},
	[VCAP_KF_8021Q_DEI0] = {
		.type = VCAP_FIELD_BIT,
		.offset = 31,
		.width = 1,
	},
	[VCAP_KF_8021Q_PCP0] = {
		.type = VCAP_FIELD_U32,
		.offset = 32,
		.width = 3,
	},
	[VCAP_KF_L2_SMAC] = {
		.type = VCAP_FIELD_U48,
		.offset = 35,
		.width = 48,
	},
	[VCAP_KF_ETYPE_LEN_IS] = {
		.type = VCAP_FIELD_BIT,
		.offset = 83,
		.width = 1,
	},
	[VCAP_KF_ETYPE] = {
		.type = VCAP_FIELD_U32,
		.offset = 84,
		.width = 16,
	},
	[VCAP_KF_IP_SNAP_IS] = {

Annotation

Implementation Notes