summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoragiri <none@none>2005-06-20 17:46:34 -0700
committeragiri <none@none>2005-06-20 17:46:34 -0700
commitabdbd06dc090fa6a49e129523156a8fc75b1868d (patch)
treefa9dcc9200097b983f2a427891f018d7c11be04d
parentf7ccf9b33cfadfb8dd726ebf0894960cb7982a75 (diff)
downloadillumos-joyent-abdbd06dc090fa6a49e129523156a8fc75b1868d.tar.gz
6272642 gcc and ADII don't get along
-rw-r--r--usr/src/uts/common/io/pci_intr_lib.c28
-rw-r--r--usr/src/uts/common/io/usb/hcd/ehci/ehci.c2
-rw-r--r--usr/src/uts/common/io/usb/hcd/openhci/ohci.c2
-rw-r--r--usr/src/uts/common/io/usb/hcd/uhci/uhci.c2
-rw-r--r--usr/src/uts/common/io/usb/usba/hcdi.c2
-rw-r--r--usr/src/uts/common/os/ddi_intr.c10
-rw-r--r--usr/src/uts/common/os/sunddi.c4
-rw-r--r--usr/src/uts/common/pcmcia/nexus/pcmcia.c4
8 files changed, 27 insertions, 27 deletions
diff --git a/usr/src/uts/common/io/pci_intr_lib.c b/usr/src/uts/common/io/pci_intr_lib.c
index eea87364bd..eaf8b6d761 100644
--- a/usr/src/uts/common/io/pci_intr_lib.c
+++ b/usr/src/uts/common/io/pci_intr_lib.c
@@ -244,11 +244,11 @@ pci_msi_configure(dev_info_t *rdip, int type, int count, int inum,
pci_config_get16(cfg_hdle, caps_ptr + PCI_MSI_CTRL)));
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
ddi_intr_msix_t *msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr +
+ off = (uintptr_t)msix_p->msix_tbl_addr +
((inum - 1) * PCI_MSIX_VECTOR_SIZE);
/* Set the "data" and "addr" bits */
@@ -304,11 +304,11 @@ pci_msi_unconfigure(dev_info_t *rdip, int type, int inum)
pci_config_get16(cfg_hdle, caps_ptr + PCI_MSI_CTRL)));
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
ddi_intr_msix_t *msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr +
+ off = (uintptr_t)msix_p->msix_tbl_addr +
((inum - 1) * PCI_MSIX_VECTOR_SIZE);
/* Reset the "data" and "addr" bits */
@@ -394,7 +394,7 @@ pci_msi_enable_mode(dev_info_t *rdip, int type, int inum)
caps_ptr + PCI_MSI_CTRL, msi_ctrl);
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
uint32_t mask_bits;
ddi_intr_msix_t *msix_p;
@@ -408,7 +408,7 @@ pci_msi_enable_mode(dev_info_t *rdip, int type, int inum)
msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr + ((inum - 1) *
+ off = (uintptr_t)msix_p->msix_tbl_addr + ((inum - 1) *
PCI_MSIX_VECTOR_SIZE) + PCI_MSIX_VECTOR_CTRL_OFFSET;
/* Clear the Mask bit */
@@ -457,7 +457,7 @@ pci_msi_disable_mode(dev_info_t *rdip, int type, int inum)
pci_config_put16(cfg_hdle,
caps_ptr + PCI_MSI_CTRL, msi_ctrl);
} else if (type == DDI_INTR_TYPE_MSIX) {
- offset_t off;
+ uintptr_t off;
ddi_intr_msix_t *msix_p;
if (!(msi_ctrl & PCI_MSIX_ENABLE_BIT))
@@ -466,7 +466,7 @@ pci_msi_disable_mode(dev_info_t *rdip, int type, int inum)
msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr + ((inum - 1) *
+ off = (uintptr_t)msix_p->msix_tbl_addr + ((inum - 1) *
PCI_MSIX_VECTOR_SIZE) + PCI_MSIX_VECTOR_CTRL_OFFSET;
/* Set the Mask bit */
@@ -521,7 +521,7 @@ pci_msi_set_mask(dev_info_t *rdip, int type, int inum)
caps_ptr + offset, mask_bits);
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
ddi_intr_msix_t *msix_p;
/* Set function mask */
@@ -533,7 +533,7 @@ pci_msi_set_mask(dev_info_t *rdip, int type, int inum)
msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr + ((inum - 1) *
+ off = (uintptr_t)msix_p->msix_tbl_addr + ((inum - 1) *
PCI_MSIX_VECTOR_SIZE) + PCI_MSIX_VECTOR_CTRL_OFFSET;
/* Set the Mask bit */
@@ -585,7 +585,7 @@ pci_msi_clr_mask(dev_info_t *rdip, int type, int inum)
caps_ptr + offset, mask_bits);
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
ddi_intr_msix_t *msix_p;
if (msi_ctrl & PCI_MSIX_FUNCTION_MASK) {
@@ -596,7 +596,7 @@ pci_msi_clr_mask(dev_info_t *rdip, int type, int inum)
msix_p = i_ddi_get_msix(rdip);
/* Offset into the "inum"th entry in the MSI-X table */
- off = (uint64_t)msix_p->msix_tbl_addr + ((inum - 1) *
+ off = (uintptr_t)msix_p->msix_tbl_addr + ((inum - 1) *
PCI_MSIX_VECTOR_SIZE) + PCI_MSIX_VECTOR_CTRL_OFFSET;
/* Clear the Mask bit */
@@ -655,12 +655,12 @@ pci_msi_get_pending(dev_info_t *rdip, int type, int inum, int *pendingp)
*pendingp = pending_bits & ~(1 >> inum);
} else if (type == DDI_INTR_TYPE_MSIX) {
- uint64_t off;
+ uintptr_t off;
uint64_t pending_bits;
ddi_intr_msix_t *msix_p = i_ddi_get_msix(rdip);
/* Offset into the PBA array which has entry for "inum" */
- off = (uint64_t)msix_p->msix_pba_addr + ((inum - 1) / 64);
+ off = (uintptr_t)msix_p->msix_pba_addr + ((inum - 1) / 64);
/* Read the PBA array */
pending_bits = ddi_get64(msix_p->msix_pba_hdl,
diff --git a/usr/src/uts/common/io/usb/hcd/ehci/ehci.c b/usr/src/uts/common/io/usb/hcd/ehci/ehci.c
index 903686c812..18e1f4e27c 100644
--- a/usr/src/uts/common/io/usb/hcd/ehci/ehci.c
+++ b/usr/src/uts/common/io/usb/hcd/ehci/ehci.c
@@ -318,7 +318,7 @@ ehci_attach(dev_info_t *dip,
* could just go)
*/
hcdi_args.usba_hcdi_register_iblock_cookie =
- (ddi_iblock_cookie_t)(uint64_t)ehcip->ehci_intr_pri;
+ (ddi_iblock_cookie_t)(uintptr_t)ehcip->ehci_intr_pri;
if (usba_hcdi_register(&hcdi_args, 0) != DDI_SUCCESS) {
(void) ehci_cleanup(ehcip);
diff --git a/usr/src/uts/common/io/usb/hcd/openhci/ohci.c b/usr/src/uts/common/io/usb/hcd/openhci/ohci.c
index 424dcc4216..2e717d7fe0 100644
--- a/usr/src/uts/common/io/usb/hcd/openhci/ohci.c
+++ b/usr/src/uts/common/io/usb/hcd/openhci/ohci.c
@@ -686,7 +686,7 @@ ohci_attach(dev_info_t *dip,
* could just go)
*/
hcdi_args.usba_hcdi_register_iblock_cookie =
- (ddi_iblock_cookie_t)(uint64_t)ohcip->ohci_intr_pri;
+ (ddi_iblock_cookie_t)(uintptr_t)ohcip->ohci_intr_pri;
if (usba_hcdi_register(&hcdi_args, 0) != DDI_SUCCESS) {
(void) ohci_cleanup(ohcip);
diff --git a/usr/src/uts/common/io/usb/hcd/uhci/uhci.c b/usr/src/uts/common/io/usb/hcd/uhci/uhci.c
index 8ed7d18f5d..6791ff8b1d 100644
--- a/usr/src/uts/common/io/usb/hcd/uhci/uhci.c
+++ b/usr/src/uts/common/io/usb/hcd/uhci/uhci.c
@@ -381,7 +381,7 @@ uhci_attach(dev_info_t *dip, ddi_attach_cmd_t cmd)
hcdi_args.usba_hcdi_register_ops = uhcip->uhci_hcdi_ops;
hcdi_args.usba_hcdi_register_dma_attr = &uhcip->uhci_dma_attr;
hcdi_args.usba_hcdi_register_iblock_cookie =
- (ddi_iblock_cookie_t)(uint64_t)intr_pri;
+ (ddi_iblock_cookie_t)(uintptr_t)intr_pri;
if (usba_hcdi_register(&hcdi_args, 0) != USB_SUCCESS) {
diff --git a/usr/src/uts/common/io/usb/usba/hcdi.c b/usr/src/uts/common/io/usb/usba/hcdi.c
index 9d8af62e62..84c87daead 100644
--- a/usr/src/uts/common/io/usb/usba/hcdi.c
+++ b/usr/src/uts/common/io/usb/usba/hcdi.c
@@ -167,7 +167,7 @@ usba_hcdi_register(usba_hcdi_register_args_t *args, uint_t flags)
* could just go)
*/
hcdi->hcdi_soft_iblock_cookie =
- (ddi_iblock_cookie_t)(uint64_t)soft_prip;
+ (ddi_iblock_cookie_t)(uintptr_t)soft_prip;
usba_init_list(&hcdi->hcdi_cb_queue, NULL, NULL);
diff --git a/usr/src/uts/common/os/ddi_intr.c b/usr/src/uts/common/os/ddi_intr.c
index 13402b5aa6..8d146a8fde 100644
--- a/usr/src/uts/common/os/ddi_intr.c
+++ b/usr/src/uts/common/os/ddi_intr.c
@@ -1207,7 +1207,7 @@ ddi_get_iblock_cookie(dev_info_t *dip, uint_t inumber,
return (DDI_FAILURE);
}
- *iblock_cookiep = (ddi_iblock_cookie_t)(uint64_t)pri;
+ *iblock_cookiep = (ddi_iblock_cookie_t)(uintptr_t)pri;
/* Free the handle allocated here only if no existing handle exists */
if (existing_hdlp == NULL)
(void) ddi_intr_free(hdl);
@@ -1267,7 +1267,7 @@ ddi_add_intr(dev_info_t *dip, uint_t inumber,
}
if (iblock_cookiep)
- *iblock_cookiep = (ddi_iblock_cookie_t)(uint64_t)pri;
+ *iblock_cookiep = (ddi_iblock_cookie_t)(uintptr_t)pri;
if (idevice_cookiep) {
idevice_cookiep->idev_vector = 0;
@@ -1349,7 +1349,7 @@ ddi_get_soft_iblock_cookie(dev_info_t *dip, int preference,
if (preference == DDI_SOFTINT_FIXED)
return (DDI_FAILURE);
- *iblock_cookiep = (ddi_iblock_cookie_t)((uint64_t)
+ *iblock_cookiep = (ddi_iblock_cookie_t)((uintptr_t)
((preference > DDI_SOFTINT_MED) ? DDI_SOFT_INTR_PRI_H :
DDI_SOFT_INTR_PRI_M));
@@ -1377,7 +1377,7 @@ ddi_add_softintr(dev_info_t *dip, int preference, ddi_softintr_t *idp,
/* Translate the priority preference */
if (preference == DDI_SOFTINT_FIXED) {
- softpri = (uint64_t)*iblock_cookiep;
+ softpri = *((uint64_t *)iblock_cookiep);
softpri = MIN(softpri, DDI_SOFT_INTR_PRI_H);
} else {
softpri = (uint64_t)((preference > DDI_SOFTINT_MED) ?
@@ -1399,7 +1399,7 @@ ddi_add_softintr(dev_info_t *dip, int preference, ddi_softintr_t *idp,
}
if (iblock_cookiep)
- *iblock_cookiep = (ddi_iblock_cookie_t)softpri;
+ *iblock_cookiep = *((ddi_iblock_cookie_t *)(&softpri));
if (idevice_cookiep) {
idevice_cookiep->idev_vector = 0;
diff --git a/usr/src/uts/common/os/sunddi.c b/usr/src/uts/common/os/sunddi.c
index e30c1fccb3..ab38b8edf5 100644
--- a/usr/src/uts/common/os/sunddi.c
+++ b/usr/src/uts/common/os/sunddi.c
@@ -316,7 +316,7 @@ i_ddi_peekpoke(dev_info_t *devi, ddi_ctl_enum_t cmd, size_t size,
/* Note: size is assumed to be correct; it is not checked. */
peekpoke_args.size = size;
- peekpoke_args.dev_addr = (uint64_t)addr;
+ peekpoke_args.dev_addr = (uintptr_t)addr;
peekpoke_args.handle = NULL;
peekpoke_args.repcount = 1;
peekpoke_args.flags = 0;
@@ -338,7 +338,7 @@ i_ddi_peekpoke(dev_info_t *devi, ddi_ctl_enum_t cmd, size_t size,
}
}
- peekpoke_args.host_addr = (uint64_t)&peekpoke_value.u64;
+ peekpoke_args.host_addr = (uintptr_t)&peekpoke_value.u64;
if (devi != NULL)
rval = ddi_ctlops(devi, devi, cmd, &peekpoke_args,
diff --git a/usr/src/uts/common/pcmcia/nexus/pcmcia.c b/usr/src/uts/common/pcmcia/nexus/pcmcia.c
index c6c88dc45c..ca4e8bddfc 100644
--- a/usr/src/uts/common/pcmcia/nexus/pcmcia.c
+++ b/usr/src/uts/common/pcmcia/nexus/pcmcia.c
@@ -5189,7 +5189,7 @@ pcmcia_intr_enable_isr(dev_info_t *dip, dev_info_t *rdip,
mutex_exit(&sockp->ls_ilock);
hdlp->ih_vector = ispecp->intrspec_vec = sockp->ls_intr_vec;
hdlp->ih_pri = sockp->ls_intr_pri;
- sockp->ls_iblk = (ddi_iblock_cookie_t)(uint64_t)
+ sockp->ls_iblk = (ddi_iblock_cookie_t)(uintptr_t)
sockp->ls_intr_pri;
sockp->ls_idev.idev_vector = (ushort_t)hdlp->ih_vector;
sockp->ls_idev.idev_priority = (ushort_t)sockp->ls_intr_pri;
@@ -5209,7 +5209,7 @@ pcmcia_intr_enable_isr(dev_info_t *dip, dev_info_t *rdip,
ret = (*(DEVI(parent)->devi_ops->devo_bus_ops->bus_intr_op))(
parent, rdip, DDI_INTROP_ENABLE, hdlp, NULL);
- sockp->ls_iblk = (ddi_iblock_cookie_t)(uint64_t)
+ sockp->ls_iblk = (ddi_iblock_cookie_t)(uintptr_t)
sockp->ls_intr_pri;
sockp->ls_idev.idev_vector = (ushort_t)sockp->ls_intr_vec;
sockp->ls_idev.idev_priority = (ushort_t)sockp->ls_intr_pri;