1de6cc651SThomas Gleixner // SPDX-License-Identifier: GPL-2.0-or-later
28b3d6663SArnd Bergmann /* hw_ops.c - query/set operations on active SPU context.
38b3d6663SArnd Bergmann  *
48b3d6663SArnd Bergmann  * Copyright (C) IBM 2005
58b3d6663SArnd Bergmann  * Author: Mark Nutter <mnutter@us.ibm.com>
68b3d6663SArnd Bergmann  */
78b3d6663SArnd Bergmann 
88b3d6663SArnd Bergmann #include <linux/errno.h>
98b3d6663SArnd Bergmann #include <linux/sched.h>
108b3d6663SArnd Bergmann #include <linux/kernel.h>
118b3d6663SArnd Bergmann #include <linux/mm.h>
123a843d7cSArnd Bergmann #include <linux/poll.h>
138b3d6663SArnd Bergmann #include <linux/smp.h>
148b3d6663SArnd Bergmann #include <linux/stddef.h>
158b3d6663SArnd Bergmann #include <linux/unistd.h>
168b3d6663SArnd Bergmann 
178b3d6663SArnd Bergmann #include <asm/io.h>
188b3d6663SArnd Bergmann #include <asm/spu.h>
19540270d8SGeoff Levand #include <asm/spu_priv1.h>
208b3d6663SArnd Bergmann #include <asm/spu_csa.h>
218b3d6663SArnd Bergmann #include <asm/mmu_context.h>
228b3d6663SArnd Bergmann #include "spufs.h"
238b3d6663SArnd Bergmann 
spu_hw_mbox_read(struct spu_context * ctx,u32 * data)248b3d6663SArnd Bergmann static int spu_hw_mbox_read(struct spu_context *ctx, u32 * data)
258b3d6663SArnd Bergmann {
268b3d6663SArnd Bergmann 	struct spu *spu = ctx->spu;
278b3d6663SArnd Bergmann 	struct spu_problem __iomem *prob = spu->problem;
288b3d6663SArnd Bergmann 	u32 mbox_stat;
298b3d6663SArnd Bergmann 	int ret = 0;
308b3d6663SArnd Bergmann 
318b3d6663SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
328b3d6663SArnd Bergmann 	mbox_stat = in_be32(&prob->mb_stat_R);
338b3d6663SArnd Bergmann 	if (mbox_stat & 0x0000ff) {
348b3d6663SArnd Bergmann 		*data = in_be32(&prob->pu_mb_R);
358b3d6663SArnd Bergmann 		ret = 4;
368b3d6663SArnd Bergmann 	}
378b3d6663SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
388b3d6663SArnd Bergmann 	return ret;
398b3d6663SArnd Bergmann }
408b3d6663SArnd Bergmann 
spu_hw_mbox_stat_read(struct spu_context * ctx)418b3d6663SArnd Bergmann static u32 spu_hw_mbox_stat_read(struct spu_context *ctx)
428b3d6663SArnd Bergmann {
438b3d6663SArnd Bergmann 	return in_be32(&ctx->spu->problem->mb_stat_R);
448b3d6663SArnd Bergmann }
458b3d6663SArnd Bergmann 
spu_hw_mbox_stat_poll(struct spu_context * ctx,__poll_t events)468153a5eaSAl Viro static __poll_t spu_hw_mbox_stat_poll(struct spu_context *ctx, __poll_t events)
473a843d7cSArnd Bergmann {
483a843d7cSArnd Bergmann 	struct spu *spu = ctx->spu;
498153a5eaSAl Viro 	__poll_t ret = 0;
503a843d7cSArnd Bergmann 	u32 stat;
513a843d7cSArnd Bergmann 
523a843d7cSArnd Bergmann 	spin_lock_irq(&spu->register_lock);
533a843d7cSArnd Bergmann 	stat = in_be32(&spu->problem->mb_stat_R);
543a843d7cSArnd Bergmann 
553a843d7cSArnd Bergmann 	/* if the requested event is there, return the poll
563a843d7cSArnd Bergmann 	   mask, otherwise enable the interrupt to get notified,
573a843d7cSArnd Bergmann 	   but first mark any pending interrupts as done so
583a843d7cSArnd Bergmann 	   we don't get woken up unnecessarily */
593a843d7cSArnd Bergmann 
60a9a08845SLinus Torvalds 	if (events & (EPOLLIN | EPOLLRDNORM)) {
613a843d7cSArnd Bergmann 		if (stat & 0xff0000)
62a9a08845SLinus Torvalds 			ret |= EPOLLIN | EPOLLRDNORM;
633a843d7cSArnd Bergmann 		else {
648af30675SJeremy Kerr 			spu_int_stat_clear(spu, 2, CLASS2_MAILBOX_INTR);
658af30675SJeremy Kerr 			spu_int_mask_or(spu, 2, CLASS2_ENABLE_MAILBOX_INTR);
663a843d7cSArnd Bergmann 		}
673a843d7cSArnd Bergmann 	}
68a9a08845SLinus Torvalds 	if (events & (EPOLLOUT | EPOLLWRNORM)) {
693a843d7cSArnd Bergmann 		if (stat & 0x00ff00)
70a9a08845SLinus Torvalds 			ret = EPOLLOUT | EPOLLWRNORM;
713a843d7cSArnd Bergmann 		else {
728af30675SJeremy Kerr 			spu_int_stat_clear(spu, 2,
738af30675SJeremy Kerr 					CLASS2_MAILBOX_THRESHOLD_INTR);
748af30675SJeremy Kerr 			spu_int_mask_or(spu, 2,
758af30675SJeremy Kerr 					CLASS2_ENABLE_MAILBOX_THRESHOLD_INTR);
763a843d7cSArnd Bergmann 		}
773a843d7cSArnd Bergmann 	}
783a843d7cSArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
793a843d7cSArnd Bergmann 	return ret;
803a843d7cSArnd Bergmann }
813a843d7cSArnd Bergmann 
spu_hw_ibox_read(struct spu_context * ctx,u32 * data)828b3d6663SArnd Bergmann static int spu_hw_ibox_read(struct spu_context *ctx, u32 * data)
838b3d6663SArnd Bergmann {
848b3d6663SArnd Bergmann 	struct spu *spu = ctx->spu;
858b3d6663SArnd Bergmann 	struct spu_problem __iomem *prob = spu->problem;
868b3d6663SArnd Bergmann 	struct spu_priv2 __iomem *priv2 = spu->priv2;
878b3d6663SArnd Bergmann 	int ret;
888b3d6663SArnd Bergmann 
898b3d6663SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
908b3d6663SArnd Bergmann 	if (in_be32(&prob->mb_stat_R) & 0xff0000) {
918b3d6663SArnd Bergmann 		/* read the first available word */
928b3d6663SArnd Bergmann 		*data = in_be64(&priv2->puint_mb_R);
938b3d6663SArnd Bergmann 		ret = 4;
948b3d6663SArnd Bergmann 	} else {
958b3d6663SArnd Bergmann 		/* make sure we get woken up by the interrupt */
968af30675SJeremy Kerr 		spu_int_mask_or(spu, 2, CLASS2_ENABLE_MAILBOX_INTR);
978b3d6663SArnd Bergmann 		ret = 0;
988b3d6663SArnd Bergmann 	}
998b3d6663SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
1008b3d6663SArnd Bergmann 	return ret;
1018b3d6663SArnd Bergmann }
1028b3d6663SArnd Bergmann 
spu_hw_wbox_write(struct spu_context * ctx,u32 data)1038b3d6663SArnd Bergmann static int spu_hw_wbox_write(struct spu_context *ctx, u32 data)
1048b3d6663SArnd Bergmann {
1058b3d6663SArnd Bergmann 	struct spu *spu = ctx->spu;
1068b3d6663SArnd Bergmann 	struct spu_problem __iomem *prob = spu->problem;
1078b3d6663SArnd Bergmann 	int ret;
1088b3d6663SArnd Bergmann 
1098b3d6663SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
1108b3d6663SArnd Bergmann 	if (in_be32(&prob->mb_stat_R) & 0x00ff00) {
1118b3d6663SArnd Bergmann 		/* we have space to write wbox_data to */
1128b3d6663SArnd Bergmann 		out_be32(&prob->spu_mb_W, data);
1138b3d6663SArnd Bergmann 		ret = 4;
1148b3d6663SArnd Bergmann 	} else {
1158b3d6663SArnd Bergmann 		/* make sure we get woken up by the interrupt when space
1168b3d6663SArnd Bergmann 		   becomes available */
1178af30675SJeremy Kerr 		spu_int_mask_or(spu, 2, CLASS2_ENABLE_MAILBOX_THRESHOLD_INTR);
1188b3d6663SArnd Bergmann 		ret = 0;
1198b3d6663SArnd Bergmann 	}
1208b3d6663SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
1218b3d6663SArnd Bergmann 	return ret;
1228b3d6663SArnd Bergmann }
1238b3d6663SArnd Bergmann 
spu_hw_signal1_write(struct spu_context * ctx,u32 data)1248b3d6663SArnd Bergmann static void spu_hw_signal1_write(struct spu_context *ctx, u32 data)
1258b3d6663SArnd Bergmann {
1268b3d6663SArnd Bergmann 	out_be32(&ctx->spu->problem->signal_notify1, data);
1278b3d6663SArnd Bergmann }
1288b3d6663SArnd Bergmann 
spu_hw_signal2_write(struct spu_context * ctx,u32 data)1298b3d6663SArnd Bergmann static void spu_hw_signal2_write(struct spu_context *ctx, u32 data)
1308b3d6663SArnd Bergmann {
1318b3d6663SArnd Bergmann 	out_be32(&ctx->spu->problem->signal_notify2, data);
1328b3d6663SArnd Bergmann }
1338b3d6663SArnd Bergmann 
spu_hw_signal1_type_set(struct spu_context * ctx,u64 val)1348b3d6663SArnd Bergmann static void spu_hw_signal1_type_set(struct spu_context *ctx, u64 val)
1358b3d6663SArnd Bergmann {
1368b3d6663SArnd Bergmann 	struct spu *spu = ctx->spu;
1378b3d6663SArnd Bergmann 	struct spu_priv2 __iomem *priv2 = spu->priv2;
1388b3d6663SArnd Bergmann 	u64 tmp;
1398b3d6663SArnd Bergmann 
1408b3d6663SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
1418b3d6663SArnd Bergmann 	tmp = in_be64(&priv2->spu_cfg_RW);
1428b3d6663SArnd Bergmann 	if (val)
1438b3d6663SArnd Bergmann 		tmp |= 1;
1448b3d6663SArnd Bergmann 	else
1458b3d6663SArnd Bergmann 		tmp &= ~1;
1468b3d6663SArnd Bergmann 	out_be64(&priv2->spu_cfg_RW, tmp);
1478b3d6663SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
1488b3d6663SArnd Bergmann }
1498b3d6663SArnd Bergmann 
spu_hw_signal1_type_get(struct spu_context * ctx)1508b3d6663SArnd Bergmann static u64 spu_hw_signal1_type_get(struct spu_context *ctx)
1518b3d6663SArnd Bergmann {
1528b3d6663SArnd Bergmann 	return ((in_be64(&ctx->spu->priv2->spu_cfg_RW) & 1) != 0);
1538b3d6663SArnd Bergmann }
1548b3d6663SArnd Bergmann 
spu_hw_signal2_type_set(struct spu_context * ctx,u64 val)1558b3d6663SArnd Bergmann static void spu_hw_signal2_type_set(struct spu_context *ctx, u64 val)
1568b3d6663SArnd Bergmann {
1578b3d6663SArnd Bergmann 	struct spu *spu = ctx->spu;
1588b3d6663SArnd Bergmann 	struct spu_priv2 __iomem *priv2 = spu->priv2;
1598b3d6663SArnd Bergmann 	u64 tmp;
1608b3d6663SArnd Bergmann 
1618b3d6663SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
1628b3d6663SArnd Bergmann 	tmp = in_be64(&priv2->spu_cfg_RW);
1638b3d6663SArnd Bergmann 	if (val)
1648b3d6663SArnd Bergmann 		tmp |= 2;
1658b3d6663SArnd Bergmann 	else
1668b3d6663SArnd Bergmann 		tmp &= ~2;
1678b3d6663SArnd Bergmann 	out_be64(&priv2->spu_cfg_RW, tmp);
1688b3d6663SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
1698b3d6663SArnd Bergmann }
1708b3d6663SArnd Bergmann 
spu_hw_signal2_type_get(struct spu_context * ctx)1718b3d6663SArnd Bergmann static u64 spu_hw_signal2_type_get(struct spu_context *ctx)
1728b3d6663SArnd Bergmann {
1738b3d6663SArnd Bergmann 	return ((in_be64(&ctx->spu->priv2->spu_cfg_RW) & 2) != 0);
1748b3d6663SArnd Bergmann }
1758b3d6663SArnd Bergmann 
spu_hw_npc_read(struct spu_context * ctx)1768b3d6663SArnd Bergmann static u32 spu_hw_npc_read(struct spu_context *ctx)
1778b3d6663SArnd Bergmann {
1788b3d6663SArnd Bergmann 	return in_be32(&ctx->spu->problem->spu_npc_RW);
1798b3d6663SArnd Bergmann }
1808b3d6663SArnd Bergmann 
spu_hw_npc_write(struct spu_context * ctx,u32 val)1818b3d6663SArnd Bergmann static void spu_hw_npc_write(struct spu_context *ctx, u32 val)
1828b3d6663SArnd Bergmann {
1838b3d6663SArnd Bergmann 	out_be32(&ctx->spu->problem->spu_npc_RW, val);
1848b3d6663SArnd Bergmann }
1858b3d6663SArnd Bergmann 
spu_hw_status_read(struct spu_context * ctx)1868b3d6663SArnd Bergmann static u32 spu_hw_status_read(struct spu_context *ctx)
1878b3d6663SArnd Bergmann {
1888b3d6663SArnd Bergmann 	return in_be32(&ctx->spu->problem->spu_status_R);
1898b3d6663SArnd Bergmann }
1908b3d6663SArnd Bergmann 
spu_hw_get_ls(struct spu_context * ctx)1918b3d6663SArnd Bergmann static char *spu_hw_get_ls(struct spu_context *ctx)
1928b3d6663SArnd Bergmann {
1938b3d6663SArnd Bergmann 	return ctx->spu->local_store;
1948b3d6663SArnd Bergmann }
1958b3d6663SArnd Bergmann 
spu_hw_privcntl_write(struct spu_context * ctx,u64 val)196cc210b3eSLuke Browning static void spu_hw_privcntl_write(struct spu_context *ctx, u64 val)
197cc210b3eSLuke Browning {
198cc210b3eSLuke Browning 	out_be64(&ctx->spu->priv2->spu_privcntl_RW, val);
199cc210b3eSLuke Browning }
200cc210b3eSLuke Browning 
spu_hw_runcntl_read(struct spu_context * ctx)2013960c260SJeremy Kerr static u32 spu_hw_runcntl_read(struct spu_context *ctx)
2023960c260SJeremy Kerr {
2033960c260SJeremy Kerr 	return in_be32(&ctx->spu->problem->spu_runcntl_RW);
2043960c260SJeremy Kerr }
2053960c260SJeremy Kerr 
spu_hw_runcntl_write(struct spu_context * ctx,u32 val)2065110459fSArnd Bergmann static void spu_hw_runcntl_write(struct spu_context *ctx, u32 val)
2075110459fSArnd Bergmann {
2085737edd1SMark Nutter 	spin_lock_irq(&ctx->spu->register_lock);
2095737edd1SMark Nutter 	if (val & SPU_RUNCNTL_ISOLATE)
210cc210b3eSLuke Browning 		spu_hw_privcntl_write(ctx,
211cc210b3eSLuke Browning 			SPU_PRIVCNT_LOAD_REQUEST_ENABLE_MASK);
2125110459fSArnd Bergmann 	out_be32(&ctx->spu->problem->spu_runcntl_RW, val);
2135737edd1SMark Nutter 	spin_unlock_irq(&ctx->spu->register_lock);
2145110459fSArnd Bergmann }
2155110459fSArnd Bergmann 
spu_hw_runcntl_stop(struct spu_context * ctx)216c25620d7SMasato Noguchi static void spu_hw_runcntl_stop(struct spu_context *ctx)
217c25620d7SMasato Noguchi {
218c25620d7SMasato Noguchi 	spin_lock_irq(&ctx->spu->register_lock);
219c25620d7SMasato Noguchi 	out_be32(&ctx->spu->problem->spu_runcntl_RW, SPU_RUNCNTL_STOP);
220c25620d7SMasato Noguchi 	while (in_be32(&ctx->spu->problem->spu_status_R) & SPU_STATUS_RUNNING)
221c25620d7SMasato Noguchi 		cpu_relax();
222c25620d7SMasato Noguchi 	spin_unlock_irq(&ctx->spu->register_lock);
223c25620d7SMasato Noguchi }
224c25620d7SMasato Noguchi 
spu_hw_master_start(struct spu_context * ctx)225ee2d7340SArnd Bergmann static void spu_hw_master_start(struct spu_context *ctx)
2265110459fSArnd Bergmann {
227ee2d7340SArnd Bergmann 	struct spu *spu = ctx->spu;
228ee2d7340SArnd Bergmann 	u64 sr1;
229ee2d7340SArnd Bergmann 
230ee2d7340SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
231ee2d7340SArnd Bergmann 	sr1 = spu_mfc_sr1_get(spu) | MFC_STATE1_MASTER_RUN_CONTROL_MASK;
232ee2d7340SArnd Bergmann 	spu_mfc_sr1_set(spu, sr1);
233ee2d7340SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
234ee2d7340SArnd Bergmann }
235ee2d7340SArnd Bergmann 
spu_hw_master_stop(struct spu_context * ctx)236ee2d7340SArnd Bergmann static void spu_hw_master_stop(struct spu_context *ctx)
237ee2d7340SArnd Bergmann {
238ee2d7340SArnd Bergmann 	struct spu *spu = ctx->spu;
239ee2d7340SArnd Bergmann 	u64 sr1;
240ee2d7340SArnd Bergmann 
241ee2d7340SArnd Bergmann 	spin_lock_irq(&spu->register_lock);
242ee2d7340SArnd Bergmann 	sr1 = spu_mfc_sr1_get(spu) & ~MFC_STATE1_MASTER_RUN_CONTROL_MASK;
243ee2d7340SArnd Bergmann 	spu_mfc_sr1_set(spu, sr1);
244ee2d7340SArnd Bergmann 	spin_unlock_irq(&spu->register_lock);
2455110459fSArnd Bergmann }
2465110459fSArnd Bergmann 
spu_hw_set_mfc_query(struct spu_context * ctx,u32 mask,u32 mode)247a33a7d73SArnd Bergmann static int spu_hw_set_mfc_query(struct spu_context * ctx, u32 mask, u32 mode)
248a33a7d73SArnd Bergmann {
249ed2bfcd2SAl Viro 	struct spu_problem __iomem *prob = ctx->spu->problem;
250a33a7d73SArnd Bergmann 	int ret;
251a33a7d73SArnd Bergmann 
252a33a7d73SArnd Bergmann 	spin_lock_irq(&ctx->spu->register_lock);
253a33a7d73SArnd Bergmann 	ret = -EAGAIN;
254a33a7d73SArnd Bergmann 	if (in_be32(&prob->dma_querytype_RW))
255a33a7d73SArnd Bergmann 		goto out;
256a33a7d73SArnd Bergmann 	ret = 0;
257a33a7d73SArnd Bergmann 	out_be32(&prob->dma_querymask_RW, mask);
258a33a7d73SArnd Bergmann 	out_be32(&prob->dma_querytype_RW, mode);
259a33a7d73SArnd Bergmann out:
260a33a7d73SArnd Bergmann 	spin_unlock_irq(&ctx->spu->register_lock);
261a33a7d73SArnd Bergmann 	return ret;
262a33a7d73SArnd Bergmann }
263a33a7d73SArnd Bergmann 
spu_hw_read_mfc_tagstatus(struct spu_context * ctx)264a33a7d73SArnd Bergmann static u32 spu_hw_read_mfc_tagstatus(struct spu_context * ctx)
265a33a7d73SArnd Bergmann {
266a33a7d73SArnd Bergmann 	return in_be32(&ctx->spu->problem->dma_tagstatus_R);
267a33a7d73SArnd Bergmann }
268a33a7d73SArnd Bergmann 
spu_hw_get_mfc_free_elements(struct spu_context * ctx)269a33a7d73SArnd Bergmann static u32 spu_hw_get_mfc_free_elements(struct spu_context *ctx)
270a33a7d73SArnd Bergmann {
271a33a7d73SArnd Bergmann 	return in_be32(&ctx->spu->problem->dma_qstatus_R);
272a33a7d73SArnd Bergmann }
273a33a7d73SArnd Bergmann 
spu_hw_send_mfc_command(struct spu_context * ctx,struct mfc_dma_command * cmd)274a33a7d73SArnd Bergmann static int spu_hw_send_mfc_command(struct spu_context *ctx,
275a33a7d73SArnd Bergmann 					struct mfc_dma_command *cmd)
276a33a7d73SArnd Bergmann {
277a33a7d73SArnd Bergmann 	u32 status;
278ed2bfcd2SAl Viro 	struct spu_problem __iomem *prob = ctx->spu->problem;
279a33a7d73SArnd Bergmann 
280a33a7d73SArnd Bergmann 	spin_lock_irq(&ctx->spu->register_lock);
281a33a7d73SArnd Bergmann 	out_be32(&prob->mfc_lsa_W, cmd->lsa);
282a33a7d73SArnd Bergmann 	out_be64(&prob->mfc_ea_W, cmd->ea);
283a33a7d73SArnd Bergmann 	out_be32(&prob->mfc_union_W.by32.mfc_size_tag32,
284a33a7d73SArnd Bergmann 				cmd->size << 16 | cmd->tag);
285a33a7d73SArnd Bergmann 	out_be32(&prob->mfc_union_W.by32.mfc_class_cmd32,
286a33a7d73SArnd Bergmann 				cmd->class << 16 | cmd->cmd);
287a33a7d73SArnd Bergmann 	status = in_be32(&prob->mfc_union_W.by32.mfc_class_cmd32);
288a33a7d73SArnd Bergmann 	spin_unlock_irq(&ctx->spu->register_lock);
289a33a7d73SArnd Bergmann 
290a33a7d73SArnd Bergmann 	switch (status & 0xffff) {
291a33a7d73SArnd Bergmann 	case 0:
292a33a7d73SArnd Bergmann 		return 0;
293a33a7d73SArnd Bergmann 	case 2:
294a33a7d73SArnd Bergmann 		return -EAGAIN;
295a33a7d73SArnd Bergmann 	default:
296a33a7d73SArnd Bergmann 		return -EINVAL;
297a33a7d73SArnd Bergmann 	}
298a33a7d73SArnd Bergmann }
299a33a7d73SArnd Bergmann 
spu_hw_restart_dma(struct spu_context * ctx)30057dace23SArnd Bergmann static void spu_hw_restart_dma(struct spu_context *ctx)
30157dace23SArnd Bergmann {
30257dace23SArnd Bergmann 	struct spu_priv2 __iomem *priv2 = ctx->spu->priv2;
30357dace23SArnd Bergmann 
30457dace23SArnd Bergmann 	if (!test_bit(SPU_CONTEXT_SWITCH_PENDING, &ctx->spu->flags))
30557dace23SArnd Bergmann 		out_be64(&priv2->mfc_control_RW, MFC_CNTL_RESTART_DMA_COMMAND);
30657dace23SArnd Bergmann }
30757dace23SArnd Bergmann 
3088b3d6663SArnd Bergmann struct spu_context_ops spu_hw_ops = {
3098b3d6663SArnd Bergmann 	.mbox_read = spu_hw_mbox_read,
3108b3d6663SArnd Bergmann 	.mbox_stat_read = spu_hw_mbox_stat_read,
3113a843d7cSArnd Bergmann 	.mbox_stat_poll = spu_hw_mbox_stat_poll,
3128b3d6663SArnd Bergmann 	.ibox_read = spu_hw_ibox_read,
3138b3d6663SArnd Bergmann 	.wbox_write = spu_hw_wbox_write,
3148b3d6663SArnd Bergmann 	.signal1_write = spu_hw_signal1_write,
3158b3d6663SArnd Bergmann 	.signal2_write = spu_hw_signal2_write,
3168b3d6663SArnd Bergmann 	.signal1_type_set = spu_hw_signal1_type_set,
3178b3d6663SArnd Bergmann 	.signal1_type_get = spu_hw_signal1_type_get,
3188b3d6663SArnd Bergmann 	.signal2_type_set = spu_hw_signal2_type_set,
3198b3d6663SArnd Bergmann 	.signal2_type_get = spu_hw_signal2_type_get,
3208b3d6663SArnd Bergmann 	.npc_read = spu_hw_npc_read,
3218b3d6663SArnd Bergmann 	.npc_write = spu_hw_npc_write,
3228b3d6663SArnd Bergmann 	.status_read = spu_hw_status_read,
3238b3d6663SArnd Bergmann 	.get_ls = spu_hw_get_ls,
324cc210b3eSLuke Browning 	.privcntl_write = spu_hw_privcntl_write,
3253960c260SJeremy Kerr 	.runcntl_read = spu_hw_runcntl_read,
3265110459fSArnd Bergmann 	.runcntl_write = spu_hw_runcntl_write,
327c25620d7SMasato Noguchi 	.runcntl_stop = spu_hw_runcntl_stop,
328ee2d7340SArnd Bergmann 	.master_start = spu_hw_master_start,
329ee2d7340SArnd Bergmann 	.master_stop = spu_hw_master_stop,
330a33a7d73SArnd Bergmann 	.set_mfc_query = spu_hw_set_mfc_query,
331a33a7d73SArnd Bergmann 	.read_mfc_tagstatus = spu_hw_read_mfc_tagstatus,
332a33a7d73SArnd Bergmann 	.get_mfc_free_elements = spu_hw_get_mfc_free_elements,
333a33a7d73SArnd Bergmann 	.send_mfc_command = spu_hw_send_mfc_command,
33457dace23SArnd Bergmann 	.restart_dma = spu_hw_restart_dma,
3358b3d6663SArnd Bergmann };
336