]> git.sur5r.net Git - u-boot/blobdiff - board/esd/pci405/pci405.c
am335x_evm: Convert CONFIG_CONS_INDEX into a menu choice
[u-boot] / board / esd / pci405 / pci405.c
index 04bc569ead1cc03a9088a2a3b0fbb19833b74ab4..566f6f77793a62449d00a9b4dc32f2e7a130563a 100644 (file)
@@ -2,23 +2,7 @@
  * (C) Copyright 2001-2004
  * Stefan Roese, esd gmbh germany, stefan.roese@esd-electronics.com
  *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
@@ -34,8 +18,6 @@
 DECLARE_GLOBAL_DATA_PTR;
 
 /* Prototypes */
-int gunzip(void *, int, unsigned char *, unsigned long *);
-int do_reset (cmd_tbl_t *cmdtp, int flag, int argc, char *argv[]);
 unsigned long fpga_done_state(void);
 unsigned long fpga_init_state(void);
 
@@ -155,13 +137,13 @@ int board_early_init_f (void)
         * IRQ 30 (EXT IRQ 5) FPGA Timestamp; active low; level sensitive
         * IRQ 31 (EXT IRQ 6) PCI Reset; active low; level sensitive
         */
-       mtdcr(uicsr, 0xFFFFFFFF);        /* clear all ints */
-       mtdcr(uicer, 0x00000000);        /* disable all ints */
-       mtdcr(uiccr, 0x00000000);        /* set all to be non-critical*/
-       mtdcr(uicpr, 0xFFFFFF80);        /* set int polarities */
-       mtdcr(uictr, 0x10000000);        /* set int trigger levels */
-       mtdcr(uicvcr, 0x00000001);       /* set vect base=0,INT0 highest priority*/
-       mtdcr(uicsr, 0xFFFFFFFF);        /* clear all ints */
+       mtdcr(UIC0SR, 0xFFFFFFFF);        /* clear all ints */
+       mtdcr(UIC0ER, 0x00000000);        /* disable all ints */
+       mtdcr(UIC0CR, 0x00000000);        /* set all to be non-critical*/
+       mtdcr(UIC0PR, 0xFFFFFF80);        /* set int polarities */
+       mtdcr(UIC0TR, 0x10000000);        /* set int trigger levels */
+       mtdcr(UIC0VCR, 0x00000001);       /* set vect base=0,INT0 highest priority*/
+       mtdcr(UIC0SR, 0xFFFFFFFF);        /* clear all ints */
 
        /*
         * Setup GPIO pins (IRQ4/GPIO21 as GPIO)
@@ -271,7 +253,7 @@ int misc_init_r (void)
                                pci_write_config_dword(PCIDEVID_405GP, i, *ptr++);
                        }
                }
-               mtdcr(uicsr, 0xFFFFFFFF);        /* clear all ints */
+               mtdcr(UIC0SR, 0xFFFFFFFF);        /* clear all ints */
 
                *magic = 0;      /* clear pci reconfig magic again */
        }
@@ -282,7 +264,6 @@ int misc_init_r (void)
 #define PCI0_BRDGOPT1 0x4a
        pci_write_config_word(PCIDEVID_405GP, PCI0_BRDGOPT1, 0x3f20);
 
-#define PLB0_ACR      0x87
        /*
         * Enable fairness and high bus utilization
         */
@@ -299,7 +280,7 @@ int misc_init_r (void)
 int checkboard (void)
 {
        char str[64];
-       int i = getenv_("serial#", str, sizeof(str));
+       int i = getenv_f("serial#", str, sizeof(str));
 
        puts ("Board: ");
 
@@ -357,7 +338,7 @@ int wpeeprom(int wp)
        return wp_state;
 }
 
-int do_wpeeprom(cmd_tbl_t *cmdtp, int flag, int argc, char *argv[])
+int do_wpeeprom(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 {
        int wp = -1;
        if (argc >= 2) {