Changeset 2885
- Timestamp:
- 09/01/07 19:24:32 (6 years ago)
- Location:
- trunk/src/target/u-boot/patches
- Files:
-
- 5 edited
-
series (modified) (2 diffs)
-
uboot-20061030-neo1973.patch (modified) (6 diffs)
-
uboot-gta02.patch (modified) (2 diffs)
-
uboot-license.patch (modified) (1 diff)
-
uboot-serial_terminal.patch (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/target/u-boot/patches/series
r2884 r2885 8 8 uboot-cramfs_but_no_jffs2.patch 9 9 nand-read_write_oob.patch 10 uboot-serial_terminal.patch 10 11 uboot-arm920t-gd_in_irq.patch 11 12 uboot-arm920_s3c2410_irq_demux.patch … … 77 78 unbusy-i2c.patch 78 79 usbtty-irq-racecondition-fix.patch 79 uboot-serial_terminal.patch -
trunk/src/target/u-boot/patches/uboot-20061030-neo1973.patch
r2884 r2885 1352 1352 --- /dev/null 1353 1353 +++ u-boot/board/neo1973/gta01/gta01.c 1354 @@ -0,0 +1,4 31@@1354 @@ -0,0 +1,485 @@ 1355 1355 +/* 1356 1356 + * (C) 2006 by OpenMoko, Inc. … … 1386 1386 + 1387 1387 +#include <common.h> 1388 +#include <devices.h> 1388 1389 +#include <s3c2410.h> 1389 1390 +#include <i2c.h> … … 1718 1719 +} 1719 1720 + 1721 +/* switch serial port 0 multiplexer */ 1722 +void neo1973_gta01_serial0_gsm(int on) 1723 +{ 1724 + S3C24X0_GPIO * const gpio = S3C24X0_GetBase_GPIO(); 1725 + S3C24X0_UART * const uart = S3C24X0_GetBase_UART(0); 1726 + int i; 1727 + 1728 + if (on) { 1729 + for (i = 0; i < 3; i++) { 1730 + if (!strcmp(stdio_devices[i]->name, "serial") || 1731 + !strcmp(stdio_devices[i]->name, "s3ser0")) { 1732 + puts("ERROR: serial port busy, can't enable GSM!\n"); 1733 + return; 1734 + } 1735 + } 1736 + puts("switching s3ser0 from console into GSM mode\n"); 1737 + uart->UMCON |= 0x10; /* Hardware flow control */ 1738 + gpio->GPFDAT &= ~(1 << 2); /* GPF2: nGSM_EN */ 1739 + } else { 1740 + gpio->GPFDAT |= (1 << 2); /* GPF2: nGSM_EN */ 1741 + uart->UMCON &= ~0x10; /* No Hardware flow control */ 1742 + puts("switched s3ser0 from GSM mode back into console mode\n"); 1743 + } 1744 +} 1745 + 1746 +/* switch gsm power on/off */ 1720 1747 +void neo1973_gsm(int on) 1721 1748 +{ 1722 + printf("not implemented yet!\n"); 1723 +} 1724 + 1749 + S3C24X0_GPIO * const gpio = S3C24X0_GetBase_GPIO(); 1750 + device_t *dev = search_device(DEV_FLAGS_INPUT, "s3ser0"); 1751 + if (!dev) { 1752 + puts("can't find s3ser0 device ?!?\n"); 1753 + return; 1754 + } 1755 + 1756 + if (on) { 1757 + gpio->GPBDAT &= ~(1 << 6); /* GPB6: MODEM_RST */ 1758 + gpio->GPBDAT |= (1 << 7); /* GPB7: MODEM_ON */ 1759 + } else { 1760 + /* unfortunately switching the modem off is not that easy. 1761 + * Ti's firmware is insisting on not switching off... */ 1762 + gpio->GPBDAT &= ~(1 << 7); /* GPB7: MODEM_ON */ 1763 + //gpio->GPBDAT |= (1 << 6); /* GPB6: MODEM_RST */ 1764 + if (!(gpio->GPFDAT & (1 << 2))) 1765 + puts("Can't power modem off while serial console " 1766 + "in use!\n"); 1767 + else { 1768 + S3C24X0_UART * const uart = S3C24X0_GetBase_UART(0); 1769 + uart->UMCON |= 0x10; /* Hardware flow control */ 1770 + gpio->GPFDAT &= ~(1 << 2); /* GPF2: nGSM_EN */ 1771 + dev->puts("AT@POFF\r\n"); 1772 + gpio->GPFDAT |= (1 << 2); /* GPF2: nGSM_EN */ 1773 + uart->UMCON &= ~0x10; /* No Hardware flow control */ 1774 + } 1775 + } 1776 +} 1777 + 1778 +/* switch gps power on/off */ 1725 1779 +void neo1973_gps(int on) 1726 1780 +{ … … 2018 2072 --- /dev/null 2019 2073 +++ u-boot/include/configs/neo1973_gta01.h 2020 @@ -0,0 +1,25 4@@2074 @@ -0,0 +1,255 @@ 2021 2075 +/* 2022 2076 + * (C) Copyright 2006 OpenMoko, Inc. … … 2125 2179 +#define CONFIG_CMD_FAT 2126 2180 +#define CONFIG_CMD_EXT2 2181 +#define CONFIG_CMD_TERMINAL 2127 2182 + 2128 2183 +#define CONFIG_BOOTDELAY 3 … … 2312 2367 + 2313 2368 +#endif 2369 Index: u-boot/common/cmd_terminal.c 2370 =================================================================== 2371 --- u-boot.orig/common/cmd_terminal.c 2372 +++ u-boot/common/cmd_terminal.c 2373 @@ -50,7 +50,15 @@ 2374 if (!dev) 2375 return -1; 2376 2377 - serial_reinit_all(); 2378 +#if defined(CONFIG_ARCH_GTA01_v3) || defined(CONFIG_ARCH_GTA01_v4) || \ 2379 + defined(CONFIG_ARCH_GTA01B_v2) || defined(CONFIG_ARCH_GTA01B_v3) || \ 2380 + defined(CONFIG_ARCH_GTA01B_v4) 2381 + if (!strcmp(dev->name, "serial") || 2382 + !strcmp(dev->name, "s3ser0")) 2383 + neo1973_gta01_serial0_gsm(1); 2384 +#endif 2385 + 2386 + //serial_reinit_all(); 2387 printf("Entering terminal mode for port %s\n", dev->name); 2388 puts("Use '~.' to leave the terminal and get back to u-boot\n"); 2389 2390 @@ -87,6 +95,14 @@ 2391 putc(c); 2392 } 2393 } 2394 +#if defined(CONFIG_ARCH_GTA01_v3) || defined(CONFIG_ARCH_GTA01_v4) || \ 2395 + defined(CONFIG_ARCH_GTA01B_v2) || defined(CONFIG_ARCH_GTA01B_v3) || \ 2396 + defined(CONFIG_ARCH_GTA01B_v4) 2397 + if (!strcmp(dev->name, "serial") || 2398 + !strcmp(dev->name, "s3ser0")) 2399 + neo1973_gta01_serial0_gsm(0); 2400 +#endif 2401 + 2402 return 0; 2403 } 2404 -
trunk/src/target/u-boot/patches/uboot-gta02.patch
r2884 r2885 561 561 --- /dev/null 562 562 +++ u-boot/include/configs/neo1973_gta02.h 563 @@ -0,0 +1,27 7@@563 @@ -0,0 +1,278 @@ 564 564 +/* 565 565 + * (C) Copyright 2007 OpenMoko, Inc. … … 669 669 +#define CONFIG_CMD_EXT2 670 670 +#define CONFIG_CMD_LICENSE 671 +#define CONFIG_CMD_TERMINAL 671 672 + 672 673 +#define CONFIG_BOOTDELAY 3 -
trunk/src/target/u-boot/patches/uboot-license.patch
r2763 r2885 666 666 --- u-boot.orig/include/configs/neo1973_gta01.h 667 667 +++ u-boot/include/configs/neo1973_gta01.h 668 @@ -10 1,6 +101,7 @@668 @@ -102,6 +102,7 @@ 669 669 #define CONFIG_CMD_MMC 670 670 #define CONFIG_CMD_FAT 671 671 #define CONFIG_CMD_EXT2 672 672 +#define CONFIG_CMD_LICENSE 673 #define CONFIG_CMD_TERMINAL 673 674 674 675 #define CONFIG_BOOTDELAY 3 675 #define CONFIG_BOOTARGS ""676 676 Index: u-boot/include/configs/hxd8.h 677 677 =================================================================== -
trunk/src/target/u-boot/patches/uboot-serial_terminal.patch
r2884 r2885 2 2 using which you can access other serial ports from the system console. 3 3 4 Index: u-boot/include/configs/neo1973_gta02.h5 ===================================================================6 --- u-boot.orig/include/configs/neo1973_gta02.h7 +++ u-boot/include/configs/neo1973_gta02.h8 @@ -105,6 +105,7 @@9 #define CONFIG_CMD_FAT10 #define CONFIG_CMD_EXT211 #define CONFIG_CMD_LICENSE12 +#define CONFIG_CMD_TERMINAL13 14 #define CONFIG_BOOTDELAY 315 #define CONFIG_BOOTARGS ""16 4 Index: u-boot/common/Makefile 17 5 =================================================================== … … 134 122 + 135 123 +#endif /* CONFIG_CMD_TERMINAL */ 136 Index: u-boot/include/configs/neo1973_gta01.h137 ===================================================================138 --- u-boot.orig/include/configs/neo1973_gta01.h139 +++ u-boot/include/configs/neo1973_gta01.h140 @@ -103,6 +103,7 @@141 #define CONFIG_CMD_FAT142 #define CONFIG_CMD_EXT2143 #define CONFIG_CMD_LICENSE144 +#define CONFIG_CMD_TERMINAL145 146 #define CONFIG_BOOTDELAY 3147 #define CONFIG_BOOTARGS ""
Note: See TracChangeset
for help on using the changeset viewer.
