Skip to contentSkip to conversation

MIPS: CEVT: Make R4K's clockevent_device name more meaningful

PATCH In review Joshua Kinard 2 participants 3 messages Dec 12, 2014 MIPS

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 MIPS: CEVT: Make R4K's clockevent_device name more meaningful

Change the R4K clockevent device's name from "MIPS" to something a bit more meaningful, "CEVT-R4K".

---
 arch/mips/kernel/cevt-r4k.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
arch/mips/kernel/cevt-r4k.c +1 -1
index bc127e2..f531cac 100644
@@ -178,7 +178,7 @@ int r4k_clockevent_init(void)
 
 	cd = &per_cpu(mips_clockevent_device, cpu);
 
-	cd->name		= "MIPS";
+	cd->name		= "CEVT-R4K";
 	cd->features		= CLOCK_EVT_FEAT_ONESHOT |
 				  CLOCK_EVT_FEAT_C3STOP |
 				  CLOCK_EVT_FEAT_PERCPU;
#1 lore raw
Quoted 3 lines · Joshua Kinard

Change the R4K clockevent device's name from "MIPS" to something a bit more meaningful, "CEVT-R4K".

This is visible to userspace, so how does changing this effect the kernel <--> userspace ABI? Or in other words, what uses this, and could changing it possibly break things?

David Daney

Quoted 22 lines
---
  arch/mips/kernel/cevt-r4k.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
arch/mips/kernel/cevt-r4k.c +1 -1
index bc127e2..f531cac 100644
@@ -178,7 +178,7 @@ int r4k_clockevent_init(void)
 
  	cd = &per_cpu(mips_clockevent_device, cpu);
 
-	cd->name		= "MIPS";
+	cd->name		= "CEVT-R4K";
  	cd->features		= CLOCK_EVT_FEAT_ONESHOT |
  				  CLOCK_EVT_FEAT_C3STOP |
  				  CLOCK_EVT_FEAT_PERCPU;
#2 lore raw
Quoted 10 lines · David Daney
Quoted 3 lines · Joshua Kinard

Change the R4K clockevent device's name from "MIPS" to something a bit more meaningful, "CEVT-R4K".

This is visible to userspace, so how does changing this effect the kernel <--> userspace ABI? Or in other words, what uses this, and could changing it possibly break things?

David Daney

I haven't noticed any issues in userspace running this change on the Octane. R4k is the only clockevent_device using the name of "MIPS", so if there is some userspace program relying on that, I would imagine it'd fail on the other clockevent_device providers as they use different names. I suspect that R4k was the original clockevent_device/timer, so it got defaulted to "MIPS". Since there's several providers now, differentiating R4K seems logical.

--J

Quoted 19 lines
Quoted 19 lines
---
  arch/mips/kernel/cevt-r4k.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
arch/mips/kernel/cevt-r4k.c +1 -1
index bc127e2..f531cac 100644
@@ -178,7 +178,7 @@ int r4k_clockevent_init(void)
 
      cd = &per_cpu(mips_clockevent_device, cpu);
 
-    cd->name        = "MIPS";
+    cd->name        = "CEVT-R4K";
      cd->features        = CLOCK_EVT_FEAT_ONESHOT |
                    CLOCK_EVT_FEAT_C3STOP |
                    CLOCK_EVT_FEAT_PERCPU;