Guennadi Liakhovetski | 8c170c5 | 2008-08-31 00:39:46 +0200 | [diff] [blame] | 1 | /* |
| 2 | * (C) Copyright 2003 |
| 3 | * David MÃŒller ELSOFT AG Switzerland. d.mueller@elsoft.ch |
| 4 | * |
| 5 | * (C) Copyright 2008 |
| 6 | * Guennadi Liakhovetki, DENX Software Engineering, <lg@denx.de> |
| 7 | * |
| 8 | * See file CREDITS for list of people who contributed to this |
| 9 | * project. |
| 10 | * |
| 11 | * This program is free software; you can redistribute it and/or |
| 12 | * modify it under the terms of the GNU General Public License as |
| 13 | * published by the Free Software Foundation; either version 2 of |
| 14 | * the License, or (at your option) any later version. |
| 15 | * |
| 16 | * This program is distributed in the hope that it will be useful, |
| 17 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 18 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 19 | * GNU General Public License for more details. |
| 20 | * |
| 21 | * You should have received a copy of the GNU General Public License |
| 22 | * along with this program; if not, write to the Free Software |
| 23 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, |
| 24 | * MA 02111-1307 USA |
| 25 | */ |
| 26 | |
| 27 | /************************************************ |
| 28 | * NAME : S3C64XX.h |
| 29 | * Version : 31.3.2003 |
| 30 | * |
| 31 | * common stuff for SAMSUNG S3C64XX SoC |
| 32 | ************************************************/ |
| 33 | |
| 34 | #ifndef __S3C64XX_H__ |
| 35 | #define __S3C64XX_H__ |
| 36 | |
| 37 | #if defined(CONFIG_SYNC_MODE) && defined(CONFIG_S3C6400) |
| 38 | #error CONFIG_SYNC_MODE unavailable on S3C6400, please, fix your configuration! |
| 39 | #endif |
| 40 | |
| 41 | #include <asm/types.h> |
| 42 | |
| 43 | /* UART (see manual chapter 11) */ |
| 44 | typedef struct { |
| 45 | volatile u32 ULCON; |
| 46 | volatile u32 UCON; |
| 47 | volatile u32 UFCON; |
| 48 | volatile u32 UMCON; |
| 49 | volatile u32 UTRSTAT; |
| 50 | volatile u32 UERSTAT; |
| 51 | volatile u32 UFSTAT; |
| 52 | volatile u32 UMSTAT; |
| 53 | #ifdef __BIG_ENDIAN |
| 54 | volatile u8 res1[3]; |
| 55 | volatile u8 UTXH; |
| 56 | volatile u8 res2[3]; |
| 57 | volatile u8 URXH; |
| 58 | #else /* Little Endian */ |
| 59 | volatile u8 UTXH; |
| 60 | volatile u8 res1[3]; |
| 61 | volatile u8 URXH; |
| 62 | volatile u8 res2[3]; |
| 63 | #endif |
| 64 | volatile u32 UBRDIV; |
| 65 | #ifdef __BIG_ENDIAN |
| 66 | volatile u8 res3[2]; |
| 67 | volatile u16 UDIVSLOT; |
| 68 | #else |
| 69 | volatile u16 UDIVSLOT; |
| 70 | volatile u8 res3[2]; |
| 71 | #endif |
| 72 | } s3c64xx_uart; |
| 73 | |
| 74 | /* PWM TIMER (see manual chapter 10) */ |
| 75 | typedef struct { |
| 76 | volatile u32 TCNTB; |
| 77 | volatile u32 TCMPB; |
| 78 | volatile u32 TCNTO; |
| 79 | } s3c64xx_timer; |
| 80 | |
| 81 | typedef struct { |
| 82 | volatile u32 TCFG0; |
| 83 | volatile u32 TCFG1; |
| 84 | volatile u32 TCON; |
| 85 | s3c64xx_timer ch[4]; |
| 86 | volatile u32 TCNTB4; |
| 87 | volatile u32 TCNTO4; |
| 88 | } s3c64xx_timers; |
| 89 | |
| 90 | #endif /*__S3C64XX_H__*/ |