drivers/crypto/caam/dpseci-debugfs.c
Source file repositories/reference/linux-study-clean/drivers/crypto/caam/dpseci-debugfs.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/crypto/caam/dpseci-debugfs.c- Extension
.c- Size
- 1432 bytes
- Lines
- 61
- Domain
- Driver Families
- Bucket
- drivers/crypto
- 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/module.hlinux/device.hlinux/debugfs.hdpseci-debugfs.h
Detected Declarations
function dpseci_dbg_fqs_showfunction dpaa2_dpseci_debugfs_initfunction dpaa2_dpseci_debugfs_exit
Annotated Snippet
// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause)
/* Copyright 2019 NXP */
#include <linux/module.h>
#include <linux/device.h>
#include <linux/debugfs.h>
#include "dpseci-debugfs.h"
static int dpseci_dbg_fqs_show(struct seq_file *file, void *offset)
{
struct dpaa2_caam_priv *priv = file->private;
u32 fqid, fcnt, bcnt;
int i, err;
seq_printf(file, "FQ stats for %s:\n", dev_name(priv->dev));
seq_printf(file, "%s%16s%16s\n",
"Rx-VFQID",
"Pending frames",
"Pending bytes");
for (i = 0; i < priv->num_pairs; i++) {
fqid = priv->rx_queue_attr[i].fqid;
err = dpaa2_io_query_fq_count(NULL, fqid, &fcnt, &bcnt);
if (err)
continue;
seq_printf(file, "%5d%16u%16u\n", fqid, fcnt, bcnt);
}
seq_printf(file, "%s%16s%16s\n",
"Tx-VFQID",
"Pending frames",
"Pending bytes");
for (i = 0; i < priv->num_pairs; i++) {
fqid = priv->tx_queue_attr[i].fqid;
err = dpaa2_io_query_fq_count(NULL, fqid, &fcnt, &bcnt);
if (err)
continue;
seq_printf(file, "%5d%16u%16u\n", fqid, fcnt, bcnt);
}
return 0;
}
DEFINE_SHOW_ATTRIBUTE(dpseci_dbg_fqs);
void dpaa2_dpseci_debugfs_init(struct dpaa2_caam_priv *priv)
{
priv->dfs_root = debugfs_create_dir(dev_name(priv->dev), NULL);
debugfs_create_file("fq_stats", 0444, priv->dfs_root, priv,
&dpseci_dbg_fqs_fops);
}
void dpaa2_dpseci_debugfs_exit(struct dpaa2_caam_priv *priv)
{
debugfs_remove_recursive(priv->dfs_root);
}
Annotation
- Immediate include surface: `linux/module.h`, `linux/device.h`, `linux/debugfs.h`, `dpseci-debugfs.h`.
- Detected declarations: `function dpseci_dbg_fqs_show`, `function dpaa2_dpseci_debugfs_init`, `function dpaa2_dpseci_debugfs_exit`.
- Atlas domain: Driver Families / drivers/crypto.
- 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.