a2091.c (05668381140309088443bf5dc53add4104610fbb) | a2091.c (65396410af63db90d6428c678ff84aa652c3c1ec) |
---|---|
1#include <linux/types.h> 2#include <linux/mm.h> 3#include <linux/blkdev.h> 4#include <linux/sched.h> 5#include <linux/init.h> 6#include <linux/interrupt.h> 7 8#include <asm/setup.h> --- 26 unchanged lines hidden (view full) --- 35 return IRQ_NONE; 36 37 spin_lock_irqsave(instance->host_lock, flags); 38 wd33c93_intr(instance); 39 spin_unlock_irqrestore(instance->host_lock, flags); 40 return IRQ_HANDLED; 41} 42 | 1#include <linux/types.h> 2#include <linux/mm.h> 3#include <linux/blkdev.h> 4#include <linux/sched.h> 5#include <linux/init.h> 6#include <linux/interrupt.h> 7 8#include <asm/setup.h> --- 26 unchanged lines hidden (view full) --- 35 return IRQ_NONE; 36 37 spin_lock_irqsave(instance->host_lock, flags); 38 wd33c93_intr(instance); 39 spin_unlock_irqrestore(instance->host_lock, flags); 40 return IRQ_HANDLED; 41} 42 |
43static int dma_setup (Scsi_Cmnd *cmd, int dir_in) | 43static int dma_setup(struct scsi_cmnd *cmd, int dir_in) |
44{ 45 unsigned short cntr = CNTR_PDMD | CNTR_INTEN; 46 unsigned long addr = virt_to_bus(cmd->SCp.ptr); 47 struct Scsi_Host *instance = cmd->device->host; 48 49 /* don't allow DMA if the physical address is bad */ 50 if (addr & A2091_XFER_MASK || 51 (!dir_in && mm_end_of_chunk (addr, cmd->SCp.this_residual))) --- 58 unchanged lines hidden (view full) --- 110 } 111 /* start DMA */ 112 DMA(cmd->device->host)->ST_DMA = 1; 113 114 /* return success */ 115 return 0; 116} 117 | 44{ 45 unsigned short cntr = CNTR_PDMD | CNTR_INTEN; 46 unsigned long addr = virt_to_bus(cmd->SCp.ptr); 47 struct Scsi_Host *instance = cmd->device->host; 48 49 /* don't allow DMA if the physical address is bad */ 50 if (addr & A2091_XFER_MASK || 51 (!dir_in && mm_end_of_chunk (addr, cmd->SCp.this_residual))) --- 58 unchanged lines hidden (view full) --- 110 } 111 /* start DMA */ 112 DMA(cmd->device->host)->ST_DMA = 1; 113 114 /* return success */ 115 return 0; 116} 117 |
118static void dma_stop (struct Scsi_Host *instance, Scsi_Cmnd *SCpnt, | 118static void dma_stop(struct Scsi_Host *instance, struct scsi_cmnd *SCpnt, |
119 int status) 120{ 121 /* disable SCSI interrupts */ 122 unsigned short cntr = CNTR_PDMD; 123 124 if (!HDATA(instance)->dma_dir) 125 cntr |= CNTR_DDIR; 126 --- 85 unchanged lines hidden (view full) --- 212 instance); 213 DMA(instance)->CNTR = CNTR_PDMD | CNTR_INTEN; 214 num_a2091++; 215 } 216 217 return num_a2091; 218} 219 | 119 int status) 120{ 121 /* disable SCSI interrupts */ 122 unsigned short cntr = CNTR_PDMD; 123 124 if (!HDATA(instance)->dma_dir) 125 cntr |= CNTR_DDIR; 126 --- 85 unchanged lines hidden (view full) --- 212 instance); 213 DMA(instance)->CNTR = CNTR_PDMD | CNTR_INTEN; 214 num_a2091++; 215 } 216 217 return num_a2091; 218} 219 |
220static int a2091_bus_reset(Scsi_Cmnd *cmd) | 220static int a2091_bus_reset(struct scsi_cmnd *cmd) |
221{ 222 /* FIXME perform bus-specific reset */ 223 224 /* FIXME 2: kill this function, and let midlayer fall back 225 to the same action, calling wd33c93_host_reset() */ 226 227 spin_lock_irq(cmd->device->host->host_lock); 228 wd33c93_host_reset(cmd); --- 38 unchanged lines hidden --- | 221{ 222 /* FIXME perform bus-specific reset */ 223 224 /* FIXME 2: kill this function, and let midlayer fall back 225 to the same action, calling wd33c93_host_reset() */ 226 227 spin_lock_irq(cmd->device->host->host_lock); 228 wd33c93_host_reset(cmd); --- 38 unchanged lines hidden --- |