powerpc: Move /proc/ppc64 to /proc/powerpc and add symlink
Some of the stuff in /proc/ppc64 such as the RTAS bits are actually useful to some 32-bit platforms. Rename the file, and create a symlink on 64-bit for backward compatibility
Signed-off-by Benjamin Herrenschmidt <[email protected]>
---
arch/powerpc/kernel/Makefile +1 -1
@@ -42,7 +42,7 @@ obj-$(CONFIG_ALTIVEC) += vecemu.o obj-$(CONFIG_PPC_970_NAP) += idle_power4.o obj-$(CONFIG_PPC_OF) += of_device.o of_platform.o prom_parse.o obj-$(CONFIG_PPC_CLOCK) += clock.o -procfs-$(CONFIG_PPC64) := proc_ppc64.o +procfs-y := proc_powerpc.o obj-$(CONFIG_PROC_FS) += $(procfs-y) rtaspci-$(CONFIG_PPC64)-$(CONFIG_PCI) := rtas_pci.o obj-$(CONFIG_PPC_RTAS) += rtas.o rtas-rtc.o $(rtaspci-y-y)
arch/powerpc/kernel/lparcfg.c +2 -2
@@ -781,9 +781,9 @@ static int __init lparcfg_init(void) !firmware_has_feature(FW_FEATURE_ISERIES)) mode |=S_IWUSR ; - ent =proc_create ("ppc64/lparcfg" , mode,NULL , &lparcfg_fops); + ent =proc_create ("powerpc/lparcfg" , mode,NULL , &lparcfg_fops);if (!ent) { -printk (KERN_ERR "Failed to create ppc64/lparcfg\n" ); +printk (KERN_ERR "Failed to create powerpc/lparcfg\n" );return -EIO ; }
arch/powerpc/kernel/proc_powerpc.c new file +126 -0
126 lines not on this page · raw message
arch/powerpc/kernel/proc_ppc64.c deleted +0 -122
122 lines not on this page · raw message
arch/powerpc/kernel/rtas_flash.c +5 -5
@@ -6,7 +6,7 @@* as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. * -* /proc/ppc64/rtas/firmware_flash interface +* /proc/powerpc/rtas/firmware_flash interface * * This file implements a firmware_flash interface to pump a firmware * image into the kernel. At reboot time rtas_restart() will see the
@@ -740,7 +740,7 @@ static int __init rtas_flash_init(void)return 1 ; } - firmware_flash_pde =create_flash_pde ("ppc64/rtas/" + firmware_flash_pde =create_flash_pde ("powerpc/rtas/" FIRMWARE_FLASH_NAME , &rtas_flash_operations);if (firmware_flash_pde ==NULL ) {
@@ -754,7 +754,7 @@ static int __init rtas_flash_init(void)if (rc !=0 ) goto cleanup; - firmware_update_pde =create_flash_pde ("ppc64/rtas/" + firmware_update_pde =create_flash_pde ("powerpc/rtas/" FIRMWARE_UPDATE_NAME , &rtas_flash_operations);if (firmware_update_pde ==NULL ) {
@@ -768,7 +768,7 @@ static int __init rtas_flash_init(void)if (rc !=0 ) goto cleanup; - validate_pde =create_flash_pde ("ppc64/rtas/" VALIDATE_FLASH_NAME , + validate_pde =create_flash_pde ("powerpc/rtas/" VALIDATE_FLASH_NAME , &validate_flash_operations);if (validate_pde ==NULL ) { rc = -ENOMEM ;
@@ -781,7 +781,7 @@ static int __init rtas_flash_init(void)if (rc !=0 ) goto cleanup; - manage_pde =create_flash_pde ("ppc64/rtas/" MANAGE_FLASH_NAME , + manage_pde =create_flash_pde ("powerpc/rtas/" MANAGE_FLASH_NAME , &manage_flash_operations);if (manage_pde ==NULL ) { rc = -ENOMEM ;
arch/powerpc/platforms/pseries/reconfig.c +3 -3
@@ -184,7 +184,7 @@ static int pSeries_reconfig_remove_node(struct device_node *np) }/* -* /proc/ppc64/ofdt - yucky binary interface for adding and removing +* /proc/powerpc/ofdt - yucky binary interface for adding and removing * OF device nodes. Should be deprecated as soon as we get an * in-kernel wrapper for the RTAS ibm,configure-connector call. */
@@ -543,7 +543,7 @@ static const struct file_operations ofdt_fops = { .write = ofdt_write }; -/* create /proc/ppc64/ofdt write-only by root */ +/* create /proc/powerpc/ofdt write-only by root */ static int proc_ppc64_create_ofdt (void ) {struct proc_dir_entry *ent;
@@ -551,7 +551,7 @@ static int proc_ppc64_create_ofdt(void)if (!machine_is (pseries))return 0 ; - ent =proc_create ("ppc64/ofdt" ,S_IWUSR ,NULL , &ofdt_fops); + ent =proc_create ("powerpc/ofdt" ,S_IWUSR ,NULL , &ofdt_fops);if (ent) ent->size =0 ;
arch/powerpc/platforms/pseries/scanlog.c +2 -2
@@ -13,7 +13,7 @@* of this data using this driver. A dump exists if the device-tree * /chosen/ibm,scan-log-data property exists. * -* This driver exports /proc/ppc64/scan-log-dump which can be read. +* This driver exports /proc/powerpc/scan-log-dump which can be read. * The driver supports only sequential reads. * * The driver looks at a write to the driver for the single word "reset".
@@ -186,7 +186,7 @@ static int __init scanlog_init(void)if (!data) goto err; - ent =proc_create_data ("ppc64/rtas/scan-log-dump" ,S_IRUSR ,NULL , + ent =proc_create_data ("powerpc/rtas/scan-log-dump" ,S_IRUSR ,NULL , &scanlog_fops, data);if (!ent) goto err;
Hi Ben,
arch/powerpc/kernel/Makefile obj-$(CONFIG_ALTIVEC) += vecemu.o · line 46
Quoted 7 lines · On Fri, 25 Sep 2009 15:29:13 +1000 Benjamin Herrenschmidt…
obj-$(CONFIG_PPC_970_NAP) += idle_power4.o
obj-$(CONFIG_PPC_OF) += of_device.o of_platform.o prom_parse.o
obj-$(CONFIG_PPC_CLOCK) += clock.oarch/powerpc/kernel/Makefile +1
-1-procfs-$(CONFIG_PPC64) := proc_ppc64.o +procfs-y := proc_powerpc.o obj-$(CONFIG_PROC_FS) += $(procfs-y)
Surely just:
obj-$(CONFIG_PROC_FS) += proc_powerpc.o
Signature · 3 lines
Cheers, Stephen Rothwell [email protected] http://www.canb.auug.org.au/~sfr/