drivers/scsi/pcmcia/qlogic_stub.c
Source file repositories/reference/linux-study-clean/drivers/scsi/pcmcia/qlogic_stub.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/scsi/pcmcia/qlogic_stub.c- Extension
.c- Size
- 9403 bytes
- Lines
- 314
- Domain
- Driver Families
- Bucket
- drivers/scsi
- 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.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/module.hlinux/init.hlinux/kernel.hlinux/slab.hlinux/string.hlinux/ioport.hasm/io.hlinux/major.hlinux/blkdev.hlinux/interrupt.hscsi/scsi.hscsi/scsi_cmnd.hscsi/scsi_device.hscsi/scsi_eh.hscsi/scsi_host.hscsi/scsi_ioctl.hscsi/scsi_tcq.h../qlogicfas408.hpcmcia/cistpl.hpcmcia/ds.hpcmcia/ciscode.h
Detected Declarations
function qlogic_probefunction qlogic_detachfunction qlogic_config_checkfunction qlogic_configfunction qlogic_releasefunction qlogic_resume
Annotated Snippet
A driver for the Qlogic SCSI card
qlogic_cs.c 1.79 2000/06/12 21:27:26
The contents of this file are subject to the Mozilla Public
License Version 1.1 (the "License"); you may not use this file
except in compliance with the License. You may obtain a copy of
the License at http://www.mozilla.org/MPL/
Software distributed under the License is distributed on an "AS
IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
implied. See the License for the specific language governing
rights and limitations under the License.
The initial developer of the original code is David A. Hinds
<dahinds@users.sourceforge.net>. Portions created by David A. Hinds
are Copyright (C) 1999 David A. Hinds. All Rights Reserved.
Alternatively, the contents of this file may be used under the
terms of the GNU General Public License version 2 (the "GPL"), in which
case the provisions of the GPL are applicable instead of the
above. If you wish to allow the use of your version of this file
only under the terms of the GPL and not to allow others to use
your version of this file under the MPL, indicate your decision
by deleting the provisions above and replace them with the notice
and other provisions required by the GPL. If you do not delete
the provisions above, a recipient may use your version of this
file under either the MPL or the GPL.
======================================================================*/
#include <linux/module.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/ioport.h>
#include <asm/io.h>
#include <linux/major.h>
#include <linux/blkdev.h>
#include <linux/interrupt.h>
#include <scsi/scsi.h>
#include <scsi/scsi_cmnd.h>
#include <scsi/scsi_device.h>
#include <scsi/scsi_eh.h>
#include <scsi/scsi_host.h>
#include <scsi/scsi_ioctl.h>
#include <scsi/scsi_tcq.h>
#include "../qlogicfas408.h"
#include <pcmcia/cistpl.h>
#include <pcmcia/ds.h>
#include <pcmcia/ciscode.h>
/* Set the following to 2 to use normal interrupt (active high/totempole-
* tristate), otherwise use 0 (REQUIRED FOR PCMCIA) for active low, open
* drain
*/
#define INT_TYPE 0
static char qlogic_name[] = "qlogic_cs";
static struct scsi_host_template qlogicfas_driver_template = {
.module = THIS_MODULE,
.name = qlogic_name,
.proc_name = qlogic_name,
.info = qlogicfas408_info,
.queuecommand = qlogicfas408_queuecommand,
.eh_abort_handler = qlogicfas408_abort,
.eh_host_reset_handler = qlogicfas408_host_reset,
.bios_param = qlogicfas408_biosparam,
.can_queue = 1,
.this_id = -1,
.sg_tablesize = SG_ALL,
.dma_boundary = PAGE_SIZE - 1,
};
/*====================================================================*/
typedef struct scsi_info_t {
struct pcmcia_device *p_dev;
struct Scsi_Host *host;
unsigned short manf_id;
} scsi_info_t;
static void qlogic_release(struct pcmcia_device *link);
static void qlogic_detach(struct pcmcia_device *p_dev);
static int qlogic_config(struct pcmcia_device * link);
Annotation
- Immediate include surface: `linux/module.h`, `linux/init.h`, `linux/kernel.h`, `linux/slab.h`, `linux/string.h`, `linux/ioport.h`, `asm/io.h`, `linux/major.h`.
- Detected declarations: `function qlogic_probe`, `function qlogic_detach`, `function qlogic_config_check`, `function qlogic_config`, `function qlogic_release`, `function qlogic_resume`.
- Atlas domain: Driver Families / drivers/scsi.
- Implementation status: source implementation candidate.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
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.