diff options
| author | Simon Glass <[email protected]> | 2024-08-21 10:18:53 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2024-08-26 14:05:37 -0600 |
| commit | 5f32aac98ec39bc3116bf6d3fbff8ebf2cf78919 (patch) | |
| tree | acdac7d1a3506d72cf72f24138260e64d276ab9a /arch/powerpc | |
| parent | 7670200d4b7bbb572290d0fb2ed9cd0fb1f989cc (diff) | |
global_data: Move pci_clk to m68k and powerpc
Only m68k and powerpc use this field, so move it to the arch-specific
info, to reduce the size for other archs.
Signed-off-by: Simon Glass <[email protected]>
Diffstat (limited to 'arch/powerpc')
| -rw-r--r-- | arch/powerpc/cpu/mpc83xx/pci.c | 4 | ||||
| -rw-r--r-- | arch/powerpc/cpu/mpc83xx/speed.c | 2 | ||||
| -rw-r--r-- | arch/powerpc/include/asm/global_data.h | 2 |
3 files changed, 5 insertions, 3 deletions
diff --git a/arch/powerpc/cpu/mpc83xx/pci.c b/arch/powerpc/cpu/mpc83xx/pci.c index 6f378c4e221..aef1123a2b7 100644 --- a/arch/powerpc/cpu/mpc83xx/pci.c +++ b/arch/powerpc/cpu/mpc83xx/pci.c @@ -45,7 +45,7 @@ void ft_pci_setup(void *blob, struct bd_info *bd) do_fixup_by_path(blob, path, "bus-range", &tmp, sizeof(tmp), 1); - tmp[0] = cpu_to_be32(gd->pci_clk); + tmp[0] = cpu_to_be32(gd->arch.pci_clk); do_fixup_by_path(blob, path, "clock-frequency", &tmp, sizeof(tmp[0]), 1); } @@ -60,7 +60,7 @@ void ft_pci_setup(void *blob, struct bd_info *bd) do_fixup_by_path(blob, path, "bus-range", &tmp, sizeof(tmp), 1); - tmp[0] = cpu_to_be32(gd->pci_clk); + tmp[0] = cpu_to_be32(gd->arch.pci_clk); do_fixup_by_path(blob, path, "clock-frequency", &tmp, sizeof(tmp[0]), 1); } diff --git a/arch/powerpc/cpu/mpc83xx/speed.c b/arch/powerpc/cpu/mpc83xx/speed.c index 72464962613..0185ab50ad9 100644 --- a/arch/powerpc/cpu/mpc83xx/speed.c +++ b/arch/powerpc/cpu/mpc83xx/speed.c @@ -456,7 +456,7 @@ int get_clocks(void) #if defined(CONFIG_ARCH_MPC837X) gd->arch.sata_clk = sata_clk; #endif - gd->pci_clk = pci_sync_in; + gd->arch.pci_clk = pci_sync_in; gd->cpu_clk = gd->arch.core_clk; gd->bus_clk = gd->arch.csb_clk; return 0; diff --git a/arch/powerpc/include/asm/global_data.h b/arch/powerpc/include/asm/global_data.h index a9efbbdd3d4..cc2ce617350 100644 --- a/arch/powerpc/include/asm/global_data.h +++ b/arch/powerpc/include/asm/global_data.h @@ -87,6 +87,8 @@ struct arch_global_data { #if defined(CONFIG_LWMON5) unsigned long kbd_status; #endif + /** @pci_clk: PCI clock rate in Hz */ + unsigned long pci_clk; }; #include <asm-generic/global_data.h> |
