Commit 80da1adb authored by Al Viro's avatar Al Viro Committed by Linus Torvalds

trivial annotations in arcmsr

driver still has serious portability problems
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent d06f6082
...@@ -141,14 +141,14 @@ struct CMD_MESSAGE_FIELD ...@@ -141,14 +141,14 @@ struct CMD_MESSAGE_FIELD
#define IS_SG64_ADDR 0x01000000 /* bit24 */ #define IS_SG64_ADDR 0x01000000 /* bit24 */
struct SG32ENTRY struct SG32ENTRY
{ {
uint32_t length; __le32 length;
uint32_t address; __le32 address;
}; };
struct SG64ENTRY struct SG64ENTRY
{ {
uint32_t length; __le32 length;
uint32_t address; __le32 address;
uint32_t addresshigh; __le32 addresshigh;
}; };
struct SGENTRY_UNION struct SGENTRY_UNION
{ {
...@@ -339,13 +339,13 @@ struct MessageUnit_B ...@@ -339,13 +339,13 @@ struct MessageUnit_B
uint32_t done_qbuffer[ARCMSR_MAX_HBB_POSTQUEUE]; uint32_t done_qbuffer[ARCMSR_MAX_HBB_POSTQUEUE];
uint32_t postq_index; uint32_t postq_index;
uint32_t doneq_index; uint32_t doneq_index;
uint32_t *drv2iop_doorbell_reg; uint32_t __iomem *drv2iop_doorbell_reg;
uint32_t *drv2iop_doorbell_mask_reg; uint32_t __iomem *drv2iop_doorbell_mask_reg;
uint32_t *iop2drv_doorbell_reg; uint32_t __iomem *iop2drv_doorbell_reg;
uint32_t *iop2drv_doorbell_mask_reg; uint32_t __iomem *iop2drv_doorbell_mask_reg;
uint32_t *msgcode_rwbuffer_reg; uint32_t __iomem *msgcode_rwbuffer_reg;
uint32_t *ioctl_wbuffer_reg; uint32_t __iomem *ioctl_wbuffer_reg;
uint32_t *ioctl_rbuffer_reg; uint32_t __iomem *ioctl_rbuffer_reg;
}; };
struct MessageUnit struct MessageUnit
...@@ -374,7 +374,11 @@ struct AdapterControlBlock ...@@ -374,7 +374,11 @@ struct AdapterControlBlock
/* Offset is used in making arc cdb physical to virtual calculations */ /* Offset is used in making arc cdb physical to virtual calculations */
uint32_t outbound_int_enable; uint32_t outbound_int_enable;
struct MessageUnit * pmu; union {
struct MessageUnit * pmu;
struct MessageUnit_A __iomem * pmuA;
struct MessageUnit_B * pmuB;
};
/* message unit ATU inbound base address0 */ /* message unit ATU inbound base address0 */
uint32_t acb_flags; uint32_t acb_flags;
...@@ -558,7 +562,7 @@ struct SENSE_DATA ...@@ -558,7 +562,7 @@ struct SENSE_DATA
extern void arcmsr_post_ioctldata2iop(struct AdapterControlBlock *); extern void arcmsr_post_ioctldata2iop(struct AdapterControlBlock *);
extern void arcmsr_iop_message_read(struct AdapterControlBlock *); extern void arcmsr_iop_message_read(struct AdapterControlBlock *);
extern struct QBUFFER *arcmsr_get_iop_rqbuffer(struct AdapterControlBlock *); extern struct QBUFFER __iomem *arcmsr_get_iop_rqbuffer(struct AdapterControlBlock *);
extern struct class_device_attribute *arcmsr_host_attrs[]; extern struct class_device_attribute *arcmsr_host_attrs[];
extern int arcmsr_alloc_sysfs_attr(struct AdapterControlBlock *); extern int arcmsr_alloc_sysfs_attr(struct AdapterControlBlock *);
void arcmsr_free_sysfs_attr(struct AdapterControlBlock *acb); void arcmsr_free_sysfs_attr(struct AdapterControlBlock *acb);
...@@ -85,13 +85,13 @@ static ssize_t arcmsr_sysfs_iop_message_read(struct kobject *kobj, ...@@ -85,13 +85,13 @@ static ssize_t arcmsr_sysfs_iop_message_read(struct kobject *kobj,
allxfer_len++; allxfer_len++;
} }
if (acb->acb_flags & ACB_F_IOPDATA_OVERFLOW) { if (acb->acb_flags & ACB_F_IOPDATA_OVERFLOW) {
struct QBUFFER *prbuffer; struct QBUFFER __iomem *prbuffer;
uint8_t *iop_data; uint8_t __iomem *iop_data;
int32_t iop_len; int32_t iop_len;
acb->acb_flags &= ~ACB_F_IOPDATA_OVERFLOW; acb->acb_flags &= ~ACB_F_IOPDATA_OVERFLOW;
prbuffer = arcmsr_get_iop_rqbuffer(acb); prbuffer = arcmsr_get_iop_rqbuffer(acb);
iop_data = (uint8_t *)prbuffer->data; iop_data = prbuffer->data;
iop_len = readl(&prbuffer->data_len); iop_len = readl(&prbuffer->data_len);
while (iop_len > 0) { while (iop_len > 0) {
acb->rqbuffer[acb->rqbuf_lastindex] = readb(iop_data); acb->rqbuffer[acb->rqbuf_lastindex] = readb(iop_data);
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment