diff options
Diffstat (limited to 'drivers/block')
-rw-r--r-- | drivers/block/DAC960.c | 13 | ||||
-rw-r--r-- | drivers/block/cciss_scsi.c | 6 |
2 files changed, 10 insertions, 9 deletions
diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c index 45bcda544880..dd8a1501142f 100644 --- a/drivers/block/DAC960.c +++ b/drivers/block/DAC960.c | |||
@@ -17,8 +17,8 @@ | |||
17 | */ | 17 | */ |
18 | 18 | ||
19 | 19 | ||
20 | #define DAC960_DriverVersion "2.5.47" | 20 | #define DAC960_DriverVersion "2.5.48" |
21 | #define DAC960_DriverDate "14 November 2002" | 21 | #define DAC960_DriverDate "14 May 2006" |
22 | 22 | ||
23 | 23 | ||
24 | #include <linux/module.h> | 24 | #include <linux/module.h> |
@@ -4780,15 +4780,16 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4780 | (NewPhysicalDeviceInfo->LogicalUnit != | 4780 | (NewPhysicalDeviceInfo->LogicalUnit != |
4781 | PhysicalDeviceInfo->LogicalUnit)) | 4781 | PhysicalDeviceInfo->LogicalUnit)) |
4782 | { | 4782 | { |
4783 | PhysicalDeviceInfo = (DAC960_V2_PhysicalDeviceInfo_T *) | 4783 | PhysicalDeviceInfo = |
4784 | kmalloc(sizeof(DAC960_V2_PhysicalDeviceInfo_T), GFP_ATOMIC); | 4784 | kmalloc(sizeof(DAC960_V2_PhysicalDeviceInfo_T), GFP_ATOMIC); |
4785 | InquiryUnitSerialNumber = | 4785 | InquiryUnitSerialNumber = |
4786 | (DAC960_SCSI_Inquiry_UnitSerialNumber_T *) | ||
4787 | kmalloc(sizeof(DAC960_SCSI_Inquiry_UnitSerialNumber_T), | 4786 | kmalloc(sizeof(DAC960_SCSI_Inquiry_UnitSerialNumber_T), |
4788 | GFP_ATOMIC); | 4787 | GFP_ATOMIC); |
4789 | if (InquiryUnitSerialNumber == NULL && | 4788 | if (InquiryUnitSerialNumber == NULL || |
4790 | PhysicalDeviceInfo != NULL) | 4789 | PhysicalDeviceInfo == NULL) |
4791 | { | 4790 | { |
4791 | kfree(InquiryUnitSerialNumber); | ||
4792 | InquiryUnitSerialNumber = NULL; | ||
4792 | kfree(PhysicalDeviceInfo); | 4793 | kfree(PhysicalDeviceInfo); |
4793 | PhysicalDeviceInfo = NULL; | 4794 | PhysicalDeviceInfo = NULL; |
4794 | } | 4795 | } |
diff --git a/drivers/block/cciss_scsi.c b/drivers/block/cciss_scsi.c index 597c007fe81b..afdff32f6724 100644 --- a/drivers/block/cciss_scsi.c +++ b/drivers/block/cciss_scsi.c | |||
@@ -578,7 +578,7 @@ complete_scsi_command( CommandList_struct *cp, int timeout, __u32 tag) | |||
578 | 578 | ||
579 | if (cmd->use_sg) { | 579 | if (cmd->use_sg) { |
580 | pci_unmap_sg(ctlr->pdev, | 580 | pci_unmap_sg(ctlr->pdev, |
581 | cmd->buffer, cmd->use_sg, | 581 | cmd->request_buffer, cmd->use_sg, |
582 | cmd->sc_data_direction); | 582 | cmd->sc_data_direction); |
583 | } | 583 | } |
584 | else if (cmd->request_bufflen) { | 584 | else if (cmd->request_bufflen) { |
@@ -1210,7 +1210,7 @@ cciss_scatter_gather(struct pci_dev *pdev, | |||
1210 | struct scsi_cmnd *cmd) | 1210 | struct scsi_cmnd *cmd) |
1211 | { | 1211 | { |
1212 | unsigned int use_sg, nsegs=0, len; | 1212 | unsigned int use_sg, nsegs=0, len; |
1213 | struct scatterlist *scatter = (struct scatterlist *) cmd->buffer; | 1213 | struct scatterlist *scatter = (struct scatterlist *) cmd->request_buffer; |
1214 | __u64 addr64; | 1214 | __u64 addr64; |
1215 | 1215 | ||
1216 | /* is it just one virtual address? */ | 1216 | /* is it just one virtual address? */ |
@@ -1232,7 +1232,7 @@ cciss_scatter_gather(struct pci_dev *pdev, | |||
1232 | } /* else, must be a list of virtual addresses.... */ | 1232 | } /* else, must be a list of virtual addresses.... */ |
1233 | else if (cmd->use_sg <= MAXSGENTRIES) { /* not too many addrs? */ | 1233 | else if (cmd->use_sg <= MAXSGENTRIES) { /* not too many addrs? */ |
1234 | 1234 | ||
1235 | use_sg = pci_map_sg(pdev, cmd->buffer, cmd->use_sg, | 1235 | use_sg = pci_map_sg(pdev, cmd->request_buffer, cmd->use_sg, |
1236 | cmd->sc_data_direction); | 1236 | cmd->sc_data_direction); |
1237 | 1237 | ||
1238 | for (nsegs=0; nsegs < use_sg; nsegs++) { | 1238 | for (nsegs=0; nsegs < use_sg; nsegs++) { |