diff options
author | drath <drath@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2007-08-10 19:44:06 +0000 |
---|---|---|
committer | drath <drath@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2007-08-10 19:44:06 +0000 |
commit | 20e4e77cdf366dedac21ff5670c54291feadfc05 (patch) | |
tree | 95363c4dc5940d7e0e94be81ba76b73e92ff1cf3 /src/jtag/gw16012.c | |
parent | 835e6440b8d1d26b4e041be7edab200ab2c572ee (diff) |
- renamed M5960 USB JTAG to "flyswatter"
- make ep93xx and at91rm9200 bitbang JTAG interfaces dependant on ARM host (thanks to Vincent Palatin)
- various whitespace fixes
- removed various warnings
- add support for Debian GNU/kFreeBSD (thanks to Uwe Hermann)
- fix OpenOCD compilation for various platforms (thanks to Uwe Hermann and Vincent Palatin)
- switched order of JTAG chain examination and validation (examine first, then multiple validation tries even if examination failed)
- added target_request subsystem to handle requests from the target (debug messages and tracepoints implemented, future enhancements might include
semihosting, all ARM7/9 only for now)
- added support for GDB vFlashXXX packets (thanks to Pavel Chromy)
- added support for receiving data via ARM7/9 DCC
- reworked flash writing. the 'flash write' command is now deprecated and replaced by 'flash write_binary' (old syntax and behaviour) and 'flash
write_image' (write image files (bin, hex, elf, s19) to a target).
- added support for AMD/ST/SST 29F400B non-cfi flashes
git-svn-id: svn://svn.berlios.de/openocd/trunk@190 b42882b7-edfa-0310-969c-e2dbd0fdcd60
Diffstat (limited to 'src/jtag/gw16012.c')
-rw-r--r-- | src/jtag/gw16012.c | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/src/jtag/gw16012.c b/src/jtag/gw16012.c index 8060d7d6..0d5c3f66 100644 --- a/src/jtag/gw16012.c +++ b/src/jtag/gw16012.c @@ -30,10 +30,8 @@ #endif /* system includes */ - -/* system includes */ // -ino: 060521-1036 -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) #include <sys/types.h> #include <machine/sysarch.h> @@ -47,7 +45,7 @@ #include "errno.h" #endif /* _WIN32 */ -#endif /* __FreeBSD__ */ +#endif /* __FreeBSD__, __FreeBSD_kernel__ */ #include <string.h> #include <stdlib.h> @@ -56,7 +54,7 @@ #include <time.h> #if PARPORT_USE_PPDEV == 1 -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) #include <dev/ppbus/ppi.h> #include <dev/ppbus/ppbconf.h> #define PPRSTATUS PPIGSTATUS @@ -137,7 +135,7 @@ void gw16012_data(u8 value) #if PARPORT_USE_PPDEV == 1 ioctl(device_handle, PPWDATA, &value); #else - #ifdef __FreeBSD__ + #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) outb(gw16012_port, value); #else outb(value, gw16012_port); @@ -158,7 +156,7 @@ void gw16012_control(u8 value) #if PARPORT_USE_PPDEV == 1 ioctl(device_handle, PPWCONTROL, &gw16012_control_value); #else - #ifdef __FreeBSD__ + #if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) outb(gw16012_port + 2, gw16012_control_value); #else outb(gw16012_control_value, gw16012_port + 2); @@ -485,7 +483,7 @@ int gw16012_init(void) return ERROR_JTAG_INIT_FAILED; } -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) DEBUG("opening /dev/ppi%d...", gw16012_port); snprintf(buffer, 256, "/dev/ppi%d", gw16012_port); @@ -504,7 +502,7 @@ int gw16012_init(void) DEBUG("...open"); -#ifndef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) i=ioctl(device_handle, PPCLAIM); if (i<0) { @@ -548,7 +546,7 @@ int gw16012_init(void) DEBUG("...privileges granted"); /* make sure parallel port is in right mode (clear tristate and interrupt */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__FreeBSD_kernel__) outb(gw16012_port + 2, 0x0); #else outb(0x0, gw16012_port + 2); |