Changeset f1fc83a in mainline


Ignore:
Timestamp:
2010-06-28T21:58:31Z (14 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5c032932
Parents:
6250c37
Message:

Add s3c24xx_uart driver to kernel for serial console output.

Files:
2 added
7 edited

Legend:

Unmodified
Added
Removed
  • HelenOS.config

    r6250c37 rf1fc83a  
    387387% Output device class
    388388@ "generic" Monitor or serial line
    389 ! [PLATFORM=arm32&MACHINE=integratorcp] CONFIG_HID_OUT (choice)
     389! [PLATFORM=arm32&(MACHINE=gta02|MACHINE=integratorcp)] CONFIG_HID_OUT (choice)
    390390
    391391% Output device class
     
    434434% Support for NS16550 controller
    435435! [(CONFIG_HID_IN=generic|CONFIG_HID_IN=serial)&PLATFORM=ia64&MACHINE=i460GX] CONFIG_NS16550 (y/n)
     436
     437% Support for Samsung S3C24XX on-chip UART
     438! [(CONFIG_HID_OUT=generic|CONFIG_HID_OUT=serial)&PLATFORM=arm32&MACHINE=gta02] CONFIG_S3C24XX_UART (y/n)
    436439
    437440% Support for Z8530 controller
  • boot/arch/arm32/include/main.h

    r6250c37 rf1fc83a  
    4242/** GTA02 serial console UART register addresses.
    4343 *
    44  * This is UART channel 2 of the S3C244x CPU
     44 * This is UART channel 2 of the S3C24xx CPU
    4545 */
    4646#define GTA02_SCONS_UTRSTAT     0x50008010
     
    4848
    4949/* Bits in UTXH register */
    50 #define S3C244X_UTXH_TX_EMPTY   0x00000004
     50#define S3C24XX_UTXH_TX_EMPTY   0x00000004
    5151
    5252
  • boot/arch/arm32/src/putchar.c

    r6250c37 rf1fc83a  
    5656
    5757        /* Wait until transmitter is empty. */
    58         while ((*utrstat & S3C244X_UTXH_TX_EMPTY) == 0)
     58        while ((*utrstat & S3C24XX_UTXH_TX_EMPTY) == 0)
    5959                ;
    6060
  • defaults/arm32/gta02/Makefile.config

    r6250c37 rf1fc83a  
    88CONFIG_UDEBUG = n
    99
    10 # Kernel console support
    11 CONFIG_KCONSOLE = n
    12 
    13 # Kernel symbol information
    14 CONFIG_SYMTAB = n
    15 
    1610# Compile kernel tests
    1711CONFIG_TEST = n
  • kernel/arch/arm32/src/mach/gta02/gta02.c

    r6250c37 rf1fc83a  
    3737#include <arch/mach/gta02/gta02.h>
    3838#include <arch/mm/page.h>
     39#include <mm/page.h>
     40#include <genarch/drivers/s3c24xx_uart/s3c24xx_uart.h>
    3941
    4042#define GTA02_MEMORY_START      0x30000000      /* physical */
    4143#define GTA02_MEMORY_SIZE       0x08000000      /* 128 MB */
    42 #define GTA02_MEMORY_SKIP       0x8000          /* 2 pages */
     44#define GTA02_MEMORY_SKIP       0x8000
     45
     46/** GTA02 serial console UART address (UART S3C24XX CPU UART channel 2). */
     47#define GTA02_SCONS_BASE        0x50008000
    4348
    4449static void gta02_init(void);
     
    5055static void gta02_output_init(void);
    5156static void gta02_input_init(void);
     57
     58static void *gta02_scons_out;
    5259
    5360struct arm_machine_ops gta02_machine_ops = {
     
    6471static void gta02_init(void)
    6572{
     73        gta02_scons_out = (void *) hw_map(GTA02_SCONS_BASE, PAGE_SIZE);
    6674}
    6775
     
    95103static void gta02_output_init(void)
    96104{
     105        outdev_t *scons_dev;
     106
     107        scons_dev = s3c24xx_uart_init((ioport8_t *) gta02_scons_out);
     108        if (scons_dev)
     109                stdout_wire(scons_dev);
    97110}
    98111
  • kernel/arch/arm32/src/mm/page.c

    r6250c37 rf1fc83a  
    6868#error "Only high exception vector supported now"
    6969#endif
     70        cur = ALIGN_DOWN(0x50008010, FRAME_SIZE);
     71        page_mapping_insert(AS_KERNEL, PA2KA(cur), cur, flags);
    7072
    7173        page_table_unlock(AS_KERNEL, true);
  • kernel/genarch/Makefile.inc

    r6250c37 rf1fc83a  
    9090endif
    9191
     92ifeq ($(CONFIG_S3C24XX_UART),y)
     93        GENARCH_SOURCES += \
     94                genarch/src/drivers/s3c24xx_uart/s3c24xx_uart.c
     95endif
     96
    9297ifeq ($(CONFIG_Z8530),y)
    9398        GENARCH_SOURCES += \
Note: See TracChangeset for help on using the changeset viewer.