diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-04-11 23:19:09 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-04-11 23:19:09 +0000 |
commit | 0162245b27eb72c2973c587e5ea59317b43b88bd (patch) | |
tree | 21a04dc3ef46bb5f4361b32eef67a0b1b433b450 /nuttx/arch/arm/src/dm320/dm320_serial.c | |
parent | 32ff8af133c4d385a8dd40c756cf9fecaaf407c4 (diff) | |
download | px4-nuttx-0162245b27eb72c2973c587e5ea59317b43b88bd.tar.gz px4-nuttx-0162245b27eb72c2973c587e5ea59317b43b88bd.tar.bz2 px4-nuttx-0162245b27eb72c2973c587e5ea59317b43b88bd.zip |
Basic UART/console functionality
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1697 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/arch/arm/src/dm320/dm320_serial.c')
-rw-r--r-- | nuttx/arch/arm/src/dm320/dm320_serial.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/nuttx/arch/arm/src/dm320/dm320_serial.c b/nuttx/arch/arm/src/dm320/dm320_serial.c index 479c271bb..93da27525 100644 --- a/nuttx/arch/arm/src/dm320/dm320_serial.c +++ b/nuttx/arch/arm/src/dm320/dm320_serial.c @@ -1,7 +1,8 @@ /**************************************************************************** - * dm320/dm320_serial.c + * arch/arm/src/dm320/dm320_serial.c + * arch/arm/src/chip/dm320_serial.c * - * Copyright (C) 2007, 2008 Gregory Nutt. All rights reserved. + * Copyright (C) 2007-2009 Gregory Nutt. All rights reserved. * Author: Gregory Nutt <spudmonkey@racsa.co.cr> * * Redistribution and use in source and binary forms, with or without @@ -61,8 +62,6 @@ * Definitions ****************************************************************************/ -#define BASE_BAUD 115200 - /**************************************************************************** * Private Types ****************************************************************************/ @@ -548,8 +547,7 @@ static int up_ioctl(struct file *filep, int cmd, unsigned long arg) struct up_dev_s *user = (struct up_dev_s*)arg; if (!user) { - *get_errno_ptr() = EINVAL; - ret = ERROR; + ret = -EINVAL; } else { @@ -576,8 +574,7 @@ static int up_ioctl(struct file *filep, int cmd, unsigned long arg) break; default: - *get_errno_ptr() = ENOTTY; - ret = ERROR; + ret = -ENOTTY; break; } |