From 64fb3e8df30a10163bb3474b6ae0664d59ae80bb Mon Sep 17 00:00:00 2001 From: Andree Buschmann Date: Sun, 3 Jan 2010 10:27:43 +0000 Subject: [PATCH] Fix more tabs git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24154 a1c6a512-1295-4272-9138-f99709370657 --- firmware/export/as3525.h | 2 +- firmware/export/config/ondavx767.h | 2 +- firmware/export/config/zenvisionm60gb.h | 2 +- firmware/export/i2c-coldfire.h | 38 ++-- firmware/export/lcd.h | 10 +- firmware/export/mas.h | 44 ++--- firmware/export/storage.h | 230 ++++++++++++------------ firmware/export/uda1380.h | 2 +- firmware/export/usb-tcc.h | 2 +- firmware/export/usb_ch9.h | 20 +-- 10 files changed, 176 insertions(+), 176 deletions(-) diff --git a/firmware/export/as3525.h b/firmware/export/as3525.h index d23bc2b0c8..a8903d17ef 100644 --- a/firmware/export/as3525.h +++ b/firmware/export/as3525.h @@ -295,7 +295,7 @@ interface */ #define UART_LNSTATUS_REG (*(volatile unsigned long*)(UART0_BASE + 0x14)) /* Line status register */ -#define SD_MCI_POWER (*(volatile unsigned long*)(SD_MCI_BASE + 0x0)) +#define SD_MCI_POWER (*(volatile unsigned long*)(SD_MCI_BASE + 0x0)) #define TIMER1_LOAD (*(volatile unsigned long*)(TIMER_BASE + 0x00)) /* 32-bit width */ diff --git a/firmware/export/config/ondavx767.h b/firmware/export/config/ondavx767.h index 661d3e9e5e..9c5248a6a1 100644 --- a/firmware/export/config/ondavx767.h +++ b/firmware/export/config/ondavx767.h @@ -159,7 +159,7 @@ #define BOOTFILE "rockbox." BOOTFILE_EXT #define BOOTDIR "/.rockbox" -#define CONFIG_USBOTG USBOTG_JZ4740 +#define CONFIG_USBOTG USBOTG_JZ4740 #define HAVE_USBSTACK #define USE_ROCKBOX_USB #define USB_VENDOR_ID 0x07C4 diff --git a/firmware/export/config/zenvisionm60gb.h b/firmware/export/config/zenvisionm60gb.h index 3e95ae7be7..bdede47962 100644 --- a/firmware/export/config/zenvisionm60gb.h +++ b/firmware/export/config/zenvisionm60gb.h @@ -158,7 +158,7 @@ #define BOOTFILE "rockbox." BOOTFILE_EXT #define BOOTDIR "/.rockbox" -/* #define CONFIG_USBOTG USBOTG_ISP1761 */ +/* #define CONFIG_USBOTG USBOTG_ISP1761 */ #define CONFIG_USBOTG USBOTG_ISP1583 #define HAVE_USBSTACK #define USE_ROCKBOX_USB diff --git a/firmware/export/i2c-coldfire.h b/firmware/export/i2c-coldfire.h index e5b34ddea6..b0d21a8631 100644 --- a/firmware/export/i2c-coldfire.h +++ b/firmware/export/i2c-coldfire.h @@ -44,31 +44,31 @@ void i2c_adjust_prescale(int multiplier); #define MAX_LOOP 0x100 /* TODO: select a better value */ /* PLLCR control */ -#define QSPISEL (1 << 11) /* Selects QSPI or I2C interface */ +#define QSPISEL (1 << 11) /* Selects QSPI or I2C interface */ /* Offsets to I2C registers from base address */ -#define O_MADR 0x00 /* Slave Address */ -#define O_MFDR 0x04 /* Frequency divider */ -#define O_MBCR 0x08 /* Control register */ -#define O_MBSR 0x0c /* Status register */ -#define O_MBDR 0x10 /* Data register */ +#define O_MADR 0x00 /* Slave Address */ +#define O_MFDR 0x04 /* Frequency divider */ +#define O_MBCR 0x08 /* Control register */ +#define O_MBSR 0x0c /* Status register */ +#define O_MBDR 0x10 /* Data register */ /* MBSR - Status register */ -#define ICF (1 << 7) /* Transfer Complete */ -#define IAAS (1 << 6) /* Addressed As Alave */ -#define IBB (1 << 5) /* Bus Busy */ -#define IAL (1 << 4) /* Arbitration Lost */ -#define SRW (1 << 2) /* Slave R/W */ -#define IIF (1 << 1) /* I2C Interrupt */ -#define RXAK (1 << 0) /* No Ack bit */ +#define ICF (1 << 7) /* Transfer Complete */ +#define IAAS (1 << 6) /* Addressed As Alave */ +#define IBB (1 << 5) /* Bus Busy */ +#define IAL (1 << 4) /* Arbitration Lost */ +#define SRW (1 << 2) /* Slave R/W */ +#define IIF (1 << 1) /* I2C Interrupt */ +#define RXAK (1 << 0) /* No Ack bit */ /* MBCR - Control register */ -#define IEN (1 << 7) /* I2C Enable */ -#define IIEN (1 << 6) /* Interrupt Enable */ -#define MSTA (1 << 5) /* Master/Slave select */ -#define MTX (1 << 4) /* Transmit/Receive */ -#define TXAK (1 << 3) /* Transfer ACK */ -#define RSTA (1 << 2) /* Restart.. */ +#define IEN (1 << 7) /* I2C Enable */ +#define IIEN (1 << 6) /* Interrupt Enable */ +#define MSTA (1 << 5) /* Master/Slave select */ +#define MTX (1 << 4) /* Transmit/Receive */ +#define TXAK (1 << 3) /* Transfer ACK */ +#define RSTA (1 << 2) /* Restart.. */ #endif diff --git a/firmware/export/lcd.h b/firmware/export/lcd.h index 89f39437a0..5145e7c21a 100644 --- a/firmware/export/lcd.h +++ b/firmware/export/lcd.h @@ -159,13 +159,13 @@ typedef unsigned char fb_data; #if defined(HAVE_LCD_MODES) void lcd_set_mode(int mode); #define LCD_MODE_RGB565 0x00000001 -#define LCD_MODE_YUV 0x00000002 -#define LCD_MODE_PAL256 0x00000004 +#define LCD_MODE_YUV 0x00000002 +#define LCD_MODE_PAL256 0x00000004 #if HAVE_LCD_MODES & LCD_MODE_PAL256 - void lcd_blit_pal256(unsigned char *src, int src_x, int src_y, int x, int y, - int width, int height); - void lcd_pal256_update_pal(fb_data *palette); + void lcd_blit_pal256(unsigned char *src, int src_x, int src_y, int x, int y, + int width, int height); + void lcd_pal256_update_pal(fb_data *palette); #endif #endif diff --git a/firmware/export/mas.h b/firmware/export/mas.h index 3cc9d3a34c..9cbe970b94 100644 --- a/firmware/export/mas.h +++ b/firmware/export/mas.h @@ -27,43 +27,43 @@ #define MAX_PEAK 0x8000 /* - MAS I2C defs + MAS I2C defs */ #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F) #define MAS_ADR 0x3c -#define MAS_DEV_WRITE (MAS_ADR | 0x00) -#define MAS_DEV_READ (MAS_ADR | 0x01) +#define MAS_DEV_WRITE (MAS_ADR | 0x00) +#define MAS_DEV_READ (MAS_ADR | 0x01) #elif CONFIG_CODEC == MAS3507D #define MAS_ADR 0x3a -#define MAS_DEV_WRITE (MAS_ADR | 0x00) -#define MAS_DEV_READ (MAS_ADR | 0x01) +#define MAS_DEV_WRITE (MAS_ADR | 0x00) +#define MAS_DEV_READ (MAS_ADR | 0x01) #endif /* registers..*/ #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F) -#define MAS_DATA_WRITE 0x68 +#define MAS_DATA_WRITE 0x68 #define MAS_DATA_READ 0x69 -#define MAS_CODEC_WRITE 0x6c +#define MAS_CODEC_WRITE 0x6c #define MAS_CODEC_READ 0x6d -#define MAS_CONTROL 0x6a -#define MAS_DCCF 0x76 -#define MAS_DCFR 0x77 +#define MAS_CONTROL 0x6a +#define MAS_DCCF 0x76 +#define MAS_DCFR 0x77 #elif CONFIG_CODEC == MAS3507D -#define MAS_DATA_WRITE 0x68 +#define MAS_DATA_WRITE 0x68 #define MAS_DATA_READ 0x69 -#define MAS_CONTROL 0x6a +#define MAS_CONTROL 0x6a #endif /* - * MAS register + * MAS register */ -#define MAS_REG_DCCF 0x8e -#define MAS_REG_MUTE 0xaa -#define MAS_REG_PIODATA 0xc8 -#define MAS_REG_StartUpConfig 0xe6 -#define MAS_REG_KPRESCALE 0xe7 +#define MAS_REG_DCCF 0x8e +#define MAS_REG_MUTE 0xaa +#define MAS_REG_PIODATA 0xc8 +#define MAS_REG_StartUpConfig 0xe6 +#define MAS_REG_KPRESCALE 0xe7 #if (CONFIG_CODEC == MAS3587F) || (CONFIG_CODEC == MAS3539F) #define MAS_REG_KMDB_SWITCH 0x21 #define MAS_REG_KMDB_STR 0x22 @@ -77,12 +77,12 @@ #define MAS_REG_VOLUME_CONTROL 0x10 #define MAS_REG_BALANCE 0x11 #define MAS_REG_KAVC 0x12 -#define MAS_REG_KBASS 0x14 -#define MAS_REG_KTREBLE 0x15 +#define MAS_REG_KBASS 0x14 +#define MAS_REG_KTREBLE 0x15 #elif CONFIG_CODEC == MAS3507D -#define MAS_REG_KBASS 0x6b -#define MAS_REG_KTREBLE 0x6f +#define MAS_REG_KBASS 0x6b +#define MAS_REG_KTREBLE 0x6f #endif /* diff --git a/firmware/export/storage.h b/firmware/export/storage.h index cb4ad7fc3a..0096e87a8d 100644 --- a/firmware/export/storage.h +++ b/firmware/export/storage.h @@ -56,140 +56,140 @@ struct storage_info * pointers, which doesn't work with argument-macros. */ #define storage_num_drives() NUM_DRIVES - #if (CONFIG_STORAGE & STORAGE_ATA) - #define storage_spindown ata_spindown - #define storage_sleep ata_sleep - #define storage_spin ata_spin + #if (CONFIG_STORAGE & STORAGE_ATA) + #define storage_spindown ata_spindown + #define storage_sleep ata_sleep + #define storage_spin ata_spin - #define storage_enable(on) ata_enable(on) - #define storage_sleepnow() ata_sleepnow() - #define storage_disk_is_active() ata_disk_is_active() - #define storage_soft_reset() ata_soft_reset() - #define storage_init() ata_init() - #define storage_close() ata_close() - #define storage_read_sectors(drive, start, count, buf) ata_read_sectors(IF_MD2(drive,) start, count, buf) - #define storage_write_sectors(drive, start, count, buf) ata_write_sectors(IF_MD2(drive,) start, count, buf) + #define storage_enable(on) ata_enable(on) + #define storage_sleepnow() ata_sleepnow() + #define storage_disk_is_active() ata_disk_is_active() + #define storage_soft_reset() ata_soft_reset() + #define storage_init() ata_init() + #define storage_close() ata_close() + #define storage_read_sectors(drive, start, count, buf) ata_read_sectors(IF_MD2(drive,) start, count, buf) + #define storage_write_sectors(drive, start, count, buf) ata_write_sectors(IF_MD2(drive,) start, count, buf) #ifdef HAVE_STORAGE_FLUSH #define storage_flush() (void)0 #endif - #define storage_last_disk_activity() ata_last_disk_activity() - #define storage_spinup_time() ata_spinup_time() - #define storage_get_identify() ata_get_identify() + #define storage_last_disk_activity() ata_last_disk_activity() + #define storage_spinup_time() ata_spinup_time() + #define storage_get_identify() ata_get_identify() - #ifdef STORAGE_GET_INFO - #define storage_get_info(drive, info) ata_get_info(IF_MD2(drive,) info) - #endif - #ifdef HAVE_HOTSWAP - #define storage_removable(drive) ata_removable(IF_MD(drive)) - #define storage_present(drive) ata_present(IF_MD(drive)) - #endif - #elif (CONFIG_STORAGE & STORAGE_SD) - #define storage_spindown sd_spindown - #define storage_sleep sd_sleep - #define storage_spin sd_spin + #ifdef STORAGE_GET_INFO + #define storage_get_info(drive, info) ata_get_info(IF_MD2(drive,) info) + #endif + #ifdef HAVE_HOTSWAP + #define storage_removable(drive) ata_removable(IF_MD(drive)) + #define storage_present(drive) ata_present(IF_MD(drive)) + #endif + #elif (CONFIG_STORAGE & STORAGE_SD) + #define storage_spindown sd_spindown + #define storage_sleep sd_sleep + #define storage_spin sd_spin - #define storage_enable(on) sd_enable(on) - #define storage_sleepnow() sd_sleepnow() - #define storage_disk_is_active() 0 - #define storage_soft_reset() (void)0 - #define storage_init() sd_init() - #define storage_read_sectors(drive, start, count, buf) sd_read_sectors(IF_MD2(drive,) start, count, buf) - #define storage_write_sectors(drive, start, count, buf) sd_write_sectors(IF_MD2(drive,) start, count, buf) + #define storage_enable(on) sd_enable(on) + #define storage_sleepnow() sd_sleepnow() + #define storage_disk_is_active() 0 + #define storage_soft_reset() (void)0 + #define storage_init() sd_init() + #define storage_read_sectors(drive, start, count, buf) sd_read_sectors(IF_MD2(drive,) start, count, buf) + #define storage_write_sectors(drive, start, count, buf) sd_write_sectors(IF_MD2(drive,) start, count, buf) #ifdef HAVE_STORAGE_FLUSH #define storage_flush() (void)0 #endif - #define storage_last_disk_activity() sd_last_disk_activity() - #define storage_spinup_time() 0 - #define storage_get_identify() sd_get_identify() + #define storage_last_disk_activity() sd_last_disk_activity() + #define storage_spinup_time() 0 + #define storage_get_identify() sd_get_identify() - #ifdef STORAGE_GET_INFO - #define storage_get_info(drive, info) sd_get_info(IF_MD2(drive,) info) - #endif - #ifdef HAVE_HOTSWAP - #define storage_removable(drive) sd_removable(IF_MD(drive)) - #define storage_present(drive) sd_present(IF_MD(drive)) - #endif - #elif (CONFIG_STORAGE & STORAGE_MMC) - #define storage_spindown mmc_spindown - #define storage_sleep mmc_sleep - #define storage_spin mmc_spin + #ifdef STORAGE_GET_INFO + #define storage_get_info(drive, info) sd_get_info(IF_MD2(drive,) info) + #endif + #ifdef HAVE_HOTSWAP + #define storage_removable(drive) sd_removable(IF_MD(drive)) + #define storage_present(drive) sd_present(IF_MD(drive)) + #endif + #elif (CONFIG_STORAGE & STORAGE_MMC) + #define storage_spindown mmc_spindown + #define storage_sleep mmc_sleep + #define storage_spin mmc_spin - #define storage_enable(on) mmc_enable(on) - #define storage_sleepnow() mmc_sleepnow() - #define storage_disk_is_active() mmc_disk_is_active() - #define storage_soft_reset() (void)0 - #define storage_init() mmc_init() - #define storage_read_sectors(drive, start, count, buf) mmc_read_sectors(IF_MD2(drive,) start, count, buf) - #define storage_write_sectors(drive, start, count, buf) mmc_write_sectors(IF_MD2(drive,) start, count, buf) + #define storage_enable(on) mmc_enable(on) + #define storage_sleepnow() mmc_sleepnow() + #define storage_disk_is_active() mmc_disk_is_active() + #define storage_soft_reset() (void)0 + #define storage_init() mmc_init() + #define storage_read_sectors(drive, start, count, buf) mmc_read_sectors(IF_MD2(drive,) start, count, buf) + #define storage_write_sectors(drive, start, count, buf) mmc_write_sectors(IF_MD2(drive,) start, count, buf) #ifdef HAVE_STORAGE_FLUSH #define storage_flush() (void)0 #endif - #define storage_last_disk_activity() mmc_last_disk_activity() - #define storage_spinup_time() 0 - #define storage_get_identify() mmc_get_identify() - - #ifdef STORAGE_GET_INFO - #define storage_get_info(drive, info) mmc_get_info(IF_MD2(drive,) info) - #endif - #ifdef HAVE_HOTSWAP - #define storage_removable(drive) mmc_removable(IF_MD(drive)) - #define storage_present(drive) mmc_present(IF_MD(drive)) - #endif - #elif (CONFIG_STORAGE & STORAGE_NAND) - #define storage_spindown nand_spindown - #define storage_sleep nand_sleep - #define storage_spin nand_spin - - #define storage_enable(on) (void)0 - #define storage_sleepnow() nand_sleepnow() - #define storage_disk_is_active() 0 - #define storage_soft_reset() (void)0 - #define storage_init() nand_init() - #define storage_read_sectors(drive, start, count, buf) nand_read_sectors(IF_MD2(drive,) start, count, buf) - #define storage_write_sectors(drive, start, count, buf) nand_write_sectors(IF_MD2(drive,) start, count, buf) - #ifdef HAVE_STORAGE_FLUSH - #define storage_flush() nand_flush() + #define storage_last_disk_activity() mmc_last_disk_activity() + #define storage_spinup_time() 0 + #define storage_get_identify() mmc_get_identify() + + #ifdef STORAGE_GET_INFO + #define storage_get_info(drive, info) mmc_get_info(IF_MD2(drive,) info) #endif - #define storage_last_disk_activity() nand_last_disk_activity() - #define storage_spinup_time() 0 - #define storage_get_identify() nand_get_identify() - - #ifdef STORAGE_GET_INFO - #define storage_get_info(drive, info) nand_get_info(IF_MD2(drive,) info) - #endif - #ifdef HAVE_HOTSWAP - #define storage_removable(drive) nand_removable(IF_MD(drive)) - #define storage_present(drive) nand_present(IF_MD(drive)) - #endif - #elif (CONFIG_STORAGE & STORAGE_RAMDISK) - #define storage_spindown ramdisk_spindown - #define storage_sleep ramdisk_sleep - #define storage_spin ramdisk_spin + #ifdef HAVE_HOTSWAP + #define storage_removable(drive) mmc_removable(IF_MD(drive)) + #define storage_present(drive) mmc_present(IF_MD(drive)) + #endif + #elif (CONFIG_STORAGE & STORAGE_NAND) + #define storage_spindown nand_spindown + #define storage_sleep nand_sleep + #define storage_spin nand_spin - #define storage_enable(on) (void)0 - #define storage_sleepnow() ramdisk_sleepnow() - #define storage_disk_is_active() 0 - #define storage_soft_reset() (void)0 - #define storage_init() ramdisk_init() - #define storage_read_sectors(drive, start, count, buf) ramdisk_read_sectors(IF_MD2(drive,) start, count, buf) - #define storage_write_sectors(drive, start, count, buf) ramdisk_write_sectors(IF_MD2(drive,) start, count, buf) + #define storage_enable(on) (void)0 + #define storage_sleepnow() nand_sleepnow() + #define storage_disk_is_active() 0 + #define storage_soft_reset() (void)0 + #define storage_init() nand_init() + #define storage_read_sectors(drive, start, count, buf) nand_read_sectors(IF_MD2(drive,) start, count, buf) + #define storage_write_sectors(drive, start, count, buf) nand_write_sectors(IF_MD2(drive,) start, count, buf) + #ifdef HAVE_STORAGE_FLUSH + #define storage_flush() nand_flush() + #endif + #define storage_last_disk_activity() nand_last_disk_activity() + #define storage_spinup_time() 0 + #define storage_get_identify() nand_get_identify() + + #ifdef STORAGE_GET_INFO + #define storage_get_info(drive, info) nand_get_info(IF_MD2(drive,) info) + #endif + #ifdef HAVE_HOTSWAP + #define storage_removable(drive) nand_removable(IF_MD(drive)) + #define storage_present(drive) nand_present(IF_MD(drive)) + #endif + #elif (CONFIG_STORAGE & STORAGE_RAMDISK) + #define storage_spindown ramdisk_spindown + #define storage_sleep ramdisk_sleep + #define storage_spin ramdisk_spin + + #define storage_enable(on) (void)0 + #define storage_sleepnow() ramdisk_sleepnow() + #define storage_disk_is_active() 0 + #define storage_soft_reset() (void)0 + #define storage_init() ramdisk_init() + #define storage_read_sectors(drive, start, count, buf) ramdisk_read_sectors(IF_MD2(drive,) start, count, buf) + #define storage_write_sectors(drive, start, count, buf) ramdisk_write_sectors(IF_MD2(drive,) start, count, buf) #ifdef HAVE_STORAGE_FLUSH #define storage_flush() (void)0 #endif - #define storage_last_disk_activity() ramdisk_last_disk_activity() - #define storage_spinup_time() 0 - #define storage_get_identify() ramdisk_get_identify() - - #ifdef STORAGE_GET_INFO - #define storage_get_info(drive, info) ramdisk_get_info(IF_MD2(drive,) info) - #endif - #ifdef HAVE_HOTSWAP - #define storage_removable(drive) ramdisk_removable(IF_MD(drive)) - #define storage_present(drive) ramdisk_present(IF_MD(drive)) - #endif - #else - //#error No storage driver! - #endif + #define storage_last_disk_activity() ramdisk_last_disk_activity() + #define storage_spinup_time() 0 + #define storage_get_identify() ramdisk_get_identify() + + #ifdef STORAGE_GET_INFO + #define storage_get_info(drive, info) ramdisk_get_info(IF_MD2(drive,) info) + #endif + #ifdef HAVE_HOTSWAP + #define storage_removable(drive) ramdisk_removable(IF_MD(drive)) + #define storage_present(drive) ramdisk_present(IF_MD(drive)) + #endif + #else + //#error No storage driver! + #endif #else /* NOT CONFIG_STORAGE_MULTI and NOT SIMULATOR*/ /* Simulator and multi-driver use normal functions */ diff --git a/firmware/export/uda1380.h b/firmware/export/uda1380.h index 6858f51e3c..e9292cf466 100644 --- a/firmware/export/uda1380.h +++ b/firmware/export/uda1380.h @@ -59,7 +59,7 @@ extern void audiohw_set_mixer_vol(int channel1, int channel2); /* REG_I2S: I2S settings */ -#define REG_I2S 0x01 +#define REG_I2S 0x01 #define I2S_IFMT_IIS (0 << 8) #define I2S_IFMT_LSB16 (1 << 8) #define I2S_IFMT_LSB18 (2 << 8) diff --git a/firmware/export/usb-tcc.h b/firmware/export/usb-tcc.h index 787977312f..c3932c7164 100644 --- a/firmware/export/usb-tcc.h +++ b/firmware/export/usb-tcc.h @@ -112,5 +112,5 @@ #define TCC7xx_USB_EP_DMA_ADDR1 MMR_REG16(USB_BASE, 0xa0) /* EP DMA MCU addr1 register */ #define TCC7xx_USB_EP_DMA_ADDR2 MMR_REG16(USB_BASE, 0xa4) /* EP DMA MCU addr2 register */ #define TCC7xx_USB_EP_DMA_STAT MMR_REG16(USB_BASE, 0xc0) /* EP DMA Transfer Status register */ -#define TCC7xx_USB_DELAY_CTRL MMR_REG16(USB_BASE, 0x80) /* Delay control register */ +#define TCC7xx_USB_DELAY_CTRL MMR_REG16(USB_BASE, 0x80) /* Delay control register */ #endif /* USB_TCC7XX_H */ diff --git a/firmware/export/usb_ch9.h b/firmware/export/usb_ch9.h index f05dbd3265..c11775b893 100644 --- a/firmware/export/usb_ch9.h +++ b/firmware/export/usb_ch9.h @@ -115,17 +115,17 @@ * are at most sixteen features of each type.) Hubs may also support a * new USB_REQ_TEST_AND_SET_FEATURE to put ports into L1 suspend. */ -#define USB_DEVICE_SELF_POWERED 0 /* (read only) */ -#define USB_DEVICE_REMOTE_WAKEUP 1 /* dev may initiate wakeup */ -#define USB_DEVICE_TEST_MODE 2 /* (wired high speed only) */ -#define USB_DEVICE_BATTERY 2 /* (wireless) */ -#define USB_DEVICE_B_HNP_ENABLE 3 /* (otg) dev may initiate HNP */ -#define USB_DEVICE_WUSB_DEVICE 3 /* (wireless)*/ -#define USB_DEVICE_A_HNP_SUPPORT 4 /* (otg) RH port supports HNP */ -#define USB_DEVICE_A_ALT_HNP_SUPPORT 5 /* (otg) other RH port does */ -#define USB_DEVICE_DEBUG_MODE 6 /* (special devices only) */ +#define USB_DEVICE_SELF_POWERED 0 /* (read only) */ +#define USB_DEVICE_REMOTE_WAKEUP 1 /* dev may initiate wakeup */ +#define USB_DEVICE_TEST_MODE 2 /* (wired high speed only) */ +#define USB_DEVICE_BATTERY 2 /* (wireless) */ +#define USB_DEVICE_B_HNP_ENABLE 3 /* (otg) dev may initiate HNP */ +#define USB_DEVICE_WUSB_DEVICE 3 /* (wireless)*/ +#define USB_DEVICE_A_HNP_SUPPORT 4 /* (otg) RH port supports HNP */ +#define USB_DEVICE_A_ALT_HNP_SUPPORT 5 /* (otg) other RH port does */ +#define USB_DEVICE_DEBUG_MODE 6 /* (special devices only) */ -#define USB_ENDPOINT_HALT 0 /* IN/OUT will STALL */ +#define USB_ENDPOINT_HALT 0 /* IN/OUT will STALL */ /**