summaryrefslogtreecommitdiffstats
path: root/drivers/char/xilinx_hwicap/buffer_icap.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2008-04-21 15:50:49 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2008-04-21 15:50:49 -0700
commit9a64388d83f6ef08dfff405a9d122e3dbcb6bf38 (patch)
treea77532ce4d6d56be6c6c7f405cd901a0184250fb /drivers/char/xilinx_hwicap/buffer_icap.c
parente80ab411e589e00550e2e6e5a6a02d59cc730357 (diff)
parent14b3ca4022f050f8622ed282b734ddf445464583 (diff)
downloadop-kernel-dev-9a64388d83f6ef08dfff405a9d122e3dbcb6bf38.zip
op-kernel-dev-9a64388d83f6ef08dfff405a9d122e3dbcb6bf38.tar.gz
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc
* 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc: (202 commits) [POWERPC] Fix compile breakage for 64-bit UP configs [POWERPC] Define copy_siginfo_from_user32 [POWERPC] Add compat handler for PTRACE_GETSIGINFO [POWERPC] i2c: Fix build breakage introduced by OF helpers [POWERPC] Optimize fls64() on 64-bit processors [POWERPC] irqtrace support for 64-bit powerpc [POWERPC] Stacktrace support for lockdep [POWERPC] Move stackframe definitions to common header [POWERPC] Fix device-tree locking vs. interrupts [POWERPC] Make pci_bus_to_host()'s struct pci_bus * argument const [POWERPC] Remove unused __max_memory variable [POWERPC] Simplify xics direct/lpar irq_host setup [POWERPC] Use pseries_setup_i8259_cascade() in pseries_mpic_init_IRQ() [POWERPC] Turn xics_setup_8259_cascade() into a generic pseries_setup_i8259_cascade() [POWERPC] Move xics_setup_8259_cascade() into platforms/pseries/setup.c [POWERPC] Use asm-generic/bitops/find.h in bitops.h [POWERPC] 83xx: mpc8315 - fix USB UTMI Host setup [POWERPC] 85xx: Fix the size of qe muram for MPC8568E [POWERPC] 86xx: mpc86xx_hpcn - Temporarily accept old dts node identifier. [POWERPC] 86xx: mark functions static, other minor cleanups ...
Diffstat (limited to 'drivers/char/xilinx_hwicap/buffer_icap.c')
-rw-r--r--drivers/char/xilinx_hwicap/buffer_icap.c22
1 files changed, 5 insertions, 17 deletions
diff --git a/drivers/char/xilinx_hwicap/buffer_icap.c b/drivers/char/xilinx_hwicap/buffer_icap.c
index f577dae..aa7f796 100644
--- a/drivers/char/xilinx_hwicap/buffer_icap.c
+++ b/drivers/char/xilinx_hwicap/buffer_icap.c
@@ -74,7 +74,7 @@
/**
* buffer_icap_get_status - Get the contents of the status register.
- * @base_address: is the base address of the device
+ * @drvdata: a pointer to the drvdata.
*
* The status register contains the ICAP status and the done bit.
*
@@ -88,9 +88,9 @@
* D1 - Always 1
* D0 - Done bit
**/
-static inline u32 buffer_icap_get_status(void __iomem *base_address)
+u32 buffer_icap_get_status(struct hwicap_drvdata *drvdata)
{
- return in_be32(base_address + XHI_STATUS_REG_OFFSET);
+ return in_be32(drvdata->base_address + XHI_STATUS_REG_OFFSET);
}
/**
@@ -117,20 +117,8 @@ static inline u32 buffer_icap_get_bram(void __iomem *base_address,
**/
static inline bool buffer_icap_busy(void __iomem *base_address)
{
- return (buffer_icap_get_status(base_address) & 1) == XHI_NOT_FINISHED;
-}
-
-/**
- * buffer_icap_busy - Return true if the icap device is not busy
- * @base_address: is the base address of the device
- *
- * The queries the low order bit of the status register, which
- * indicates whether the current configuration or readback operation
- * has completed.
- **/
-static inline bool buffer_icap_done(void __iomem *base_address)
-{
- return (buffer_icap_get_status(base_address) & 1) == XHI_FINISHED;
+ u32 status = in_be32(base_address + XHI_STATUS_REG_OFFSET);
+ return (status & 1) == XHI_NOT_FINISHED;
}
/**
OpenPOWER on IntegriCloud