socrates: Rework CONFIG_PCI_CLK_FREQ
authorTom Rini <trini@konsulko.com>
Mon, 20 Jun 2022 12:07:54 +0000 (08:07 -0400)
committerTom Rini <trini@konsulko.com>
Tue, 5 Jul 2022 21:05:00 +0000 (17:05 -0400)
The symbol CONFIG_PCI_CLK_FREQ is local to this board.  Provide equal
clarity in the code by referencing the numeric value directly and move
the explanatory comment to the code, just prior to use.

Signed-off-by: Tom Rini <trini@konsulko.com>
board/socrates/socrates.c
include/configs/socrates.h

index 3430a1e..27aad4e 100644 (file)
@@ -59,7 +59,8 @@ int checkboard (void)
                f = get_board_sys_clk();
        } else {
                src = "PCI_CLK";
-               f = CONFIG_PCI_CLK_FREQ;
+               /* PCI is clocked by the external source at 33 MHz */
+               f = 33000000;
        }
        printf ("PCI1:  32 bit, %d MHz (%s)\n", f/1000000, src);
 #else
index 14f7bb9..6a78cb1 100644 (file)
  * Memory space is mapped 1-1.
  */
 
-/* PCI is clocked by the external source at 33 MHz */
-#define CONFIG_PCI_CLK_FREQ    33000000
 #define CONFIG_SYS_PCI1_MEM_BASE       0x80000000
 #define CONFIG_SYS_PCI1_MEM_PHYS       CONFIG_SYS_PCI1_MEM_BASE
 #define CONFIG_SYS_PCI1_MEM_SIZE       0x20000000      /* 512M                 */