drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_llh.c
Source file repositories/reference/linux-study-clean/drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_llh.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/ethernet/aquantia/atlantic/hw_atl/hw_atl_llh.c- Extension
.c- Size
- 56294 bytes
- Lines
- 1897
- 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.
- 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.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
hw_atl_llh.hhw_atl_llh_internal.h../aq_hw_utils.h
Detected Declarations
function Copyrightfunction hw_atl_ts_power_down_setfunction hw_atl_ts_power_down_getfunction hw_atl_ts_ready_getfunction hw_atl_ts_ready_latch_high_getfunction hw_atl_ts_data_getfunction hw_atl_smb0_bus_busy_getfunction hw_atl_smb0_byte_transfer_complete_getfunction hw_atl_smb0_receive_acknowledged_getfunction hw_atl_smb0_repeated_start_detect_getfunction hw_atl_smb0_rx_data_getfunction hw_atl_smb0_tx_data_setfunction hw_atl_smb0_provisioning2_setfunction hw_atl_reg_glb_cpu_sem_setfunction hw_atl_reg_glb_cpu_sem_getfunction hw_atl_glb_glb_reg_res_dis_setfunction hw_atl_glb_soft_res_setfunction hw_atl_glb_soft_res_getfunction hw_atl_reg_glb_mif_id_getfunction hw_atl_rpb_rx_dma_drop_pkt_cnt_getfunction hw_atl_stats_rx_dma_good_octet_counter_getfunction hw_atl_stats_rx_dma_good_pkt_counter_getfunction hw_atl_stats_tx_dma_good_octet_counter_getfunction hw_atl_stats_tx_dma_good_pkt_counter_getfunction hw_atl_itr_irq_auto_masklsw_setfunction hw_atl_itr_irq_map_en_rx_setfunction hw_atl_itr_irq_map_en_tx_setfunction hw_atl_itr_irq_map_rx_setfunction hw_atl_itr_irq_map_tx_setfunction hw_atl_itr_irq_msk_clearlsw_setfunction hw_atl_itr_irq_msk_setlsw_setfunction hw_atl_itr_irq_reg_res_dis_setfunction hw_atl_itr_irq_status_clearlsw_setfunction hw_atl_itr_irq_statuslsw_getfunction hw_atl_itr_res_irq_getfunction hw_atl_itr_res_irq_setfunction hw_atl_itr_rsc_en_setfunction hw_atl_itr_rsc_delay_setfunction hw_atl_rdm_cpu_id_setfunction hw_atl_rdm_rx_dca_en_setfunction hw_atl_rdm_rx_dca_mode_setfunction hw_atl_rdm_rx_desc_data_buff_size_setfunction hw_atl_rdm_rx_desc_dca_en_setfunction hw_atl_rdm_rx_desc_en_setfunction hw_atl_rdm_rx_desc_head_buff_size_setfunction hw_atl_rdm_rx_desc_head_splitting_setfunction hw_atl_rdm_rx_desc_head_ptr_getfunction hw_atl_rdm_rx_desc_len_set
Annotated Snippet
// SPDX-License-Identifier: GPL-2.0-only
/* Atlantic Network Driver
*
* Copyright (C) 2014-2019 aQuantia Corporation
* Copyright (C) 2019-2020 Marvell International Ltd.
*/
/* File hw_atl_llh.c: Definitions of bitfield and register access functions for
* Atlantic registers.
*/
#include "hw_atl_llh.h"
#include "hw_atl_llh_internal.h"
#include "../aq_hw_utils.h"
void hw_atl_ts_reset_set(struct aq_hw_s *aq_hw, u32 val)
{
aq_hw_write_reg_bit(aq_hw, HW_ATL_TS_RESET_ADR,
HW_ATL_TS_RESET_MSK,
HW_ATL_TS_RESET_SHIFT,
val);
}
void hw_atl_ts_power_down_set(struct aq_hw_s *aq_hw, u32 val)
{
aq_hw_write_reg_bit(aq_hw, HW_ATL_TS_POWER_DOWN_ADR,
HW_ATL_TS_POWER_DOWN_MSK,
HW_ATL_TS_POWER_DOWN_SHIFT,
val);
}
u32 hw_atl_ts_power_down_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_TS_POWER_DOWN_ADR,
HW_ATL_TS_POWER_DOWN_MSK,
HW_ATL_TS_POWER_DOWN_SHIFT);
}
u32 hw_atl_ts_ready_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_TS_READY_ADR,
HW_ATL_TS_READY_MSK,
HW_ATL_TS_READY_SHIFT);
}
u32 hw_atl_ts_ready_latch_high_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_TS_READY_LATCH_HIGH_ADR,
HW_ATL_TS_READY_LATCH_HIGH_MSK,
HW_ATL_TS_READY_LATCH_HIGH_SHIFT);
}
u32 hw_atl_ts_data_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_TS_DATA_OUT_ADR,
HW_ATL_TS_DATA_OUT_MSK,
HW_ATL_TS_DATA_OUT_SHIFT);
}
u32 hw_atl_smb0_bus_busy_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_SMB0_BUS_BUSY_ADR,
HW_ATL_SMB0_BUS_BUSY_MSK,
HW_ATL_SMB0_BUS_BUSY_SHIFT);
}
u32 hw_atl_smb0_byte_transfer_complete_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_SMB0_BYTE_TRANSFER_COMPLETE_ADR,
HW_ATL_SMB0_BYTE_TRANSFER_COMPLETE_MSK,
HW_ATL_SMB0_BYTE_TRANSFER_COMPLETE_SHIFT);
}
u32 hw_atl_smb0_receive_acknowledged_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_SMB0_RX_ACKNOWLEDGED_ADR,
HW_ATL_SMB0_RX_ACKNOWLEDGED_MSK,
HW_ATL_SMB0_RX_ACKNOWLEDGED_SHIFT);
}
u32 hw_atl_smb0_repeated_start_detect_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg_bit(aq_hw, HW_ATL_SMB0_REPEATED_START_DETECT_ADR,
HW_ATL_SMB0_REPEATED_START_DETECT_MSK,
HW_ATL_SMB0_REPEATED_START_DETECT_SHIFT);
}
u32 hw_atl_smb0_rx_data_get(struct aq_hw_s *aq_hw)
{
return aq_hw_read_reg(aq_hw, HW_ATL_SMB0_RECEIVED_DATA_ADR);
Annotation
- Immediate include surface: `hw_atl_llh.h`, `hw_atl_llh_internal.h`, `../aq_hw_utils.h`.
- Detected declarations: `function Copyright`, `function hw_atl_ts_power_down_set`, `function hw_atl_ts_power_down_get`, `function hw_atl_ts_ready_get`, `function hw_atl_ts_ready_latch_high_get`, `function hw_atl_ts_data_get`, `function hw_atl_smb0_bus_busy_get`, `function hw_atl_smb0_byte_transfer_complete_get`, `function hw_atl_smb0_receive_acknowledged_get`, `function hw_atl_smb0_repeated_start_detect_get`.
- Atlas domain: Driver Families / drivers/net.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.