aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/sibyte/common/sb_tbprof.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mips/sibyte/common/sb_tbprof.c')
-rw-r--r--arch/mips/sibyte/common/sb_tbprof.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/arch/mips/sibyte/common/sb_tbprof.c b/arch/mips/sibyte/common/sb_tbprof.c
index e8c4538c5f61..2188b39a1251 100644
--- a/arch/mips/sibyte/common/sb_tbprof.c
+++ b/arch/mips/sibyte/common/sb_tbprof.c
@@ -152,7 +152,7 @@ static u64 tb_period;
152 152
153static void arm_tb(void) 153static void arm_tb(void)
154{ 154{
155 u64 scdperfcnt; 155 u64 scdperfcnt;
156 u64 next = (1ULL << 40) - tb_period; 156 u64 next = (1ULL << 40) - tb_period;
157 u64 tb_options = M_SCD_TRACE_CFG_FREEZE_FULL; 157 u64 tb_options = M_SCD_TRACE_CFG_FREEZE_FULL;
158 158
@@ -257,8 +257,8 @@ static irqreturn_t sbprof_pc_intr(int irq, void *dev_id)
257 257
258/* 258/*
259 * Requires: Already called zclk_timer_init with a value that won't 259 * Requires: Already called zclk_timer_init with a value that won't
260 * saturate 40 bits. No subsequent use of SCD performance counters 260 * saturate 40 bits. No subsequent use of SCD performance counters
261 * or trace buffer. 261 * or trace buffer.
262 */ 262 */
263 263
264static int sbprof_zbprof_start(struct file *filp) 264static int sbprof_zbprof_start(struct file *filp)
@@ -288,8 +288,8 @@ static int sbprof_zbprof_start(struct file *filp)
288 288
289 /* 289 /*
290 * We grab this interrupt to prevent others from trying to use 290 * We grab this interrupt to prevent others from trying to use
291 * it, even though we don't want to service the interrupts 291 * it, even though we don't want to service the interrupts
292 * (they only feed into the trace-on-interrupt mechanism) 292 * (they only feed into the trace-on-interrupt mechanism)
293 */ 293 */
294 if (request_irq(K_INT_PERF_CNT, sbprof_pc_intr, 0, DEVNAME " scd perfcnt", &sbp)) { 294 if (request_irq(K_INT_PERF_CNT, sbprof_pc_intr, 0, DEVNAME " scd perfcnt", &sbp)) {
295 free_irq(K_INT_TRACE_FREEZE, &sbp); 295 free_irq(K_INT_TRACE_FREEZE, &sbp);
@@ -298,7 +298,7 @@ static int sbprof_zbprof_start(struct file *filp)
298 298
299 /* 299 /*
300 * I need the core to mask these, but the interrupt mapper to 300 * I need the core to mask these, but the interrupt mapper to
301 * pass them through. I am exploiting my knowledge that 301 * pass them through. I am exploiting my knowledge that
302 * cp0_status masks out IP[5]. krw 302 * cp0_status masks out IP[5]. krw
303 */ 303 */
304#if defined(CONFIG_SIBYTE_BCM1x55) || defined(CONFIG_SIBYTE_BCM1x80) 304#if defined(CONFIG_SIBYTE_BCM1x55) || defined(CONFIG_SIBYTE_BCM1x80)
@@ -328,7 +328,7 @@ static int sbprof_zbprof_start(struct file *filp)
328 __raw_writeq(0, IOADDR(A_ADDR_TRAP_CFG_3)); 328 __raw_writeq(0, IOADDR(A_ADDR_TRAP_CFG_3));
329 329
330 /* Initialize Trace Event 0-7 */ 330 /* Initialize Trace Event 0-7 */
331 /* when interrupt */ 331 /* when interrupt */
332 __raw_writeq(M_SCD_TREVT_INTERRUPT, IOADDR(A_SCD_TRACE_EVENT_0)); 332 __raw_writeq(M_SCD_TREVT_INTERRUPT, IOADDR(A_SCD_TRACE_EVENT_0));
333 __raw_writeq(0, IOADDR(A_SCD_TRACE_EVENT_1)); 333 __raw_writeq(0, IOADDR(A_SCD_TRACE_EVENT_1));
334 __raw_writeq(0, IOADDR(A_SCD_TRACE_EVENT_2)); 334 __raw_writeq(0, IOADDR(A_SCD_TRACE_EVENT_2));
@@ -479,7 +479,7 @@ static ssize_t sbprof_tb_read(struct file *filp, char *buf,
479 return err; 479 return err;
480 } 480 }
481 pr_debug(DEVNAME ": read from sample %d, %d bytes\n", 481 pr_debug(DEVNAME ": read from sample %d, %d bytes\n",
482 cur_sample, cur_count); 482 cur_sample, cur_count);
483 size -= cur_count; 483 size -= cur_count;
484 sample_left -= cur_count; 484 sample_left -= cur_count;
485 if (!sample_left) { 485 if (!sample_left) {
@@ -540,7 +540,7 @@ static const struct file_operations sbprof_tb_fops = {
540 .open = sbprof_tb_open, 540 .open = sbprof_tb_open,
541 .release = sbprof_tb_release, 541 .release = sbprof_tb_release,
542 .read = sbprof_tb_read, 542 .read = sbprof_tb_read,
543 .unlocked_ioctl = sbprof_tb_ioctl, 543 .unlocked_ioctl = sbprof_tb_ioctl,
544 .compat_ioctl = sbprof_tb_ioctl, 544 .compat_ioctl = sbprof_tb_ioctl,
545 .mmap = NULL, 545 .mmap = NULL,
546 .llseek = default_llseek, 546 .llseek = default_llseek,