drivers/media/usb/pvrusb2/pvrusb2-devattr.c
Source file repositories/reference/linux-study-clean/drivers/media/usb/pvrusb2/pvrusb2-devattr.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/media/usb/pvrusb2/pvrusb2-devattr.c- Extension
.c- Size
- 21575 bytes
- Lines
- 719
- Domain
- Driver Families
- Bucket
- drivers/media
- 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
pvrusb2-devattr.hlinux/usb.hlinux/module.hlinux/i2c.hmedia/tuner.hpvrusb2-hdw-internal.hlgdt330x.hs5h1409.hs5h1411.htda10048.htda18271.htda8290.htuner-simple.hsi2157.hlgdt3306a.hsi2168.h
Detected Declarations
function pvr2_lgdt3303_attachfunction pvr2_lgh06xf_attachfunction pvr2_lgdt3302_attachfunction pvr2_fcv1236d_attachfunction pvr2_tda10048_attachfunction pvr2_73xxx_tda18271_8295_attachfunction pvr2_s5h1409_attachfunction pvr2_s5h1411_attachfunction pvr2_tda18271_8295_attachfunction pvr2_si2157_attachfunction pvr2_si2168_attachfunction pvr2_lgdt3306a_attachfunction pvr2_dual_fe_attach
Annotated Snippet
// SPDX-License-Identifier: GPL-2.0-only
/*
*
* Copyright (C) 2007 Mike Isely <isely@pobox.com>
*/
/*
This source file should encompass ALL per-device type information for the
driver. To define a new device, add elements to the pvr2_device_table and
pvr2_device_desc structures.
*/
#include "pvrusb2-devattr.h"
#include <linux/usb.h>
#include <linux/module.h>
/* This is needed in order to pull in tuner type ids... */
#include <linux/i2c.h>
#include <media/tuner.h>
#ifdef CONFIG_VIDEO_PVRUSB2_DVB
#include "pvrusb2-hdw-internal.h"
#include "lgdt330x.h"
#include "s5h1409.h"
#include "s5h1411.h"
#include "tda10048.h"
#include "tda18271.h"
#include "tda8290.h"
#include "tuner-simple.h"
#include "si2157.h"
#include "lgdt3306a.h"
#include "si2168.h"
#endif
/*------------------------------------------------------------------------*/
/* Hauppauge PVR-USB2 Model 29xxx */
static const struct pvr2_device_client_desc pvr2_cli_29xxx[] = {
{ .module_id = PVR2_CLIENT_ID_SAA7115 },
{ .module_id = PVR2_CLIENT_ID_MSP3400 },
{ .module_id = PVR2_CLIENT_ID_TUNER },
{ .module_id = PVR2_CLIENT_ID_DEMOD },
};
#define PVR2_FIRMWARE_29xxx "v4l-pvrusb2-29xxx-01.fw"
static const char *pvr2_fw1_names_29xxx[] = {
PVR2_FIRMWARE_29xxx,
};
static const struct pvr2_device_desc pvr2_device_29xxx = {
.description = "WinTV PVR USB2 Model 29xxx",
.shortname = "29xxx",
.client_table.lst = pvr2_cli_29xxx,
.client_table.cnt = ARRAY_SIZE(pvr2_cli_29xxx),
.fx2_firmware.lst = pvr2_fw1_names_29xxx,
.fx2_firmware.cnt = ARRAY_SIZE(pvr2_fw1_names_29xxx),
.flag_has_hauppauge_rom = !0,
.flag_has_analogtuner = !0,
.flag_has_fmradio = !0,
.flag_has_composite = !0,
.flag_has_svideo = !0,
.signal_routing_scheme = PVR2_ROUTING_SCHEME_HAUPPAUGE,
.led_scheme = PVR2_LED_SCHEME_HAUPPAUGE,
.ir_scheme = PVR2_IR_SCHEME_29XXX,
};
/*------------------------------------------------------------------------*/
/* Hauppauge PVR-USB2 Model 24xxx */
static const struct pvr2_device_client_desc pvr2_cli_24xxx[] = {
{ .module_id = PVR2_CLIENT_ID_CX25840 },
{ .module_id = PVR2_CLIENT_ID_TUNER },
{ .module_id = PVR2_CLIENT_ID_WM8775 },
{ .module_id = PVR2_CLIENT_ID_DEMOD },
};
#define PVR2_FIRMWARE_24xxx "v4l-pvrusb2-24xxx-01.fw"
static const char *pvr2_fw1_names_24xxx[] = {
PVR2_FIRMWARE_24xxx,
};
static const struct pvr2_device_desc pvr2_device_24xxx = {
.description = "WinTV PVR USB2 Model 24xxx",
.shortname = "24xxx",
.client_table.lst = pvr2_cli_24xxx,
.client_table.cnt = ARRAY_SIZE(pvr2_cli_24xxx),
.fx2_firmware.lst = pvr2_fw1_names_24xxx,
Annotation
- Immediate include surface: `pvrusb2-devattr.h`, `linux/usb.h`, `linux/module.h`, `linux/i2c.h`, `media/tuner.h`, `pvrusb2-hdw-internal.h`, `lgdt330x.h`, `s5h1409.h`.
- Detected declarations: `function pvr2_lgdt3303_attach`, `function pvr2_lgh06xf_attach`, `function pvr2_lgdt3302_attach`, `function pvr2_fcv1236d_attach`, `function pvr2_tda10048_attach`, `function pvr2_73xxx_tda18271_8295_attach`, `function pvr2_s5h1409_attach`, `function pvr2_s5h1411_attach`, `function pvr2_tda18271_8295_attach`, `function pvr2_si2157_attach`.
- Atlas domain: Driver Families / drivers/media.
- 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.