drivers/staging/media/atomisp/pci/hive_isp_css_common/host/isp_private.h
Source file repositories/reference/linux-study-clean/drivers/staging/media/atomisp/pci/hive_isp_css_common/host/isp_private.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/staging/media/atomisp/pci/hive_isp_css_common/host/isp_private.h- Extension
.h- Size
- 3588 bytes
- Lines
- 153
- Domain
- Driver Families
- Bucket
- drivers/staging
- 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.
Dependency Surface
hrt/api.hisp_public.hdevice_access.hassert_support.htype_support.h
Detected Declarations
function Copyrightfunction isp_ctrl_loadfunction isp_ctrl_getbitfunction isp_ctrl_setbitfunction isp_ctrl_clearbitfunction isp_dmem_storefunction isp_dmem_loadfunction isp_dmem_store_uint32function isp_dmem_load_uint32function isp_2w_cat_1w
Annotated Snippet
#ifndef __ISP_PRIVATE_H_INCLUDED__
#define __ISP_PRIVATE_H_INCLUDED__
#ifdef HRT_MEMORY_ACCESS
#include <hrt/api.h>
#endif
#include "isp_public.h"
#include "device_access.h"
#include "assert_support.h"
#include "type_support.h"
STORAGE_CLASS_ISP_C void isp_ctrl_store(
const isp_ID_t ID,
const unsigned int reg,
const hrt_data value)
{
assert(ID < N_ISP_ID);
assert(ISP_CTRL_BASE[ID] != (hrt_address) - 1);
#if !defined(HRT_MEMORY_ACCESS)
ia_css_device_store_uint32(ISP_CTRL_BASE[ID] + reg * sizeof(hrt_data), value);
#else
hrt_master_port_store_32(ISP_CTRL_BASE[ID] + reg * sizeof(hrt_data), value);
#endif
return;
}
STORAGE_CLASS_ISP_C hrt_data isp_ctrl_load(
const isp_ID_t ID,
const unsigned int reg)
{
assert(ID < N_ISP_ID);
assert(ISP_CTRL_BASE[ID] != (hrt_address) - 1);
#if !defined(HRT_MEMORY_ACCESS)
return ia_css_device_load_uint32(ISP_CTRL_BASE[ID] + reg * sizeof(hrt_data));
#else
return hrt_master_port_uload_32(ISP_CTRL_BASE[ID] + reg * sizeof(hrt_data));
#endif
}
STORAGE_CLASS_ISP_C bool isp_ctrl_getbit(
const isp_ID_t ID,
const unsigned int reg,
const unsigned int bit)
{
hrt_data val = isp_ctrl_load(ID, reg);
return (val & (1UL << bit)) != 0;
}
STORAGE_CLASS_ISP_C void isp_ctrl_setbit(
const isp_ID_t ID,
const unsigned int reg,
const unsigned int bit)
{
hrt_data data = isp_ctrl_load(ID, reg);
isp_ctrl_store(ID, reg, (data | (1UL << bit)));
return;
}
STORAGE_CLASS_ISP_C void isp_ctrl_clearbit(
const isp_ID_t ID,
const unsigned int reg,
const unsigned int bit)
{
hrt_data data = isp_ctrl_load(ID, reg);
isp_ctrl_store(ID, reg, (data & ~(1UL << bit)));
return;
}
STORAGE_CLASS_ISP_C void isp_dmem_store(
const isp_ID_t ID,
unsigned int addr,
const void *data,
const size_t size)
{
assert(ID < N_ISP_ID);
assert(ISP_DMEM_BASE[ID] != (hrt_address) - 1);
#if !defined(HRT_MEMORY_ACCESS)
ia_css_device_store(ISP_DMEM_BASE[ID] + addr, data, size);
#else
hrt_master_port_store(ISP_DMEM_BASE[ID] + addr, data, size);
#endif
return;
}
Annotation
- Immediate include surface: `hrt/api.h`, `isp_public.h`, `device_access.h`, `assert_support.h`, `type_support.h`.
- Detected declarations: `function Copyright`, `function isp_ctrl_load`, `function isp_ctrl_getbit`, `function isp_ctrl_setbit`, `function isp_ctrl_clearbit`, `function isp_dmem_store`, `function isp_dmem_load`, `function isp_dmem_store_uint32`, `function isp_dmem_load_uint32`, `function isp_2w_cat_1w`.
- Atlas domain: Driver Families / drivers/staging.
- 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.