drivers/gpu/drm/nouveau/include/nvif/printf.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/nouveau/include/nvif/printf.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/nouveau/include/nvif/printf.h- Extension
.h- Size
- 1206 bytes
- Lines
- 30
- Domain
- Driver Families
- Bucket
- drivers/gpu
- 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
nvif/client.hnvif/parent.h
Detected Declarations
- No top-level syscall, struct, function, initcall, or export declaration detected by the generator.
Annotated Snippet
#ifndef __NVIF_PRINTF_H__
#define __NVIF_PRINTF_H__
#include <nvif/client.h>
#include <nvif/parent.h>
#define NVIF_PRINT(l,o,f,a...) do { \
struct nvif_object *_o = (o); \
struct nvif_parent *_p = _o->parent; \
_p->func->l(_o, "[%s/%08x:%s] "f"\n", _o->client->object.name, _o->handle, _o->name, ##a); \
} while(0)
#ifndef NVIF_DEBUG_PRINT_DISABLE
#define NVIF_DEBUG(o,f,a...) NVIF_PRINT(debugf, (o), f, ##a)
#else
#define NVIF_DEBUG(o,f,a...)
#endif
#define NVIF_ERROR(o,f,a...) NVIF_PRINT(errorf, (o), f, ##a)
#define NVIF_ERRON(c,o,f,a...) do { \
struct nvif_object *_object = (o); \
int _cond = (c); \
if (_cond) { \
NVIF_ERROR(_object, f" (ret:%d)", ##a, _cond); \
} else { \
NVIF_DEBUG(_object, f, ##a); \
} \
} while(0)
#endif
Annotation
- Immediate include surface: `nvif/client.h`, `nvif/parent.h`.
- Atlas domain: Driver Families / drivers/gpu.
- 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.