]> git.sur5r.net Git - u-boot/blobdiff - board/prodrive/p3p440/p3p440.c
CM41xx: fix signedness of env bootargs string pointer
[u-boot] / board / prodrive / p3p440 / p3p440.c
index 5761e708454b961304503a2d9606d4635cb26383..1bb9686a3b7b37539d97faa1f92d9e9629c9e4a3 100644 (file)
@@ -122,12 +122,13 @@ int board_early_init_f(void)
 
 int checkboard(void)
 {
-       char *s = getenv("serial#");
+       char buf[64];
+       int i = getenv_f("serial#", buf, sizeof(buf));
 
        printf("Board: P3P440");
-       if (s != NULL) {
+       if (i > 0) {
                puts(", serial# ");
-               puts(s);
+               puts(buf);
        }
 
        if (is_monarch()) {
@@ -164,37 +165,6 @@ int misc_init_r (void)
        return 0;
 }
 
-/*************************************************************************
- *  pci_pre_init
- *
- *  This routine is called just prior to registering the hose and gives
- *  the board the opportunity to check things. Returning a value of zero
- *  indicates that things are bad & PCI initialization should be aborted.
- *
- *     Different boards may wish to customize the pci controller structure
- *     (add regions, override default access routines, etc) or perform
- *     certain pre-initialization actions.
- *
- ************************************************************************/
-#if defined(CONFIG_PCI)
-int pci_pre_init(struct pci_controller *hose)
-{
-       unsigned long strap;
-
-       /*--------------------------------------------------------------------------+
-        *      The P3P440 board is always configured as the host & requires the
-        *      PCI arbiter to be disabled because it's an PMC module.
-        *--------------------------------------------------------------------------*/
-       strap = mfdcr(CPC0_STRP1);
-       if (strap & 0x00100000) {
-               printf("PCI: CPC0_STRP1[PAE] set.\n");
-               return 0;
-       }
-
-       return 1;
-}
-#endif /* defined(CONFIG_PCI) */
-
 /*************************************************************************
  * Override weak is_pci_host()
  *