drivers/soc/renesas/r9a08g046-sysc.c
Source file repositories/reference/linux-study-clean/drivers/soc/renesas/r9a08g046-sysc.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/soc/renesas/r9a08g046-sysc.c- Extension
.c- Size
- 2055 bytes
- Lines
- 87
- Domain
- Driver Families
- Bucket
- drivers/soc
- 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
linux/bits.hlinux/device.hlinux/init.hrz-sysc.h
Detected Declarations
function Copyrightfunction rzg3l_regmap_readable_regfunction rzg3l_regmap_writeable_reg
Annotated Snippet
// SPDX-License-Identifier: GPL-2.0
/*
* RZ/G3L System controller (SYSC) driver
*
* Copyright (C) 2026 Renesas Electronics Corp.
*/
#include <linux/bits.h>
#include <linux/device.h>
#include <linux/init.h>
#include "rz-sysc.h"
#define SYS_XSPI_MAP_STAADD_CS0 0x348
#define SYS_XSPI_MAP_ENDADD_CS0 0x34c
#define SYS_XSPI_MAP_STAADD_CS1 0x350
#define SYS_XSPI_MAP_ENDADD_CS1 0x354
#define SYS_GETH0_CFG 0x380
#define SYS_GETH1_CFG 0x390
#define SYS_PCIE_CFG 0x3a0
#define SYS_PCIE_MON 0x3a4
#define SYS_PCIE_PHY 0x3b4
#define SYS_I2C0_CFG 0x400
#define SYS_I2C1_CFG 0x410
#define SYS_I2C2_CFG 0x420
#define SYS_I2C3_CFG 0x430
#define SYS_I3C_CFG 0x440
#define SYS_PWRRDY_N 0xd70
#define SYS_IPCONT_SEL_CLONECH 0xe2c
static bool rzg3l_regmap_readable_writeable_reg(unsigned int reg)
{
switch (reg) {
case SYS_XSPI_MAP_STAADD_CS0:
case SYS_XSPI_MAP_ENDADD_CS0:
case SYS_XSPI_MAP_STAADD_CS1:
case SYS_XSPI_MAP_ENDADD_CS1:
case SYS_PCIE_CFG:
case SYS_PCIE_PHY:
case SYS_I2C0_CFG:
case SYS_I2C1_CFG:
case SYS_I2C2_CFG:
case SYS_I2C3_CFG:
case SYS_I3C_CFG:
case SYS_PWRRDY_N:
case SYS_IPCONT_SEL_CLONECH:
return true;
default:
return false;
}
}
static bool rzg3l_regmap_readable_reg(struct device *dev, unsigned int reg)
{
if (rzg3l_regmap_readable_writeable_reg(reg))
return true;
switch (reg) {
case SYS_GETH0_CFG:
case SYS_GETH1_CFG:
case SYS_PCIE_MON:
return true;
default:
return false;
}
}
static bool rzg3l_regmap_writeable_reg(struct device *dev, unsigned int reg)
{
return rzg3l_regmap_readable_writeable_reg(reg);
}
static const struct rz_sysc_soc_id_init_data rzg3l_sysc_soc_id_init_data __initconst = {
.family = "RZ/G3L",
.id = 0x87d9447,
.devid_offset = 0xa04,
.revision_mask = GENMASK(31, 28),
.specific_id_mask = GENMASK(27, 0),
};
const struct rz_sysc_init_data rzg3l_sysc_init_data __initconst = {
.soc_id_init_data = &rzg3l_sysc_soc_id_init_data,
.readable_reg = rzg3l_regmap_readable_reg,
.writeable_reg = rzg3l_regmap_writeable_reg,
.max_register = 0xe2c,
};
Annotation
- Immediate include surface: `linux/bits.h`, `linux/device.h`, `linux/init.h`, `rz-sysc.h`.
- Detected declarations: `function Copyright`, `function rzg3l_regmap_readable_reg`, `function rzg3l_regmap_writeable_reg`.
- Atlas domain: Driver Families / drivers/soc.
- 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.