diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-03-19 12:41:24 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-03-19 12:41:24 -0400 |
commit | 9ce28d827f74d0acdd058bded8bab5309b0f5c8f (patch) | |
tree | 634f22e8df9c7fd3966b3639e3e997436751ca50 /drivers/block/DAC960.c | |
parent | f074ff92b5b26f3a559fab1203c36e140ea8d067 (diff) | |
parent | c16fa4f2ad19908a47c63d8fa436a1178438c7e7 (diff) |
Merge tag 'v3.3' into staging/for_v3.4
* tag 'v3.3': (1646 commits)
Linux 3.3
Don't limit non-nested epoll paths
netfilter: ctnetlink: fix race between delete and timeout expiration
ipv6: Don't dev_hold(dev) in ip6_mc_find_dev_rcu.
nilfs2: fix NULL pointer dereference in nilfs_load_super_block()
nilfs2: clamp ns_r_segments_percentage to [1, 99]
afs: Remote abort can cause BUG in rxrpc code
afs: Read of file returns EBADMSG
C6X: remove dead code from entry.S
wimax/i2400m: fix erroneous NETDEV_TX_BUSY use
net/hyperv: fix erroneous NETDEV_TX_BUSY use
net/usbnet: reserve headroom on rx skbs
bnx2x: fix memory leak in bnx2x_init_firmware()
bnx2x: fix a crash on corrupt firmware file
sch_sfq: revert dont put new flow at the end of flows
ipv6: fix icmp6_dst_alloc()
MAINTAINERS: Add Serge as maintainer of capabilities
drivers/video/backlight/s6e63m0.c: fix corruption storing gamma mode
MAINTAINERS: add entry for exynos mipi display drivers
MAINTAINERS: fix link to Gustavo Padovans tree
...
Diffstat (limited to 'drivers/block/DAC960.c')
-rw-r--r-- | drivers/block/DAC960.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/drivers/block/DAC960.c b/drivers/block/DAC960.c index e086fbbbe853..8db9089127c5 100644 --- a/drivers/block/DAC960.c +++ b/drivers/block/DAC960.c | |||
@@ -1177,7 +1177,8 @@ static bool DAC960_V1_EnableMemoryMailboxInterface(DAC960_Controller_T | |||
1177 | int TimeoutCounter; | 1177 | int TimeoutCounter; |
1178 | int i; | 1178 | int i; |
1179 | 1179 | ||
1180 | 1180 | memset(&CommandMailbox, 0, sizeof(DAC960_V1_CommandMailbox_T)); | |
1181 | |||
1181 | if (pci_set_dma_mask(Controller->PCIDevice, DMA_BIT_MASK(32))) | 1182 | if (pci_set_dma_mask(Controller->PCIDevice, DMA_BIT_MASK(32))) |
1182 | return DAC960_Failure(Controller, "DMA mask out of range"); | 1183 | return DAC960_Failure(Controller, "DMA mask out of range"); |
1183 | Controller->BounceBufferLimit = DMA_BIT_MASK(32); | 1184 | Controller->BounceBufferLimit = DMA_BIT_MASK(32); |
@@ -4627,7 +4628,8 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4627 | DAC960_Controller_T *Controller = Command->Controller; | 4628 | DAC960_Controller_T *Controller = Command->Controller; |
4628 | DAC960_CommandType_T CommandType = Command->CommandType; | 4629 | DAC960_CommandType_T CommandType = Command->CommandType; |
4629 | DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; | 4630 | DAC960_V2_CommandMailbox_T *CommandMailbox = &Command->V2.CommandMailbox; |
4630 | DAC960_V2_IOCTL_Opcode_T CommandOpcode = CommandMailbox->Common.IOCTL_Opcode; | 4631 | DAC960_V2_IOCTL_Opcode_T IOCTLOpcode = CommandMailbox->Common.IOCTL_Opcode; |
4632 | DAC960_V2_CommandOpcode_T CommandOpcode = CommandMailbox->SCSI_10.CommandOpcode; | ||
4631 | DAC960_V2_CommandStatus_T CommandStatus = Command->V2.CommandStatus; | 4633 | DAC960_V2_CommandStatus_T CommandStatus = Command->V2.CommandStatus; |
4632 | 4634 | ||
4633 | if (CommandType == DAC960_ReadCommand || | 4635 | if (CommandType == DAC960_ReadCommand || |
@@ -4699,7 +4701,7 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4699 | { | 4701 | { |
4700 | if (Controller->ShutdownMonitoringTimer) | 4702 | if (Controller->ShutdownMonitoringTimer) |
4701 | return; | 4703 | return; |
4702 | if (CommandOpcode == DAC960_V2_GetControllerInfo) | 4704 | if (IOCTLOpcode == DAC960_V2_GetControllerInfo) |
4703 | { | 4705 | { |
4704 | DAC960_V2_ControllerInfo_T *NewControllerInfo = | 4706 | DAC960_V2_ControllerInfo_T *NewControllerInfo = |
4705 | Controller->V2.NewControllerInformation; | 4707 | Controller->V2.NewControllerInformation; |
@@ -4719,14 +4721,14 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4719 | memcpy(ControllerInfo, NewControllerInfo, | 4721 | memcpy(ControllerInfo, NewControllerInfo, |
4720 | sizeof(DAC960_V2_ControllerInfo_T)); | 4722 | sizeof(DAC960_V2_ControllerInfo_T)); |
4721 | } | 4723 | } |
4722 | else if (CommandOpcode == DAC960_V2_GetEvent) | 4724 | else if (IOCTLOpcode == DAC960_V2_GetEvent) |
4723 | { | 4725 | { |
4724 | if (CommandStatus == DAC960_V2_NormalCompletion) { | 4726 | if (CommandStatus == DAC960_V2_NormalCompletion) { |
4725 | DAC960_V2_ReportEvent(Controller, Controller->V2.Event); | 4727 | DAC960_V2_ReportEvent(Controller, Controller->V2.Event); |
4726 | } | 4728 | } |
4727 | Controller->V2.NextEventSequenceNumber++; | 4729 | Controller->V2.NextEventSequenceNumber++; |
4728 | } | 4730 | } |
4729 | else if (CommandOpcode == DAC960_V2_GetPhysicalDeviceInfoValid && | 4731 | else if (IOCTLOpcode == DAC960_V2_GetPhysicalDeviceInfoValid && |
4730 | CommandStatus == DAC960_V2_NormalCompletion) | 4732 | CommandStatus == DAC960_V2_NormalCompletion) |
4731 | { | 4733 | { |
4732 | DAC960_V2_PhysicalDeviceInfo_T *NewPhysicalDeviceInfo = | 4734 | DAC960_V2_PhysicalDeviceInfo_T *NewPhysicalDeviceInfo = |
@@ -4915,7 +4917,7 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4915 | NewPhysicalDeviceInfo->LogicalUnit++; | 4917 | NewPhysicalDeviceInfo->LogicalUnit++; |
4916 | Controller->V2.PhysicalDeviceIndex++; | 4918 | Controller->V2.PhysicalDeviceIndex++; |
4917 | } | 4919 | } |
4918 | else if (CommandOpcode == DAC960_V2_GetPhysicalDeviceInfoValid) | 4920 | else if (IOCTLOpcode == DAC960_V2_GetPhysicalDeviceInfoValid) |
4919 | { | 4921 | { |
4920 | unsigned int DeviceIndex; | 4922 | unsigned int DeviceIndex; |
4921 | for (DeviceIndex = Controller->V2.PhysicalDeviceIndex; | 4923 | for (DeviceIndex = Controller->V2.PhysicalDeviceIndex; |
@@ -4938,7 +4940,7 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
4938 | } | 4940 | } |
4939 | Controller->V2.NeedPhysicalDeviceInformation = false; | 4941 | Controller->V2.NeedPhysicalDeviceInformation = false; |
4940 | } | 4942 | } |
4941 | else if (CommandOpcode == DAC960_V2_GetLogicalDeviceInfoValid && | 4943 | else if (IOCTLOpcode == DAC960_V2_GetLogicalDeviceInfoValid && |
4942 | CommandStatus == DAC960_V2_NormalCompletion) | 4944 | CommandStatus == DAC960_V2_NormalCompletion) |
4943 | { | 4945 | { |
4944 | DAC960_V2_LogicalDeviceInfo_T *NewLogicalDeviceInfo = | 4946 | DAC960_V2_LogicalDeviceInfo_T *NewLogicalDeviceInfo = |
@@ -5065,7 +5067,7 @@ static void DAC960_V2_ProcessCompletedCommand(DAC960_Command_T *Command) | |||
5065 | [LogicalDeviceNumber] = true; | 5067 | [LogicalDeviceNumber] = true; |
5066 | NewLogicalDeviceInfo->LogicalDeviceNumber++; | 5068 | NewLogicalDeviceInfo->LogicalDeviceNumber++; |
5067 | } | 5069 | } |
5068 | else if (CommandOpcode == DAC960_V2_GetLogicalDeviceInfoValid) | 5070 | else if (IOCTLOpcode == DAC960_V2_GetLogicalDeviceInfoValid) |
5069 | { | 5071 | { |
5070 | int LogicalDriveNumber; | 5072 | int LogicalDriveNumber; |
5071 | for (LogicalDriveNumber = 0; | 5073 | for (LogicalDriveNumber = 0; |