diff options
265 files changed, 9740 insertions, 8981 deletions
diff --git a/MAINTAINERS b/MAINTAINERS index 277451a52695..16202c8ac68f 100644 --- a/MAINTAINERS +++ b/MAINTAINERS | |||
| @@ -378,8 +378,9 @@ T: git://git.kernel.org/pub/scm/linux/kernel/git/joro/linux-2.6-iommu.git | |||
| 378 | S: Supported | 378 | S: Supported |
| 379 | 379 | ||
| 380 | AMD MICROCODE UPDATE SUPPORT | 380 | AMD MICROCODE UPDATE SUPPORT |
| 381 | P: Peter Oruba | 381 | P: Andreas Herrmann |
| 382 | M: peter.oruba@amd.com | 382 | M: andeas.herrmann3@amd.com |
| 383 | L: amd64-microcode@amd64.org | ||
| 383 | S: Supported | 384 | S: Supported |
| 384 | 385 | ||
| 385 | AMS (Apple Motion Sensor) DRIVER | 386 | AMS (Apple Motion Sensor) DRIVER |
diff --git a/arch/alpha/kernel/osf_sys.c b/arch/alpha/kernel/osf_sys.c index f25f6c490952..18a3ea1aac51 100644 --- a/arch/alpha/kernel/osf_sys.c +++ b/arch/alpha/kernel/osf_sys.c | |||
| @@ -983,10 +983,12 @@ asmlinkage int | |||
| 983 | osf_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp, | 983 | osf_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp, |
| 984 | struct timeval32 __user *tvp) | 984 | struct timeval32 __user *tvp) |
| 985 | { | 985 | { |
| 986 | s64 timeout = MAX_SCHEDULE_TIMEOUT; | 986 | struct timespec end_time, *to = NULL; |
| 987 | if (tvp) { | 987 | if (tvp) { |
| 988 | time_t sec, usec; | 988 | time_t sec, usec; |
| 989 | 989 | ||
| 990 | to = &end_time; | ||
| 991 | |||
| 990 | if (!access_ok(VERIFY_READ, tvp, sizeof(*tvp)) | 992 | if (!access_ok(VERIFY_READ, tvp, sizeof(*tvp)) |
| 991 | || __get_user(sec, &tvp->tv_sec) | 993 | || __get_user(sec, &tvp->tv_sec) |
| 992 | || __get_user(usec, &tvp->tv_usec)) { | 994 | || __get_user(usec, &tvp->tv_usec)) { |
| @@ -996,14 +998,13 @@ osf_select(int n, fd_set __user *inp, fd_set __user *outp, fd_set __user *exp, | |||
| 996 | if (sec < 0 || usec < 0) | 998 | if (sec < 0 || usec < 0) |
| 997 | return -EINVAL; | 999 | return -EINVAL; |
| 998 | 1000 | ||
| 999 | if ((unsigned long) sec < MAX_SELECT_SECONDS) { | 1001 | if (poll_select_set_timeout(to, sec, usec * NSEC_PER_USEC)) |
| 1000 | timeout = (usec + 1000000/HZ - 1) / (1000000/HZ); | 1002 | return -EINVAL; |
| 1001 | timeout += sec * (unsigned long) HZ; | 1003 | |
| 1002 | } | ||
| 1003 | } | 1004 | } |
| 1004 | 1005 | ||
| 1005 | /* OSF does not copy back the remaining time. */ | 1006 | /* OSF does not copy back the remaining time. */ |
| 1006 | return core_sys_select(n, inp, outp, exp, &timeout); | 1007 | return core_sys_select(n, inp, outp, exp, to); |
| 1007 | } | 1008 | } |
| 1008 | 1009 | ||
| 1009 | struct rusage32 { | 1010 | struct rusage32 { |
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index f504c801792f..5021db2217ed 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
| @@ -540,16 +540,15 @@ config ARCH_OMAP | |||
| 540 | help | 540 | help |
| 541 | Support for TI's OMAP platform (OMAP1 and OMAP2). | 541 | Support for TI's OMAP platform (OMAP1 and OMAP2). |
| 542 | 542 | ||
| 543 | config ARCH_MSM7X00A | 543 | config ARCH_MSM |
| 544 | bool "Qualcomm MSM7X00A" | 544 | bool "Qualcomm MSM" |
| 545 | select GENERIC_TIME | 545 | select GENERIC_TIME |
| 546 | select GENERIC_CLOCKEVENTS | 546 | select GENERIC_CLOCKEVENTS |
| 547 | help | 547 | help |
| 548 | Support for Qualcomm MSM7X00A based systems. This runs on the ARM11 | 548 | Support for Qualcomm MSM7K based systems. This runs on the ARM11 |
| 549 | apps processor of the MSM7X00A and depends on a shared memory | 549 | apps processor of the MSM7K and depends on a shared memory |
| 550 | interface to the ARM9 modem processor which runs the baseband stack | 550 | interface to the ARM9 modem processor which runs the baseband stack |
| 551 | and controls some vital subsystems (clock and power control, etc). | 551 | and controls some vital subsystems (clock and power control, etc). |
| 552 | <http://www.cdmatech.com/products/msm7200_chipset_solution.jsp> | ||
| 553 | 552 | ||
| 554 | endchoice | 553 | endchoice |
| 555 | 554 | ||
diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 7d5121260fda..bd6e28115ebb 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile | |||
| @@ -141,7 +141,7 @@ endif | |||
| 141 | machine-$(CONFIG_ARCH_MX3) := mx3 | 141 | machine-$(CONFIG_ARCH_MX3) := mx3 |
| 142 | machine-$(CONFIG_ARCH_ORION5X) := orion5x | 142 | machine-$(CONFIG_ARCH_ORION5X) := orion5x |
| 143 | plat-$(CONFIG_PLAT_ORION) := orion | 143 | plat-$(CONFIG_PLAT_ORION) := orion |
| 144 | machine-$(CONFIG_ARCH_MSM7X00A) := msm | 144 | machine-$(CONFIG_ARCH_MSM) := msm |
| 145 | machine-$(CONFIG_ARCH_LOKI) := loki | 145 | machine-$(CONFIG_ARCH_LOKI) := loki |
| 146 | machine-$(CONFIG_ARCH_MV78XX0) := mv78xx0 | 146 | machine-$(CONFIG_ARCH_MV78XX0) := mv78xx0 |
| 147 | 147 | ||
diff --git a/arch/arm/configs/corgi_defconfig b/arch/arm/configs/corgi_defconfig index 9b8748a8d9dd..f3af0b593eb0 100644 --- a/arch/arm/configs/corgi_defconfig +++ b/arch/arm/configs/corgi_defconfig | |||
| @@ -1,71 +1,111 @@ | |||
| 1 | # | 1 | # |
| 2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
| 3 | # Linux kernel version: 2.6.15-rc2 | 3 | # Linux kernel version: 2.6.27 |
| 4 | # Mon Nov 28 10:30:09 2005 | 4 | # Mon Oct 20 10:12:23 2008 |
| 5 | # | 5 | # |
| 6 | CONFIG_ARM=y | 6 | CONFIG_ARM=y |
| 7 | CONFIG_SYS_SUPPORTS_APM_EMULATION=y | ||
| 8 | CONFIG_GENERIC_GPIO=y | ||
| 9 | CONFIG_GENERIC_TIME=y | ||
| 10 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
| 7 | CONFIG_MMU=y | 11 | CONFIG_MMU=y |
| 8 | CONFIG_UID16=y | 12 | # CONFIG_NO_IOPORT is not set |
| 13 | CONFIG_GENERIC_HARDIRQS=y | ||
| 14 | CONFIG_STACKTRACE_SUPPORT=y | ||
| 15 | CONFIG_HAVE_LATENCYTOP_SUPPORT=y | ||
| 16 | CONFIG_LOCKDEP_SUPPORT=y | ||
| 17 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
| 18 | CONFIG_HARDIRQS_SW_RESEND=y | ||
| 19 | CONFIG_GENERIC_IRQ_PROBE=y | ||
| 9 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 20 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
| 21 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
| 22 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
| 23 | CONFIG_GENERIC_HWEIGHT=y | ||
| 10 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 24 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
| 25 | CONFIG_ARCH_MTD_XIP=y | ||
| 26 | CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y | ||
| 27 | CONFIG_VECTORS_BASE=0xffff0000 | ||
| 28 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
| 11 | 29 | ||
| 12 | # | 30 | # |
| 13 | # Code maturity level options | 31 | # General setup |
| 14 | # | 32 | # |
| 15 | CONFIG_EXPERIMENTAL=y | 33 | CONFIG_EXPERIMENTAL=y |
| 16 | CONFIG_CLEAN_COMPILE=y | ||
| 17 | CONFIG_BROKEN_ON_SMP=y | 34 | CONFIG_BROKEN_ON_SMP=y |
| 18 | CONFIG_LOCK_KERNEL=y | 35 | CONFIG_LOCK_KERNEL=y |
| 19 | CONFIG_INIT_ENV_ARG_LIMIT=32 | 36 | CONFIG_INIT_ENV_ARG_LIMIT=32 |
| 20 | |||
| 21 | # | ||
| 22 | # General setup | ||
| 23 | # | ||
| 24 | CONFIG_LOCALVERSION="" | 37 | CONFIG_LOCALVERSION="" |
| 25 | CONFIG_LOCALVERSION_AUTO=y | 38 | CONFIG_LOCALVERSION_AUTO=y |
| 26 | CONFIG_SWAP=y | 39 | CONFIG_SWAP=y |
| 27 | CONFIG_SYSVIPC=y | 40 | CONFIG_SYSVIPC=y |
| 41 | CONFIG_SYSVIPC_SYSCTL=y | ||
| 28 | # CONFIG_POSIX_MQUEUE is not set | 42 | # CONFIG_POSIX_MQUEUE is not set |
| 29 | CONFIG_BSD_PROCESS_ACCT=y | 43 | CONFIG_BSD_PROCESS_ACCT=y |
| 30 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set | 44 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set |
| 31 | CONFIG_SYSCTL=y | 45 | # CONFIG_TASKSTATS is not set |
| 32 | # CONFIG_AUDIT is not set | 46 | # CONFIG_AUDIT is not set |
| 33 | CONFIG_HOTPLUG=y | ||
| 34 | CONFIG_KOBJECT_UEVENT=y | ||
| 35 | # CONFIG_IKCONFIG is not set | 47 | # CONFIG_IKCONFIG is not set |
| 36 | CONFIG_INITRAMFS_SOURCE="" | 48 | CONFIG_LOG_BUF_SHIFT=14 |
| 49 | # CONFIG_CGROUPS is not set | ||
| 50 | # CONFIG_GROUP_SCHED is not set | ||
| 51 | CONFIG_SYSFS_DEPRECATED=y | ||
| 52 | CONFIG_SYSFS_DEPRECATED_V2=y | ||
| 53 | # CONFIG_RELAY is not set | ||
| 54 | # CONFIG_NAMESPACES is not set | ||
| 55 | # CONFIG_BLK_DEV_INITRD is not set | ||
| 56 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | ||
| 57 | CONFIG_SYSCTL=y | ||
| 37 | CONFIG_EMBEDDED=y | 58 | CONFIG_EMBEDDED=y |
| 59 | CONFIG_UID16=y | ||
| 60 | CONFIG_SYSCTL_SYSCALL=y | ||
| 38 | CONFIG_KALLSYMS=y | 61 | CONFIG_KALLSYMS=y |
| 39 | # CONFIG_KALLSYMS_ALL is not set | 62 | # CONFIG_KALLSYMS_ALL is not set |
| 40 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | 63 | # CONFIG_KALLSYMS_EXTRA_PASS is not set |
| 64 | CONFIG_HOTPLUG=y | ||
| 41 | CONFIG_PRINTK=y | 65 | CONFIG_PRINTK=y |
| 42 | CONFIG_BUG=y | 66 | CONFIG_BUG=y |
| 67 | CONFIG_ELF_CORE=y | ||
| 68 | CONFIG_COMPAT_BRK=y | ||
| 43 | CONFIG_BASE_FULL=y | 69 | CONFIG_BASE_FULL=y |
| 44 | CONFIG_FUTEX=y | 70 | CONFIG_FUTEX=y |
| 71 | CONFIG_ANON_INODES=y | ||
| 45 | CONFIG_EPOLL=y | 72 | CONFIG_EPOLL=y |
| 46 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 73 | CONFIG_SIGNALFD=y |
| 74 | CONFIG_TIMERFD=y | ||
| 75 | CONFIG_EVENTFD=y | ||
| 47 | CONFIG_SHMEM=y | 76 | CONFIG_SHMEM=y |
| 48 | CONFIG_CC_ALIGN_FUNCTIONS=0 | 77 | CONFIG_AIO=y |
| 49 | CONFIG_CC_ALIGN_LABELS=0 | 78 | CONFIG_VM_EVENT_COUNTERS=y |
| 50 | CONFIG_CC_ALIGN_LOOPS=0 | 79 | CONFIG_SLUB_DEBUG=y |
| 51 | CONFIG_CC_ALIGN_JUMPS=0 | 80 | # CONFIG_SLAB is not set |
| 81 | CONFIG_SLUB=y | ||
| 82 | # CONFIG_SLOB is not set | ||
| 83 | CONFIG_PROFILING=y | ||
| 84 | # CONFIG_MARKERS is not set | ||
| 85 | CONFIG_OPROFILE=m | ||
| 86 | CONFIG_HAVE_OPROFILE=y | ||
| 87 | # CONFIG_KPROBES is not set | ||
| 88 | CONFIG_HAVE_KPROBES=y | ||
| 89 | CONFIG_HAVE_KRETPROBES=y | ||
| 90 | CONFIG_HAVE_CLK=y | ||
| 91 | CONFIG_HAVE_GENERIC_DMA_COHERENT=y | ||
| 92 | CONFIG_SLABINFO=y | ||
| 93 | CONFIG_RT_MUTEXES=y | ||
| 52 | # CONFIG_TINY_SHMEM is not set | 94 | # CONFIG_TINY_SHMEM is not set |
| 53 | CONFIG_BASE_SMALL=0 | 95 | CONFIG_BASE_SMALL=0 |
| 54 | |||
| 55 | # | ||
| 56 | # Loadable module support | ||
| 57 | # | ||
| 58 | CONFIG_MODULES=y | 96 | CONFIG_MODULES=y |
| 97 | # CONFIG_MODULE_FORCE_LOAD is not set | ||
| 59 | CONFIG_MODULE_UNLOAD=y | 98 | CONFIG_MODULE_UNLOAD=y |
| 60 | CONFIG_MODULE_FORCE_UNLOAD=y | 99 | CONFIG_MODULE_FORCE_UNLOAD=y |
| 61 | CONFIG_OBSOLETE_MODPARM=y | ||
| 62 | # CONFIG_MODVERSIONS is not set | 100 | # CONFIG_MODVERSIONS is not set |
| 63 | # CONFIG_MODULE_SRCVERSION_ALL is not set | 101 | # CONFIG_MODULE_SRCVERSION_ALL is not set |
| 64 | CONFIG_KMOD=y | 102 | CONFIG_KMOD=y |
| 65 | 103 | CONFIG_BLOCK=y | |
| 66 | # | 104 | # CONFIG_LBD is not set |
| 67 | # Block layer | 105 | # CONFIG_BLK_DEV_IO_TRACE is not set |
| 68 | # | 106 | # CONFIG_LSF is not set |
| 107 | # CONFIG_BLK_DEV_BSG is not set | ||
| 108 | # CONFIG_BLK_DEV_INTEGRITY is not set | ||
| 69 | 109 | ||
| 70 | # | 110 | # |
| 71 | # IO Schedulers | 111 | # IO Schedulers |
| @@ -79,50 +119,97 @@ CONFIG_DEFAULT_AS=y | |||
| 79 | # CONFIG_DEFAULT_CFQ is not set | 119 | # CONFIG_DEFAULT_CFQ is not set |
| 80 | # CONFIG_DEFAULT_NOOP is not set | 120 | # CONFIG_DEFAULT_NOOP is not set |
| 81 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 121 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
| 122 | CONFIG_CLASSIC_RCU=y | ||
| 82 | 123 | ||
| 83 | # | 124 | # |
| 84 | # System Type | 125 | # System Type |
| 85 | # | 126 | # |
| 127 | # CONFIG_ARCH_AAEC2000 is not set | ||
| 128 | # CONFIG_ARCH_INTEGRATOR is not set | ||
| 129 | # CONFIG_ARCH_REALVIEW is not set | ||
| 130 | # CONFIG_ARCH_VERSATILE is not set | ||
| 131 | # CONFIG_ARCH_AT91 is not set | ||
| 86 | # CONFIG_ARCH_CLPS7500 is not set | 132 | # CONFIG_ARCH_CLPS7500 is not set |
| 87 | # CONFIG_ARCH_CLPS711X is not set | 133 | # CONFIG_ARCH_CLPS711X is not set |
| 88 | # CONFIG_ARCH_CO285 is not set | ||
| 89 | # CONFIG_ARCH_EBSA110 is not set | 134 | # CONFIG_ARCH_EBSA110 is not set |
| 135 | # CONFIG_ARCH_EP93XX is not set | ||
| 90 | # CONFIG_ARCH_FOOTBRIDGE is not set | 136 | # CONFIG_ARCH_FOOTBRIDGE is not set |
| 91 | # CONFIG_ARCH_INTEGRATOR is not set | 137 | # CONFIG_ARCH_NETX is not set |
| 92 | # CONFIG_ARCH_IOP3XX is not set | 138 | # CONFIG_ARCH_H720X is not set |
| 93 | # CONFIG_ARCH_IXP4XX is not set | 139 | # CONFIG_ARCH_IMX is not set |
| 140 | # CONFIG_ARCH_IOP13XX is not set | ||
| 141 | # CONFIG_ARCH_IOP32X is not set | ||
| 142 | # CONFIG_ARCH_IOP33X is not set | ||
| 143 | # CONFIG_ARCH_IXP23XX is not set | ||
| 94 | # CONFIG_ARCH_IXP2000 is not set | 144 | # CONFIG_ARCH_IXP2000 is not set |
| 145 | # CONFIG_ARCH_IXP4XX is not set | ||
| 95 | # CONFIG_ARCH_L7200 is not set | 146 | # CONFIG_ARCH_L7200 is not set |
| 147 | # CONFIG_ARCH_KIRKWOOD is not set | ||
| 148 | # CONFIG_ARCH_KS8695 is not set | ||
| 149 | # CONFIG_ARCH_NS9XXX is not set | ||
| 150 | # CONFIG_ARCH_LOKI is not set | ||
| 151 | # CONFIG_ARCH_MV78XX0 is not set | ||
| 152 | # CONFIG_ARCH_MXC is not set | ||
| 153 | # CONFIG_ARCH_ORION5X is not set | ||
| 154 | # CONFIG_ARCH_PNX4008 is not set | ||
| 96 | CONFIG_ARCH_PXA=y | 155 | CONFIG_ARCH_PXA=y |
| 97 | # CONFIG_ARCH_RPC is not set | 156 | # CONFIG_ARCH_RPC is not set |
| 98 | # CONFIG_ARCH_SA1100 is not set | 157 | # CONFIG_ARCH_SA1100 is not set |
| 99 | # CONFIG_ARCH_S3C2410 is not set | 158 | # CONFIG_ARCH_S3C2410 is not set |
| 100 | # CONFIG_ARCH_SHARK is not set | 159 | # CONFIG_ARCH_SHARK is not set |
| 101 | # CONFIG_ARCH_LH7A40X is not set | 160 | # CONFIG_ARCH_LH7A40X is not set |
| 161 | # CONFIG_ARCH_DAVINCI is not set | ||
| 102 | # CONFIG_ARCH_OMAP is not set | 162 | # CONFIG_ARCH_OMAP is not set |
| 103 | # CONFIG_ARCH_VERSATILE is not set | 163 | # CONFIG_ARCH_MSM7X00A is not set |
| 104 | # CONFIG_ARCH_REALVIEW is not set | ||
| 105 | # CONFIG_ARCH_IMX is not set | ||
| 106 | # CONFIG_ARCH_H720X is not set | ||
| 107 | # CONFIG_ARCH_AAEC2000 is not set | ||
| 108 | 164 | ||
| 109 | # | 165 | # |
| 110 | # Intel PXA2xx Implementations | 166 | # Intel PXA2xx/PXA3xx Implementations |
| 111 | # | 167 | # |
| 168 | # CONFIG_ARCH_GUMSTIX is not set | ||
| 112 | # CONFIG_ARCH_LUBBOCK is not set | 169 | # CONFIG_ARCH_LUBBOCK is not set |
| 170 | # CONFIG_MACH_LOGICPD_PXA270 is not set | ||
| 113 | # CONFIG_MACH_MAINSTONE is not set | 171 | # CONFIG_MACH_MAINSTONE is not set |
| 172 | # CONFIG_MACH_MP900C is not set | ||
| 114 | # CONFIG_ARCH_PXA_IDP is not set | 173 | # CONFIG_ARCH_PXA_IDP is not set |
| 115 | CONFIG_PXA_SHARPSL=y | 174 | CONFIG_PXA_SHARPSL=y |
| 116 | CONFIG_PXA_SHARPSL_25x=y | ||
| 117 | # CONFIG_PXA_SHARPSL_27x is not set | ||
| 118 | CONFIG_MACH_POODLE=y | 175 | CONFIG_MACH_POODLE=y |
| 119 | CONFIG_MACH_CORGI=y | 176 | CONFIG_MACH_CORGI=y |
| 120 | CONFIG_MACH_SHEPHERD=y | 177 | CONFIG_MACH_SHEPHERD=y |
| 121 | CONFIG_MACH_HUSKY=y | 178 | CONFIG_MACH_HUSKY=y |
| 179 | # CONFIG_MACH_AKITA is not set | ||
| 180 | # CONFIG_MACH_SPITZ is not set | ||
| 181 | # CONFIG_MACH_BORZOI is not set | ||
| 122 | CONFIG_MACH_TOSA=y | 182 | CONFIG_MACH_TOSA=y |
| 183 | # CONFIG_ARCH_VIPER is not set | ||
| 184 | # CONFIG_ARCH_PXA_ESERIES is not set | ||
| 185 | # CONFIG_TRIZEPS_PXA is not set | ||
| 186 | # CONFIG_MACH_EM_X270 is not set | ||
| 187 | # CONFIG_MACH_COLIBRI is not set | ||
| 188 | # CONFIG_MACH_ZYLONITE is not set | ||
| 189 | # CONFIG_MACH_LITTLETON is not set | ||
| 190 | # CONFIG_MACH_TAVOREVB is not set | ||
| 191 | # CONFIG_MACH_SAAR is not set | ||
| 192 | # CONFIG_MACH_ARMCORE is not set | ||
| 193 | # CONFIG_MACH_CM_X300 is not set | ||
| 194 | # CONFIG_MACH_MAGICIAN is not set | ||
| 195 | # CONFIG_MACH_MIOA701 is not set | ||
| 196 | # CONFIG_MACH_PCM027 is not set | ||
| 197 | # CONFIG_ARCH_PXA_PALM is not set | ||
| 198 | # CONFIG_PXA_EZX is not set | ||
| 123 | CONFIG_PXA25x=y | 199 | CONFIG_PXA25x=y |
| 124 | CONFIG_PXA_SHARP_C7xx=y | 200 | CONFIG_PXA_SHARP_C7xx=y |
| 125 | CONFIG_PXA_SSP=y | 201 | CONFIG_PXA_SSP=y |
| 202 | # CONFIG_PXA_PWM is not set | ||
| 203 | # CONFIG_TOSA_BT is not set | ||
| 204 | CONFIG_PXA_HAVE_BOARD_IRQS=y | ||
| 205 | |||
| 206 | # | ||
| 207 | # Boot options | ||
| 208 | # | ||
| 209 | |||
| 210 | # | ||
| 211 | # Power management | ||
| 212 | # | ||
| 126 | 213 | ||
| 127 | # | 214 | # |
| 128 | # Processor Type | 215 | # Processor Type |
| @@ -131,25 +218,30 @@ CONFIG_CPU_32=y | |||
| 131 | CONFIG_CPU_XSCALE=y | 218 | CONFIG_CPU_XSCALE=y |
| 132 | CONFIG_CPU_32v5=y | 219 | CONFIG_CPU_32v5=y |
| 133 | CONFIG_CPU_ABRT_EV5T=y | 220 | CONFIG_CPU_ABRT_EV5T=y |
| 221 | CONFIG_CPU_PABRT_NOIFAR=y | ||
| 134 | CONFIG_CPU_CACHE_VIVT=y | 222 | CONFIG_CPU_CACHE_VIVT=y |
| 135 | CONFIG_CPU_TLB_V4WBI=y | 223 | CONFIG_CPU_TLB_V4WBI=y |
| 224 | CONFIG_CPU_CP15=y | ||
| 225 | CONFIG_CPU_CP15_MMU=y | ||
| 136 | 226 | ||
| 137 | # | 227 | # |
| 138 | # Processor Features | 228 | # Processor Features |
| 139 | # | 229 | # |
| 140 | CONFIG_ARM_THUMB=y | 230 | CONFIG_ARM_THUMB=y |
| 231 | # CONFIG_CPU_DCACHE_DISABLE is not set | ||
| 232 | # CONFIG_OUTER_CACHE is not set | ||
| 233 | # CONFIG_IWMMXT is not set | ||
| 141 | CONFIG_XSCALE_PMU=y | 234 | CONFIG_XSCALE_PMU=y |
| 235 | CONFIG_SHARP_LOCOMO=y | ||
| 142 | CONFIG_SHARP_PARAM=y | 236 | CONFIG_SHARP_PARAM=y |
| 237 | CONFIG_SHARPSL_PM=y | ||
| 143 | CONFIG_SHARP_SCOOP=y | 238 | CONFIG_SHARP_SCOOP=y |
| 144 | 239 | ||
| 145 | # | 240 | # |
| 146 | # Bus support | 241 | # Bus support |
| 147 | # | 242 | # |
| 148 | CONFIG_ISA_DMA_API=y | 243 | # CONFIG_PCI_SYSCALL is not set |
| 149 | 244 | # CONFIG_ARCH_SUPPORTS_MSI is not set | |
| 150 | # | ||
| 151 | # PCCARD (PCMCIA/CardBus) support | ||
| 152 | # | ||
| 153 | CONFIG_PCCARD=y | 245 | CONFIG_PCCARD=y |
| 154 | # CONFIG_PCMCIA_DEBUG is not set | 246 | # CONFIG_PCMCIA_DEBUG is not set |
| 155 | CONFIG_PCMCIA=y | 247 | CONFIG_PCMCIA=y |
| @@ -164,16 +256,32 @@ CONFIG_PCMCIA_PXA2XX=y | |||
| 164 | # | 256 | # |
| 165 | # Kernel Features | 257 | # Kernel Features |
| 166 | # | 258 | # |
| 259 | CONFIG_TICK_ONESHOT=y | ||
| 260 | # CONFIG_NO_HZ is not set | ||
| 261 | # CONFIG_HIGH_RES_TIMERS is not set | ||
| 262 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
| 263 | CONFIG_VMSPLIT_3G=y | ||
| 264 | # CONFIG_VMSPLIT_2G is not set | ||
| 265 | # CONFIG_VMSPLIT_1G is not set | ||
| 266 | CONFIG_PAGE_OFFSET=0xC0000000 | ||
| 167 | CONFIG_PREEMPT=y | 267 | CONFIG_PREEMPT=y |
| 168 | # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set | 268 | CONFIG_HZ=100 |
| 269 | # CONFIG_AEABI is not set | ||
| 270 | CONFIG_ARCH_FLATMEM_HAS_HOLES=y | ||
| 271 | # CONFIG_ARCH_SPARSEMEM_DEFAULT is not set | ||
| 272 | # CONFIG_ARCH_SELECT_MEMORY_MODEL is not set | ||
| 169 | CONFIG_SELECT_MEMORY_MODEL=y | 273 | CONFIG_SELECT_MEMORY_MODEL=y |
| 170 | CONFIG_FLATMEM_MANUAL=y | 274 | CONFIG_FLATMEM_MANUAL=y |
| 171 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 275 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
| 172 | # CONFIG_SPARSEMEM_MANUAL is not set | 276 | # CONFIG_SPARSEMEM_MANUAL is not set |
| 173 | CONFIG_FLATMEM=y | 277 | CONFIG_FLATMEM=y |
| 174 | CONFIG_FLAT_NODE_MEM_MAP=y | 278 | CONFIG_FLAT_NODE_MEM_MAP=y |
| 175 | # CONFIG_SPARSEMEM_STATIC is not set | 279 | CONFIG_PAGEFLAGS_EXTENDED=y |
| 176 | CONFIG_SPLIT_PTLOCK_CPUS=4096 | 280 | CONFIG_SPLIT_PTLOCK_CPUS=4096 |
| 281 | # CONFIG_RESOURCES_64BIT is not set | ||
| 282 | # CONFIG_PHYS_ADDR_T_64BIT is not set | ||
| 283 | CONFIG_ZONE_DMA_FLAG=0 | ||
| 284 | CONFIG_VIRT_TO_BUS=y | ||
| 177 | CONFIG_ALIGNMENT_TRAP=y | 285 | CONFIG_ALIGNMENT_TRAP=y |
| 178 | 286 | ||
| 179 | # | 287 | # |
| @@ -183,6 +291,13 @@ CONFIG_ZBOOT_ROM_TEXT=0x0 | |||
| 183 | CONFIG_ZBOOT_ROM_BSS=0x0 | 291 | CONFIG_ZBOOT_ROM_BSS=0x0 |
| 184 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" | 292 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" |
| 185 | # CONFIG_XIP_KERNEL is not set | 293 | # CONFIG_XIP_KERNEL is not set |
| 294 | # CONFIG_KEXEC is not set | ||
| 295 | |||
| 296 | # | ||
| 297 | # CPU Power Management | ||
| 298 | # | ||
| 299 | # CONFIG_CPU_FREQ is not set | ||
| 300 | # CONFIG_CPU_IDLE is not set | ||
| 186 | 301 | ||
| 187 | # | 302 | # |
| 188 | # Floating point emulation | 303 | # Floating point emulation |
| @@ -199,6 +314,7 @@ CONFIG_FPE_NWFPE=y | |||
| 199 | # Userspace binary formats | 314 | # Userspace binary formats |
| 200 | # | 315 | # |
| 201 | CONFIG_BINFMT_ELF=y | 316 | CONFIG_BINFMT_ELF=y |
| 317 | CONFIG_HAVE_AOUT=y | ||
| 202 | CONFIG_BINFMT_AOUT=m | 318 | CONFIG_BINFMT_AOUT=m |
| 203 | CONFIG_BINFMT_MISC=m | 319 | CONFIG_BINFMT_MISC=m |
| 204 | # CONFIG_ARTHUR is not set | 320 | # CONFIG_ARTHUR is not set |
| @@ -207,12 +323,12 @@ CONFIG_BINFMT_MISC=m | |||
| 207 | # Power management options | 323 | # Power management options |
| 208 | # | 324 | # |
| 209 | CONFIG_PM=y | 325 | CONFIG_PM=y |
| 210 | # CONFIG_PM_LEGACY is not set | 326 | # CONFIG_PM_DEBUG is not set |
| 211 | CONFIG_APM=y | 327 | CONFIG_PM_SLEEP=y |
| 212 | 328 | CONFIG_SUSPEND=y | |
| 213 | # | 329 | CONFIG_SUSPEND_FREEZER=y |
| 214 | # Networking | 330 | CONFIG_APM_EMULATION=y |
| 215 | # | 331 | CONFIG_ARCH_SUSPEND_POSSIBLE=y |
| 216 | CONFIG_NET=y | 332 | CONFIG_NET=y |
| 217 | 333 | ||
| 218 | # | 334 | # |
| @@ -223,6 +339,10 @@ CONFIG_PACKET_MMAP=y | |||
| 223 | CONFIG_UNIX=y | 339 | CONFIG_UNIX=y |
| 224 | CONFIG_XFRM=y | 340 | CONFIG_XFRM=y |
| 225 | CONFIG_XFRM_USER=m | 341 | CONFIG_XFRM_USER=m |
| 342 | # CONFIG_XFRM_SUB_POLICY is not set | ||
| 343 | # CONFIG_XFRM_MIGRATE is not set | ||
| 344 | # CONFIG_XFRM_STATISTICS is not set | ||
| 345 | CONFIG_XFRM_IPCOMP=m | ||
| 226 | # CONFIG_NET_KEY is not set | 346 | # CONFIG_NET_KEY is not set |
| 227 | CONFIG_INET=y | 347 | CONFIG_INET=y |
| 228 | # CONFIG_IP_MULTICAST is not set | 348 | # CONFIG_IP_MULTICAST is not set |
| @@ -236,140 +356,131 @@ CONFIG_SYN_COOKIES=y | |||
| 236 | # CONFIG_INET_AH is not set | 356 | # CONFIG_INET_AH is not set |
| 237 | # CONFIG_INET_ESP is not set | 357 | # CONFIG_INET_ESP is not set |
| 238 | # CONFIG_INET_IPCOMP is not set | 358 | # CONFIG_INET_IPCOMP is not set |
| 239 | # CONFIG_INET_TUNNEL is not set | 359 | # CONFIG_INET_XFRM_TUNNEL is not set |
| 360 | CONFIG_INET_TUNNEL=m | ||
| 361 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
| 362 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
| 363 | CONFIG_INET_XFRM_MODE_BEET=y | ||
| 364 | # CONFIG_INET_LRO is not set | ||
| 240 | CONFIG_INET_DIAG=y | 365 | CONFIG_INET_DIAG=y |
| 241 | CONFIG_INET_TCP_DIAG=y | 366 | CONFIG_INET_TCP_DIAG=y |
| 242 | # CONFIG_TCP_CONG_ADVANCED is not set | 367 | # CONFIG_TCP_CONG_ADVANCED is not set |
| 243 | CONFIG_TCP_CONG_BIC=y | 368 | CONFIG_TCP_CONG_CUBIC=y |
| 244 | 369 | CONFIG_DEFAULT_TCP_CONG="cubic" | |
| 245 | # | 370 | # CONFIG_TCP_MD5SIG is not set |
| 246 | # IP: Virtual Server Configuration | ||
| 247 | # | ||
| 248 | # CONFIG_IP_VS is not set | ||
| 249 | CONFIG_IPV6=m | 371 | CONFIG_IPV6=m |
| 250 | # CONFIG_IPV6_PRIVACY is not set | 372 | # CONFIG_IPV6_PRIVACY is not set |
| 373 | # CONFIG_IPV6_ROUTER_PREF is not set | ||
| 374 | # CONFIG_IPV6_OPTIMISTIC_DAD is not set | ||
| 251 | CONFIG_INET6_AH=m | 375 | CONFIG_INET6_AH=m |
| 252 | CONFIG_INET6_ESP=m | 376 | CONFIG_INET6_ESP=m |
| 253 | CONFIG_INET6_IPCOMP=m | 377 | CONFIG_INET6_IPCOMP=m |
| 378 | # CONFIG_IPV6_MIP6 is not set | ||
| 379 | CONFIG_INET6_XFRM_TUNNEL=m | ||
| 254 | CONFIG_INET6_TUNNEL=m | 380 | CONFIG_INET6_TUNNEL=m |
| 381 | CONFIG_INET6_XFRM_MODE_TRANSPORT=m | ||
| 382 | CONFIG_INET6_XFRM_MODE_TUNNEL=m | ||
| 383 | CONFIG_INET6_XFRM_MODE_BEET=m | ||
| 384 | # CONFIG_INET6_XFRM_MODE_ROUTEOPTIMIZATION is not set | ||
| 385 | CONFIG_IPV6_SIT=m | ||
| 386 | CONFIG_IPV6_NDISC_NODETYPE=y | ||
| 255 | CONFIG_IPV6_TUNNEL=m | 387 | CONFIG_IPV6_TUNNEL=m |
| 388 | # CONFIG_IPV6_MULTIPLE_TABLES is not set | ||
| 389 | # CONFIG_IPV6_MROUTE is not set | ||
| 390 | # CONFIG_NETWORK_SECMARK is not set | ||
| 256 | CONFIG_NETFILTER=y | 391 | CONFIG_NETFILTER=y |
| 257 | # CONFIG_NETFILTER_DEBUG is not set | 392 | # CONFIG_NETFILTER_DEBUG is not set |
| 393 | CONFIG_NETFILTER_ADVANCED=y | ||
| 258 | 394 | ||
| 259 | # | 395 | # |
| 260 | # Core Netfilter Configuration | 396 | # Core Netfilter Configuration |
| 261 | # | 397 | # |
| 262 | # CONFIG_NETFILTER_NETLINK is not set | 398 | # CONFIG_NETFILTER_NETLINK_QUEUE is not set |
| 399 | # CONFIG_NETFILTER_NETLINK_LOG is not set | ||
| 400 | # CONFIG_NF_CONNTRACK is not set | ||
| 401 | CONFIG_NETFILTER_XTABLES=m | ||
| 402 | # CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set | ||
| 403 | # CONFIG_NETFILTER_XT_TARGET_DSCP is not set | ||
| 404 | # CONFIG_NETFILTER_XT_TARGET_MARK is not set | ||
| 405 | # CONFIG_NETFILTER_XT_TARGET_NFLOG is not set | ||
| 406 | # CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set | ||
| 407 | # CONFIG_NETFILTER_XT_TARGET_RATEEST is not set | ||
| 408 | # CONFIG_NETFILTER_XT_TARGET_TRACE is not set | ||
| 409 | # CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set | ||
| 410 | # CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP is not set | ||
| 411 | # CONFIG_NETFILTER_XT_MATCH_COMMENT is not set | ||
| 412 | # CONFIG_NETFILTER_XT_MATCH_DCCP is not set | ||
| 413 | # CONFIG_NETFILTER_XT_MATCH_DSCP is not set | ||
| 414 | # CONFIG_NETFILTER_XT_MATCH_ESP is not set | ||
| 415 | # CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set | ||
| 416 | # CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set | ||
| 417 | # CONFIG_NETFILTER_XT_MATCH_LENGTH is not set | ||
| 418 | # CONFIG_NETFILTER_XT_MATCH_LIMIT is not set | ||
| 419 | # CONFIG_NETFILTER_XT_MATCH_MAC is not set | ||
| 420 | # CONFIG_NETFILTER_XT_MATCH_MARK is not set | ||
| 421 | # CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set | ||
| 422 | # CONFIG_NETFILTER_XT_MATCH_OWNER is not set | ||
| 423 | # CONFIG_NETFILTER_XT_MATCH_POLICY is not set | ||
| 424 | # CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set | ||
| 425 | # CONFIG_NETFILTER_XT_MATCH_QUOTA is not set | ||
| 426 | # CONFIG_NETFILTER_XT_MATCH_RATEEST is not set | ||
| 427 | # CONFIG_NETFILTER_XT_MATCH_REALM is not set | ||
| 428 | # CONFIG_NETFILTER_XT_MATCH_RECENT is not set | ||
| 429 | # CONFIG_NETFILTER_XT_MATCH_SCTP is not set | ||
| 430 | # CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set | ||
| 431 | # CONFIG_NETFILTER_XT_MATCH_STRING is not set | ||
| 432 | # CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set | ||
| 433 | # CONFIG_NETFILTER_XT_MATCH_TIME is not set | ||
| 434 | # CONFIG_NETFILTER_XT_MATCH_U32 is not set | ||
| 435 | # CONFIG_IP_VS is not set | ||
| 263 | 436 | ||
| 264 | # | 437 | # |
| 265 | # IP: Netfilter Configuration | 438 | # IP: Netfilter Configuration |
| 266 | # | 439 | # |
| 267 | CONFIG_IP_NF_CONNTRACK=m | 440 | # CONFIG_NF_DEFRAG_IPV4 is not set |
| 268 | # CONFIG_IP_NF_CT_ACCT is not set | ||
| 269 | # CONFIG_IP_NF_CONNTRACK_MARK is not set | ||
| 270 | # CONFIG_IP_NF_CONNTRACK_EVENTS is not set | ||
| 271 | CONFIG_IP_NF_CT_PROTO_SCTP=m | ||
| 272 | CONFIG_IP_NF_FTP=m | ||
| 273 | CONFIG_IP_NF_IRC=m | ||
| 274 | # CONFIG_IP_NF_NETBIOS_NS is not set | ||
| 275 | CONFIG_IP_NF_TFTP=m | ||
| 276 | CONFIG_IP_NF_AMANDA=m | ||
| 277 | # CONFIG_IP_NF_PPTP is not set | ||
| 278 | CONFIG_IP_NF_QUEUE=m | 441 | CONFIG_IP_NF_QUEUE=m |
| 279 | CONFIG_IP_NF_IPTABLES=m | 442 | CONFIG_IP_NF_IPTABLES=m |
| 280 | CONFIG_IP_NF_MATCH_LIMIT=m | 443 | CONFIG_IP_NF_MATCH_ADDRTYPE=m |
| 281 | CONFIG_IP_NF_MATCH_IPRANGE=m | 444 | # CONFIG_IP_NF_MATCH_AH is not set |
| 282 | CONFIG_IP_NF_MATCH_MAC=m | ||
| 283 | CONFIG_IP_NF_MATCH_PKTTYPE=m | ||
| 284 | CONFIG_IP_NF_MATCH_MARK=m | ||
| 285 | CONFIG_IP_NF_MATCH_MULTIPORT=m | ||
| 286 | CONFIG_IP_NF_MATCH_TOS=m | ||
| 287 | CONFIG_IP_NF_MATCH_RECENT=m | ||
| 288 | CONFIG_IP_NF_MATCH_ECN=m | 445 | CONFIG_IP_NF_MATCH_ECN=m |
| 289 | CONFIG_IP_NF_MATCH_DSCP=m | ||
| 290 | CONFIG_IP_NF_MATCH_AH_ESP=m | ||
| 291 | CONFIG_IP_NF_MATCH_LENGTH=m | ||
| 292 | CONFIG_IP_NF_MATCH_TTL=m | 446 | CONFIG_IP_NF_MATCH_TTL=m |
| 293 | CONFIG_IP_NF_MATCH_TCPMSS=m | ||
| 294 | CONFIG_IP_NF_MATCH_HELPER=m | ||
| 295 | CONFIG_IP_NF_MATCH_STATE=m | ||
| 296 | CONFIG_IP_NF_MATCH_CONNTRACK=m | ||
| 297 | CONFIG_IP_NF_MATCH_OWNER=m | ||
| 298 | CONFIG_IP_NF_MATCH_ADDRTYPE=m | ||
| 299 | CONFIG_IP_NF_MATCH_REALM=m | ||
| 300 | CONFIG_IP_NF_MATCH_SCTP=m | ||
| 301 | # CONFIG_IP_NF_MATCH_DCCP is not set | ||
| 302 | CONFIG_IP_NF_MATCH_COMMENT=m | ||
| 303 | CONFIG_IP_NF_MATCH_HASHLIMIT=m | ||
| 304 | # CONFIG_IP_NF_MATCH_STRING is not set | ||
| 305 | CONFIG_IP_NF_FILTER=m | 447 | CONFIG_IP_NF_FILTER=m |
| 306 | # CONFIG_IP_NF_TARGET_REJECT is not set | 448 | # CONFIG_IP_NF_TARGET_REJECT is not set |
| 307 | CONFIG_IP_NF_TARGET_LOG=m | 449 | CONFIG_IP_NF_TARGET_LOG=m |
| 308 | CONFIG_IP_NF_TARGET_ULOG=m | 450 | CONFIG_IP_NF_TARGET_ULOG=m |
| 309 | CONFIG_IP_NF_TARGET_TCPMSS=m | ||
| 310 | # CONFIG_IP_NF_TARGET_NFQUEUE is not set | ||
| 311 | CONFIG_IP_NF_NAT=m | ||
| 312 | CONFIG_IP_NF_NAT_NEEDED=y | ||
| 313 | # CONFIG_IP_NF_TARGET_MASQUERADE is not set | ||
| 314 | # CONFIG_IP_NF_TARGET_REDIRECT is not set | ||
| 315 | # CONFIG_IP_NF_TARGET_NETMAP is not set | ||
| 316 | # CONFIG_IP_NF_TARGET_SAME is not set | ||
| 317 | # CONFIG_IP_NF_NAT_SNMP_BASIC is not set | ||
| 318 | CONFIG_IP_NF_NAT_IRC=m | ||
| 319 | CONFIG_IP_NF_NAT_FTP=m | ||
| 320 | CONFIG_IP_NF_NAT_TFTP=m | ||
| 321 | CONFIG_IP_NF_NAT_AMANDA=m | ||
| 322 | CONFIG_IP_NF_MANGLE=m | 451 | CONFIG_IP_NF_MANGLE=m |
| 323 | # CONFIG_IP_NF_TARGET_TOS is not set | ||
| 324 | # CONFIG_IP_NF_TARGET_ECN is not set | 452 | # CONFIG_IP_NF_TARGET_ECN is not set |
| 325 | # CONFIG_IP_NF_TARGET_DSCP is not set | ||
| 326 | # CONFIG_IP_NF_TARGET_MARK is not set | ||
| 327 | # CONFIG_IP_NF_TARGET_CLASSIFY is not set | ||
| 328 | # CONFIG_IP_NF_TARGET_TTL is not set | 453 | # CONFIG_IP_NF_TARGET_TTL is not set |
| 329 | CONFIG_IP_NF_RAW=m | 454 | CONFIG_IP_NF_RAW=m |
| 330 | # CONFIG_IP_NF_TARGET_NOTRACK is not set | ||
| 331 | CONFIG_IP_NF_ARPTABLES=m | 455 | CONFIG_IP_NF_ARPTABLES=m |
| 332 | CONFIG_IP_NF_ARPFILTER=m | 456 | CONFIG_IP_NF_ARPFILTER=m |
| 333 | CONFIG_IP_NF_ARP_MANGLE=m | 457 | CONFIG_IP_NF_ARP_MANGLE=m |
| 334 | 458 | ||
| 335 | # | 459 | # |
| 336 | # IPv6: Netfilter Configuration (EXPERIMENTAL) | 460 | # IPv6: Netfilter Configuration |
| 337 | # | 461 | # |
| 338 | CONFIG_IP6_NF_QUEUE=m | 462 | CONFIG_IP6_NF_QUEUE=m |
| 339 | CONFIG_IP6_NF_IPTABLES=m | 463 | CONFIG_IP6_NF_IPTABLES=m |
| 340 | CONFIG_IP6_NF_MATCH_LIMIT=m | 464 | # CONFIG_IP6_NF_MATCH_AH is not set |
| 341 | CONFIG_IP6_NF_MATCH_MAC=m | 465 | CONFIG_IP6_NF_MATCH_EUI64=m |
| 342 | CONFIG_IP6_NF_MATCH_RT=m | ||
| 343 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
| 344 | CONFIG_IP6_NF_MATCH_FRAG=m | 466 | CONFIG_IP6_NF_MATCH_FRAG=m |
| 467 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
| 345 | CONFIG_IP6_NF_MATCH_HL=m | 468 | CONFIG_IP6_NF_MATCH_HL=m |
| 346 | CONFIG_IP6_NF_MATCH_MULTIPORT=m | ||
| 347 | CONFIG_IP6_NF_MATCH_OWNER=m | ||
| 348 | CONFIG_IP6_NF_MATCH_MARK=m | ||
| 349 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m | 469 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m |
| 350 | CONFIG_IP6_NF_MATCH_AHESP=m | 470 | # CONFIG_IP6_NF_MATCH_MH is not set |
| 351 | CONFIG_IP6_NF_MATCH_LENGTH=m | 471 | CONFIG_IP6_NF_MATCH_RT=m |
| 352 | CONFIG_IP6_NF_MATCH_EUI64=m | ||
| 353 | CONFIG_IP6_NF_FILTER=m | ||
| 354 | # CONFIG_IP6_NF_TARGET_LOG is not set | 472 | # CONFIG_IP6_NF_TARGET_LOG is not set |
| 473 | CONFIG_IP6_NF_FILTER=m | ||
| 355 | # CONFIG_IP6_NF_TARGET_REJECT is not set | 474 | # CONFIG_IP6_NF_TARGET_REJECT is not set |
| 356 | # CONFIG_IP6_NF_TARGET_NFQUEUE is not set | ||
| 357 | CONFIG_IP6_NF_MANGLE=m | 475 | CONFIG_IP6_NF_MANGLE=m |
| 358 | # CONFIG_IP6_NF_TARGET_MARK is not set | ||
| 359 | # CONFIG_IP6_NF_TARGET_HL is not set | 476 | # CONFIG_IP6_NF_TARGET_HL is not set |
| 360 | CONFIG_IP6_NF_RAW=m | 477 | CONFIG_IP6_NF_RAW=m |
| 361 | |||
| 362 | # | ||
| 363 | # DCCP Configuration (EXPERIMENTAL) | ||
| 364 | # | ||
| 365 | # CONFIG_IP_DCCP is not set | 478 | # CONFIG_IP_DCCP is not set |
| 366 | |||
| 367 | # | ||
| 368 | # SCTP Configuration (EXPERIMENTAL) | ||
| 369 | # | ||
| 370 | # CONFIG_IP_SCTP is not set | 479 | # CONFIG_IP_SCTP is not set |
| 480 | # CONFIG_TIPC is not set | ||
| 371 | # CONFIG_ATM is not set | 481 | # CONFIG_ATM is not set |
| 372 | # CONFIG_BRIDGE is not set | 482 | # CONFIG_BRIDGE is not set |
| 483 | # CONFIG_NET_DSA is not set | ||
| 373 | # CONFIG_VLAN_8021Q is not set | 484 | # CONFIG_VLAN_8021Q is not set |
| 374 | # CONFIG_DECNET is not set | 485 | # CONFIG_DECNET is not set |
| 375 | # CONFIG_LLC2 is not set | 486 | # CONFIG_LLC2 is not set |
| @@ -377,21 +488,16 @@ CONFIG_IP6_NF_RAW=m | |||
| 377 | # CONFIG_ATALK is not set | 488 | # CONFIG_ATALK is not set |
| 378 | # CONFIG_X25 is not set | 489 | # CONFIG_X25 is not set |
| 379 | # CONFIG_LAPB is not set | 490 | # CONFIG_LAPB is not set |
| 380 | # CONFIG_NET_DIVERT is not set | ||
| 381 | # CONFIG_ECONET is not set | 491 | # CONFIG_ECONET is not set |
| 382 | # CONFIG_WAN_ROUTER is not set | 492 | # CONFIG_WAN_ROUTER is not set |
| 383 | |||
| 384 | # | ||
| 385 | # QoS and/or fair queueing | ||
| 386 | # | ||
| 387 | # CONFIG_NET_SCHED is not set | 493 | # CONFIG_NET_SCHED is not set |
| 388 | CONFIG_NET_CLS_ROUTE=y | ||
| 389 | 494 | ||
| 390 | # | 495 | # |
| 391 | # Network testing | 496 | # Network testing |
| 392 | # | 497 | # |
| 393 | # CONFIG_NET_PKTGEN is not set | 498 | # CONFIG_NET_PKTGEN is not set |
| 394 | # CONFIG_HAMRADIO is not set | 499 | # CONFIG_HAMRADIO is not set |
| 500 | # CONFIG_CAN is not set | ||
| 395 | CONFIG_IRDA=m | 501 | CONFIG_IRDA=m |
| 396 | 502 | ||
| 397 | # | 503 | # |
| @@ -421,27 +527,17 @@ CONFIG_IRCOMM=m | |||
| 421 | # | 527 | # |
| 422 | # Dongle support | 528 | # Dongle support |
| 423 | # | 529 | # |
| 424 | 530 | # CONFIG_KINGSUN_DONGLE is not set | |
| 425 | # | 531 | # CONFIG_KSDAZZLE_DONGLE is not set |
| 426 | # Old SIR device drivers | 532 | # CONFIG_KS959_DONGLE is not set |
| 427 | # | ||
| 428 | # CONFIG_IRPORT_SIR is not set | ||
| 429 | |||
| 430 | # | ||
| 431 | # Old Serial dongle support | ||
| 432 | # | ||
| 433 | 533 | ||
| 434 | # | 534 | # |
| 435 | # FIR device drivers | 535 | # FIR device drivers |
| 436 | # | 536 | # |
| 437 | # CONFIG_USB_IRDA is not set | 537 | # CONFIG_USB_IRDA is not set |
| 438 | # CONFIG_SIGMATEL_FIR is not set | 538 | # CONFIG_SIGMATEL_FIR is not set |
| 439 | # CONFIG_NSC_FIR is not set | ||
| 440 | # CONFIG_WINBOND_FIR is not set | ||
| 441 | # CONFIG_SMC_IRCC_FIR is not set | ||
| 442 | # CONFIG_ALI_FIR is not set | ||
| 443 | # CONFIG_VIA_FIR is not set | ||
| 444 | CONFIG_PXA_FICP=m | 539 | CONFIG_PXA_FICP=m |
| 540 | # CONFIG_MCS_FIR is not set | ||
| 445 | CONFIG_BT=m | 541 | CONFIG_BT=m |
| 446 | CONFIG_BT_L2CAP=m | 542 | CONFIG_BT_L2CAP=m |
| 447 | CONFIG_BT_SCO=m | 543 | CONFIG_BT_SCO=m |
| @@ -457,9 +553,12 @@ CONFIG_BT_HIDP=m | |||
| 457 | # | 553 | # |
| 458 | CONFIG_BT_HCIUSB=m | 554 | CONFIG_BT_HCIUSB=m |
| 459 | # CONFIG_BT_HCIUSB_SCO is not set | 555 | # CONFIG_BT_HCIUSB_SCO is not set |
| 556 | # CONFIG_BT_HCIBTUSB is not set | ||
| 557 | # CONFIG_BT_HCIBTSDIO is not set | ||
| 460 | CONFIG_BT_HCIUART=m | 558 | CONFIG_BT_HCIUART=m |
| 461 | CONFIG_BT_HCIUART_H4=y | 559 | CONFIG_BT_HCIUART_H4=y |
| 462 | CONFIG_BT_HCIUART_BCSP=y | 560 | CONFIG_BT_HCIUART_BCSP=y |
| 561 | # CONFIG_BT_HCIUART_LL is not set | ||
| 463 | CONFIG_BT_HCIBCM203X=m | 562 | CONFIG_BT_HCIBCM203X=m |
| 464 | CONFIG_BT_HCIBPA10X=m | 563 | CONFIG_BT_HCIBPA10X=m |
| 465 | CONFIG_BT_HCIBFUSB=m | 564 | CONFIG_BT_HCIBFUSB=m |
| @@ -468,11 +567,20 @@ CONFIG_BT_HCIBT3C=m | |||
| 468 | CONFIG_BT_HCIBLUECARD=m | 567 | CONFIG_BT_HCIBLUECARD=m |
| 469 | CONFIG_BT_HCIBTUART=m | 568 | CONFIG_BT_HCIBTUART=m |
| 470 | CONFIG_BT_HCIVHCI=m | 569 | CONFIG_BT_HCIVHCI=m |
| 570 | # CONFIG_AF_RXRPC is not set | ||
| 571 | # CONFIG_PHONET is not set | ||
| 572 | CONFIG_WIRELESS=y | ||
| 573 | # CONFIG_CFG80211 is not set | ||
| 574 | # CONFIG_WIRELESS_OLD_REGULATORY is not set | ||
| 575 | # CONFIG_WIRELESS_EXT is not set | ||
| 576 | # CONFIG_MAC80211 is not set | ||
| 471 | CONFIG_IEEE80211=m | 577 | CONFIG_IEEE80211=m |
| 472 | # CONFIG_IEEE80211_DEBUG is not set | 578 | # CONFIG_IEEE80211_DEBUG is not set |
| 473 | CONFIG_IEEE80211_CRYPT_WEP=m | 579 | CONFIG_IEEE80211_CRYPT_WEP=m |
| 474 | # CONFIG_IEEE80211_CRYPT_CCMP is not set | 580 | # CONFIG_IEEE80211_CRYPT_CCMP is not set |
| 475 | # CONFIG_IEEE80211_CRYPT_TKIP is not set | 581 | # CONFIG_IEEE80211_CRYPT_TKIP is not set |
| 582 | # CONFIG_RFKILL is not set | ||
| 583 | # CONFIG_NET_9P is not set | ||
| 476 | 584 | ||
| 477 | # | 585 | # |
| 478 | # Device Drivers | 586 | # Device Drivers |
| @@ -481,19 +589,16 @@ CONFIG_IEEE80211_CRYPT_WEP=m | |||
| 481 | # | 589 | # |
| 482 | # Generic Driver Options | 590 | # Generic Driver Options |
| 483 | # | 591 | # |
| 592 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
| 484 | CONFIG_STANDALONE=y | 593 | CONFIG_STANDALONE=y |
| 485 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 594 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
| 486 | CONFIG_FW_LOADER=y | 595 | CONFIG_FW_LOADER=y |
| 596 | CONFIG_FIRMWARE_IN_KERNEL=y | ||
| 597 | CONFIG_EXTRA_FIRMWARE="" | ||
| 487 | # CONFIG_DEBUG_DRIVER is not set | 598 | # CONFIG_DEBUG_DRIVER is not set |
| 488 | 599 | # CONFIG_DEBUG_DEVRES is not set | |
| 489 | # | 600 | # CONFIG_SYS_HYPERVISOR is not set |
| 490 | # Connector - unified userspace <-> kernelspace linker | ||
| 491 | # | ||
| 492 | # CONFIG_CONNECTOR is not set | 601 | # CONFIG_CONNECTOR is not set |
| 493 | |||
| 494 | # | ||
| 495 | # Memory Technology Devices (MTD) | ||
| 496 | # | ||
| 497 | CONFIG_MTD=y | 602 | CONFIG_MTD=y |
| 498 | # CONFIG_MTD_DEBUG is not set | 603 | # CONFIG_MTD_DEBUG is not set |
| 499 | # CONFIG_MTD_CONCAT is not set | 604 | # CONFIG_MTD_CONCAT is not set |
| @@ -501,16 +606,20 @@ CONFIG_MTD_PARTITIONS=y | |||
| 501 | # CONFIG_MTD_REDBOOT_PARTS is not set | 606 | # CONFIG_MTD_REDBOOT_PARTS is not set |
| 502 | CONFIG_MTD_CMDLINE_PARTS=y | 607 | CONFIG_MTD_CMDLINE_PARTS=y |
| 503 | # CONFIG_MTD_AFS_PARTS is not set | 608 | # CONFIG_MTD_AFS_PARTS is not set |
| 609 | # CONFIG_MTD_AR7_PARTS is not set | ||
| 504 | 610 | ||
| 505 | # | 611 | # |
| 506 | # User Modules And Translation Layers | 612 | # User Modules And Translation Layers |
| 507 | # | 613 | # |
| 508 | CONFIG_MTD_CHAR=y | 614 | CONFIG_MTD_CHAR=y |
| 615 | CONFIG_MTD_BLKDEVS=y | ||
| 509 | CONFIG_MTD_BLOCK=y | 616 | CONFIG_MTD_BLOCK=y |
| 510 | # CONFIG_FTL is not set | 617 | # CONFIG_FTL is not set |
| 511 | # CONFIG_NFTL is not set | 618 | # CONFIG_NFTL is not set |
| 512 | # CONFIG_INFTL is not set | 619 | # CONFIG_INFTL is not set |
| 513 | # CONFIG_RFD_FTL is not set | 620 | # CONFIG_RFD_FTL is not set |
| 621 | # CONFIG_SSFDC is not set | ||
| 622 | # CONFIG_MTD_OOPS is not set | ||
| 514 | 623 | ||
| 515 | # | 624 | # |
| 516 | # RAM/ROM/Flash chip drivers | 625 | # RAM/ROM/Flash chip drivers |
| @@ -535,16 +644,18 @@ CONFIG_MTD_ROM=y | |||
| 535 | # Mapping drivers for chip access | 644 | # Mapping drivers for chip access |
| 536 | # | 645 | # |
| 537 | CONFIG_MTD_COMPLEX_MAPPINGS=y | 646 | CONFIG_MTD_COMPLEX_MAPPINGS=y |
| 647 | # CONFIG_MTD_PHYSMAP is not set | ||
| 538 | CONFIG_MTD_SHARP_SL=y | 648 | CONFIG_MTD_SHARP_SL=y |
| 539 | # CONFIG_MTD_PLATRAM is not set | 649 | # CONFIG_MTD_PLATRAM is not set |
| 540 | 650 | ||
| 541 | # | 651 | # |
| 542 | # Self-contained MTD device drivers | 652 | # Self-contained MTD device drivers |
| 543 | # | 653 | # |
| 654 | # CONFIG_MTD_DATAFLASH is not set | ||
| 655 | # CONFIG_MTD_M25P80 is not set | ||
| 544 | # CONFIG_MTD_SLRAM is not set | 656 | # CONFIG_MTD_SLRAM is not set |
| 545 | # CONFIG_MTD_PHRAM is not set | 657 | # CONFIG_MTD_PHRAM is not set |
| 546 | # CONFIG_MTD_MTDRAM is not set | 658 | # CONFIG_MTD_MTDRAM is not set |
| 547 | # CONFIG_MTD_BLKMTD is not set | ||
| 548 | # CONFIG_MTD_BLOCK2MTD is not set | 659 | # CONFIG_MTD_BLOCK2MTD is not set |
| 549 | 660 | ||
| 550 | # | 661 | # |
| @@ -553,78 +664,66 @@ CONFIG_MTD_SHARP_SL=y | |||
| 553 | # CONFIG_MTD_DOC2000 is not set | 664 | # CONFIG_MTD_DOC2000 is not set |
| 554 | # CONFIG_MTD_DOC2001 is not set | 665 | # CONFIG_MTD_DOC2001 is not set |
| 555 | # CONFIG_MTD_DOC2001PLUS is not set | 666 | # CONFIG_MTD_DOC2001PLUS is not set |
| 556 | |||
| 557 | # | ||
| 558 | # NAND Flash Device Drivers | ||
| 559 | # | ||
| 560 | CONFIG_MTD_NAND=y | 667 | CONFIG_MTD_NAND=y |
| 561 | CONFIG_MTD_NAND_VERIFY_WRITE=y | 668 | CONFIG_MTD_NAND_VERIFY_WRITE=y |
| 669 | # CONFIG_MTD_NAND_ECC_SMC is not set | ||
| 670 | # CONFIG_MTD_NAND_MUSEUM_IDS is not set | ||
| 562 | # CONFIG_MTD_NAND_H1900 is not set | 671 | # CONFIG_MTD_NAND_H1900 is not set |
| 563 | CONFIG_MTD_NAND_IDS=y | 672 | CONFIG_MTD_NAND_IDS=y |
| 564 | # CONFIG_MTD_NAND_DISKONCHIP is not set | 673 | # CONFIG_MTD_NAND_DISKONCHIP is not set |
| 565 | CONFIG_MTD_NAND_SHARPSL=y | 674 | CONFIG_MTD_NAND_SHARPSL=y |
| 566 | # CONFIG_MTD_NAND_NANDSIM is not set | 675 | # CONFIG_MTD_NAND_NANDSIM is not set |
| 567 | 676 | # CONFIG_MTD_NAND_PLATFORM is not set | |
| 568 | # | 677 | # CONFIG_MTD_ALAUDA is not set |
| 569 | # OneNAND Flash Device Drivers | ||
| 570 | # | ||
| 571 | # CONFIG_MTD_ONENAND is not set | 678 | # CONFIG_MTD_ONENAND is not set |
| 572 | 679 | ||
| 573 | # | 680 | # |
| 574 | # Parallel port support | 681 | # UBI - Unsorted block images |
| 575 | # | 682 | # |
| 683 | # CONFIG_MTD_UBI is not set | ||
| 576 | # CONFIG_PARPORT is not set | 684 | # CONFIG_PARPORT is not set |
| 577 | 685 | CONFIG_BLK_DEV=y | |
| 578 | # | ||
| 579 | # Plug and Play support | ||
| 580 | # | ||
| 581 | |||
| 582 | # | ||
| 583 | # Block devices | ||
| 584 | # | ||
| 585 | # CONFIG_BLK_DEV_COW_COMMON is not set | 686 | # CONFIG_BLK_DEV_COW_COMMON is not set |
| 586 | CONFIG_BLK_DEV_LOOP=y | 687 | CONFIG_BLK_DEV_LOOP=y |
| 587 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | 688 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set |
| 588 | # CONFIG_BLK_DEV_NBD is not set | 689 | # CONFIG_BLK_DEV_NBD is not set |
| 589 | # CONFIG_BLK_DEV_UB is not set | 690 | # CONFIG_BLK_DEV_UB is not set |
| 590 | # CONFIG_BLK_DEV_RAM is not set | 691 | # CONFIG_BLK_DEV_RAM is not set |
| 591 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
| 592 | # CONFIG_CDROM_PKTCDVD is not set | 692 | # CONFIG_CDROM_PKTCDVD is not set |
| 593 | # CONFIG_ATA_OVER_ETH is not set | 693 | # CONFIG_ATA_OVER_ETH is not set |
| 594 | 694 | CONFIG_MISC_DEVICES=y | |
| 595 | # | 695 | # CONFIG_EEPROM_93CX6 is not set |
| 596 | # ATA/ATAPI/MFM/RLL support | 696 | # CONFIG_ENCLOSURE_SERVICES is not set |
| 597 | # | 697 | CONFIG_HAVE_IDE=y |
| 598 | CONFIG_IDE=y | 698 | CONFIG_IDE=y |
| 599 | CONFIG_BLK_DEV_IDE=y | ||
| 600 | 699 | ||
| 601 | # | 700 | # |
| 602 | # Please see Documentation/ide.txt for help/info on IDE drives | 701 | # Please see Documentation/ide/ide.txt for help/info on IDE drives |
| 603 | # | 702 | # |
| 604 | # CONFIG_BLK_DEV_IDE_SATA is not set | 703 | # CONFIG_BLK_DEV_IDE_SATA is not set |
| 605 | CONFIG_BLK_DEV_IDEDISK=y | 704 | CONFIG_BLK_DEV_IDEDISK=y |
| 606 | # CONFIG_IDEDISK_MULTI_MODE is not set | ||
| 607 | CONFIG_BLK_DEV_IDECS=y | 705 | CONFIG_BLK_DEV_IDECS=y |
| 608 | # CONFIG_BLK_DEV_IDECD is not set | 706 | # CONFIG_BLK_DEV_IDECD is not set |
| 609 | # CONFIG_BLK_DEV_IDETAPE is not set | 707 | # CONFIG_BLK_DEV_IDETAPE is not set |
| 610 | # CONFIG_BLK_DEV_IDEFLOPPY is not set | 708 | # CONFIG_BLK_DEV_IDEFLOPPY is not set |
| 611 | # CONFIG_BLK_DEV_IDESCSI is not set | 709 | # CONFIG_BLK_DEV_IDESCSI is not set |
| 612 | # CONFIG_IDE_TASK_IOCTL is not set | 710 | # CONFIG_IDE_TASK_IOCTL is not set |
| 711 | CONFIG_IDE_PROC_FS=y | ||
| 613 | 712 | ||
| 614 | # | 713 | # |
| 615 | # IDE chipset support/bugfixes | 714 | # IDE chipset support/bugfixes |
| 616 | # | 715 | # |
| 617 | CONFIG_IDE_GENERIC=y | 716 | # CONFIG_BLK_DEV_PLATFORM is not set |
| 618 | # CONFIG_IDE_ARM is not set | ||
| 619 | # CONFIG_BLK_DEV_IDEDMA is not set | 717 | # CONFIG_BLK_DEV_IDEDMA is not set |
| 620 | # CONFIG_IDEDMA_AUTO is not set | ||
| 621 | # CONFIG_BLK_DEV_HD is not set | ||
| 622 | 718 | ||
| 623 | # | 719 | # |
| 624 | # SCSI device support | 720 | # SCSI device support |
| 625 | # | 721 | # |
| 626 | # CONFIG_RAID_ATTRS is not set | 722 | # CONFIG_RAID_ATTRS is not set |
| 627 | CONFIG_SCSI=m | 723 | CONFIG_SCSI=m |
| 724 | CONFIG_SCSI_DMA=y | ||
| 725 | # CONFIG_SCSI_TGT is not set | ||
| 726 | # CONFIG_SCSI_NETLINK is not set | ||
| 628 | CONFIG_SCSI_PROC_FS=y | 727 | CONFIG_SCSI_PROC_FS=y |
| 629 | 728 | ||
| 630 | # | 729 | # |
| @@ -644,121 +743,76 @@ CONFIG_CHR_DEV_SG=m | |||
| 644 | CONFIG_SCSI_MULTI_LUN=y | 743 | CONFIG_SCSI_MULTI_LUN=y |
| 645 | # CONFIG_SCSI_CONSTANTS is not set | 744 | # CONFIG_SCSI_CONSTANTS is not set |
| 646 | # CONFIG_SCSI_LOGGING is not set | 745 | # CONFIG_SCSI_LOGGING is not set |
| 746 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
| 747 | CONFIG_SCSI_WAIT_SCAN=m | ||
| 647 | 748 | ||
| 648 | # | 749 | # |
| 649 | # SCSI Transport Attributes | 750 | # SCSI Transports |
| 650 | # | 751 | # |
| 651 | # CONFIG_SCSI_SPI_ATTRS is not set | 752 | # CONFIG_SCSI_SPI_ATTRS is not set |
| 652 | # CONFIG_SCSI_FC_ATTRS is not set | 753 | # CONFIG_SCSI_FC_ATTRS is not set |
| 653 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 754 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
| 654 | # CONFIG_SCSI_SAS_ATTRS is not set | 755 | # CONFIG_SCSI_SAS_LIBSAS is not set |
| 655 | 756 | # CONFIG_SCSI_SRP_ATTRS is not set | |
| 656 | # | 757 | CONFIG_SCSI_LOWLEVEL=y |
| 657 | # SCSI low-level drivers | ||
| 658 | # | ||
| 659 | # CONFIG_ISCSI_TCP is not set | 758 | # CONFIG_ISCSI_TCP is not set |
| 660 | # CONFIG_SCSI_SATA is not set | ||
| 661 | # CONFIG_SCSI_DEBUG is not set | 759 | # CONFIG_SCSI_DEBUG is not set |
| 662 | 760 | # CONFIG_SCSI_LOWLEVEL_PCMCIA is not set | |
| 663 | # | 761 | # CONFIG_SCSI_DH is not set |
| 664 | # PCMCIA SCSI adapter support | 762 | # CONFIG_ATA is not set |
| 665 | # | ||
| 666 | # CONFIG_PCMCIA_AHA152X is not set | ||
| 667 | # CONFIG_PCMCIA_FDOMAIN is not set | ||
| 668 | # CONFIG_PCMCIA_NINJA_SCSI is not set | ||
| 669 | # CONFIG_PCMCIA_QLOGIC is not set | ||
| 670 | # CONFIG_PCMCIA_SYM53C500 is not set | ||
| 671 | |||
| 672 | # | ||
| 673 | # Multi-device support (RAID and LVM) | ||
| 674 | # | ||
| 675 | # CONFIG_MD is not set | 763 | # CONFIG_MD is not set |
| 676 | |||
| 677 | # | ||
| 678 | # Fusion MPT device support | ||
| 679 | # | ||
| 680 | # CONFIG_FUSION is not set | ||
| 681 | |||
| 682 | # | ||
| 683 | # IEEE 1394 (FireWire) support | ||
| 684 | # | ||
| 685 | |||
| 686 | # | ||
| 687 | # I2O device support | ||
| 688 | # | ||
| 689 | |||
| 690 | # | ||
| 691 | # Network device support | ||
| 692 | # | ||
| 693 | CONFIG_NETDEVICES=y | 764 | CONFIG_NETDEVICES=y |
| 694 | # CONFIG_DUMMY is not set | 765 | # CONFIG_DUMMY is not set |
| 695 | # CONFIG_BONDING is not set | 766 | # CONFIG_BONDING is not set |
| 767 | # CONFIG_MACVLAN is not set | ||
| 696 | # CONFIG_EQUALIZER is not set | 768 | # CONFIG_EQUALIZER is not set |
| 697 | # CONFIG_TUN is not set | 769 | # CONFIG_TUN is not set |
| 698 | 770 | # CONFIG_VETH is not set | |
| 699 | # | ||
| 700 | # PHY device support | ||
| 701 | # | ||
| 702 | # CONFIG_PHYLIB is not set | 771 | # CONFIG_PHYLIB is not set |
| 703 | |||
| 704 | # | ||
| 705 | # Ethernet (10 or 100Mbit) | ||
| 706 | # | ||
| 707 | CONFIG_NET_ETHERNET=y | 772 | CONFIG_NET_ETHERNET=y |
| 708 | CONFIG_MII=m | 773 | CONFIG_MII=m |
| 774 | # CONFIG_AX88796 is not set | ||
| 709 | # CONFIG_SMC91X is not set | 775 | # CONFIG_SMC91X is not set |
| 710 | # CONFIG_DM9000 is not set | 776 | # CONFIG_DM9000 is not set |
| 777 | # CONFIG_ENC28J60 is not set | ||
| 778 | # CONFIG_SMC911X is not set | ||
| 779 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
| 780 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
| 781 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
| 782 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
| 783 | # CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set | ||
| 784 | # CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set | ||
| 785 | # CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set | ||
| 786 | # CONFIG_B44 is not set | ||
| 787 | CONFIG_NETDEV_1000=y | ||
| 788 | CONFIG_NETDEV_10000=y | ||
| 711 | 789 | ||
| 712 | # | 790 | # |
| 713 | # Ethernet (1000 Mbit) | 791 | # Wireless LAN |
| 714 | # | ||
| 715 | |||
| 716 | # | ||
| 717 | # Ethernet (10000 Mbit) | ||
| 718 | # | ||
| 719 | |||
| 720 | # | ||
| 721 | # Token Ring devices | ||
| 722 | # | ||
| 723 | |||
| 724 | # | ||
| 725 | # Wireless LAN (non-hamradio) | ||
| 726 | # | ||
| 727 | CONFIG_NET_RADIO=y | ||
| 728 | |||
| 729 | # | ||
| 730 | # Obsolete Wireless cards support (pre-802.11) | ||
| 731 | # | ||
| 732 | # CONFIG_STRIP is not set | ||
| 733 | # CONFIG_PCMCIA_WAVELAN is not set | ||
| 734 | # CONFIG_PCMCIA_NETWAVE is not set | ||
| 735 | |||
| 736 | # | ||
| 737 | # Wireless 802.11 Frequency Hopping cards support | ||
| 738 | # | 792 | # |
| 739 | # CONFIG_PCMCIA_RAYCS is not set | 793 | # CONFIG_WLAN_PRE80211 is not set |
| 794 | # CONFIG_WLAN_80211 is not set | ||
| 795 | # CONFIG_IWLWIFI_LEDS is not set | ||
| 740 | 796 | ||
| 741 | # | 797 | # |
| 742 | # Wireless 802.11b ISA/PCI cards support | 798 | # USB Network Adapters |
| 743 | # | ||
| 744 | CONFIG_HERMES=m | ||
| 745 | # CONFIG_ATMEL is not set | ||
| 746 | |||
| 747 | # | ||
| 748 | # Wireless 802.11b Pcmcia/Cardbus cards support | ||
| 749 | # | ||
| 750 | CONFIG_PCMCIA_HERMES=m | ||
| 751 | CONFIG_PCMCIA_SPECTRUM=m | ||
| 752 | # CONFIG_AIRO_CS is not set | ||
| 753 | # CONFIG_PCMCIA_WL3501 is not set | ||
| 754 | CONFIG_HOSTAP=m | ||
| 755 | CONFIG_HOSTAP_FIRMWARE=y | ||
| 756 | CONFIG_HOSTAP_CS=m | ||
| 757 | CONFIG_NET_WIRELESS=y | ||
| 758 | |||
| 759 | # | ||
| 760 | # PCMCIA network device support | ||
| 761 | # | 799 | # |
| 800 | CONFIG_USB_CATC=m | ||
| 801 | CONFIG_USB_KAWETH=m | ||
| 802 | CONFIG_USB_PEGASUS=m | ||
| 803 | CONFIG_USB_RTL8150=m | ||
| 804 | CONFIG_USB_USBNET=m | ||
| 805 | CONFIG_USB_NET_AX8817X=m | ||
| 806 | CONFIG_USB_NET_CDCETHER=m | ||
| 807 | # CONFIG_USB_NET_DM9601 is not set | ||
| 808 | # CONFIG_USB_NET_SMSC95XX is not set | ||
| 809 | # CONFIG_USB_NET_GL620A is not set | ||
| 810 | CONFIG_USB_NET_NET1080=m | ||
| 811 | # CONFIG_USB_NET_PLUSB is not set | ||
| 812 | # CONFIG_USB_NET_MCS7830 is not set | ||
| 813 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
| 814 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
| 815 | CONFIG_USB_NET_ZAURUS=m | ||
| 762 | CONFIG_NET_PCMCIA=y | 816 | CONFIG_NET_PCMCIA=y |
| 763 | # CONFIG_PCMCIA_3C589 is not set | 817 | # CONFIG_PCMCIA_3C589 is not set |
| 764 | # CONFIG_PCMCIA_3C574 is not set | 818 | # CONFIG_PCMCIA_3C574 is not set |
| @@ -768,10 +822,6 @@ CONFIG_PCMCIA_PCNET=m | |||
| 768 | # CONFIG_PCMCIA_SMC91C92 is not set | 822 | # CONFIG_PCMCIA_SMC91C92 is not set |
| 769 | # CONFIG_PCMCIA_XIRC2PS is not set | 823 | # CONFIG_PCMCIA_XIRC2PS is not set |
| 770 | # CONFIG_PCMCIA_AXNET is not set | 824 | # CONFIG_PCMCIA_AXNET is not set |
| 771 | |||
| 772 | # | ||
| 773 | # Wan interfaces | ||
| 774 | # | ||
| 775 | # CONFIG_WAN is not set | 825 | # CONFIG_WAN is not set |
| 776 | CONFIG_PPP=m | 826 | CONFIG_PPP=m |
| 777 | # CONFIG_PPP_MULTILINK is not set | 827 | # CONFIG_PPP_MULTILINK is not set |
| @@ -782,30 +832,29 @@ CONFIG_PPP_ASYNC=m | |||
| 782 | CONFIG_PPP_BSDCOMP=m | 832 | CONFIG_PPP_BSDCOMP=m |
| 783 | # CONFIG_PPP_MPPE is not set | 833 | # CONFIG_PPP_MPPE is not set |
| 784 | # CONFIG_PPPOE is not set | 834 | # CONFIG_PPPOE is not set |
| 835 | # CONFIG_PPPOL2TP is not set | ||
| 785 | # CONFIG_SLIP is not set | 836 | # CONFIG_SLIP is not set |
| 786 | # CONFIG_SHAPER is not set | 837 | CONFIG_SLHC=m |
| 787 | # CONFIG_NETCONSOLE is not set | 838 | # CONFIG_NETCONSOLE is not set |
| 788 | # CONFIG_NETPOLL is not set | 839 | # CONFIG_NETPOLL is not set |
| 789 | # CONFIG_NET_POLL_CONTROLLER is not set | 840 | # CONFIG_NET_POLL_CONTROLLER is not set |
| 790 | |||
| 791 | # | ||
| 792 | # ISDN subsystem | ||
| 793 | # | ||
| 794 | # CONFIG_ISDN is not set | 841 | # CONFIG_ISDN is not set |
| 795 | 842 | ||
| 796 | # | 843 | # |
| 797 | # Input device support | 844 | # Input device support |
| 798 | # | 845 | # |
| 799 | CONFIG_INPUT=y | 846 | CONFIG_INPUT=y |
| 847 | CONFIG_INPUT_FF_MEMLESS=m | ||
| 848 | # CONFIG_INPUT_POLLDEV is not set | ||
| 800 | 849 | ||
| 801 | # | 850 | # |
| 802 | # Userland interfaces | 851 | # Userland interfaces |
| 803 | # | 852 | # |
| 804 | # CONFIG_INPUT_MOUSEDEV is not set | 853 | # CONFIG_INPUT_MOUSEDEV is not set |
| 805 | # CONFIG_INPUT_JOYDEV is not set | 854 | # CONFIG_INPUT_JOYDEV is not set |
| 806 | # CONFIG_INPUT_TSDEV is not set | ||
| 807 | CONFIG_INPUT_EVDEV=y | 855 | CONFIG_INPUT_EVDEV=y |
| 808 | # CONFIG_INPUT_EVBUG is not set | 856 | # CONFIG_INPUT_EVBUG is not set |
| 857 | # CONFIG_INPUT_APMPOWER is not set | ||
| 809 | 858 | ||
| 810 | # | 859 | # |
| 811 | # Input Device Drivers | 860 | # Input Device Drivers |
| @@ -814,19 +863,39 @@ CONFIG_INPUT_KEYBOARD=y | |||
| 814 | # CONFIG_KEYBOARD_ATKBD is not set | 863 | # CONFIG_KEYBOARD_ATKBD is not set |
| 815 | # CONFIG_KEYBOARD_SUNKBD is not set | 864 | # CONFIG_KEYBOARD_SUNKBD is not set |
| 816 | # CONFIG_KEYBOARD_LKKBD is not set | 865 | # CONFIG_KEYBOARD_LKKBD is not set |
| 866 | # CONFIG_KEYBOARD_LOCOMO is not set | ||
| 817 | # CONFIG_KEYBOARD_XTKBD is not set | 867 | # CONFIG_KEYBOARD_XTKBD is not set |
| 818 | # CONFIG_KEYBOARD_NEWTON is not set | 868 | # CONFIG_KEYBOARD_NEWTON is not set |
| 869 | # CONFIG_KEYBOARD_STOWAWAY is not set | ||
| 819 | CONFIG_KEYBOARD_CORGI=y | 870 | CONFIG_KEYBOARD_CORGI=y |
| 820 | CONFIG_KEYBOARD_SPITZ=y | 871 | CONFIG_KEYBOARD_SPITZ=y |
| 872 | CONFIG_KEYBOARD_TOSA=y | ||
| 873 | # CONFIG_KEYBOARD_TOSA_USE_EXT_KEYCODES is not set | ||
| 874 | # CONFIG_KEYBOARD_GPIO is not set | ||
| 821 | # CONFIG_INPUT_MOUSE is not set | 875 | # CONFIG_INPUT_MOUSE is not set |
| 822 | # CONFIG_INPUT_JOYSTICK is not set | 876 | # CONFIG_INPUT_JOYSTICK is not set |
| 877 | # CONFIG_INPUT_TABLET is not set | ||
| 823 | CONFIG_INPUT_TOUCHSCREEN=y | 878 | CONFIG_INPUT_TOUCHSCREEN=y |
| 824 | CONFIG_TOUCHSCREEN_CORGI=y | 879 | CONFIG_TOUCHSCREEN_ADS7846=y |
| 880 | # CONFIG_TOUCHSCREEN_CORGI is not set | ||
| 881 | # CONFIG_TOUCHSCREEN_FUJITSU is not set | ||
| 825 | # CONFIG_TOUCHSCREEN_GUNZE is not set | 882 | # CONFIG_TOUCHSCREEN_GUNZE is not set |
| 826 | # CONFIG_TOUCHSCREEN_ELO is not set | 883 | # CONFIG_TOUCHSCREEN_ELO is not set |
| 827 | # CONFIG_TOUCHSCREEN_MTOUCH is not set | 884 | # CONFIG_TOUCHSCREEN_MTOUCH is not set |
| 885 | # CONFIG_TOUCHSCREEN_INEXIO is not set | ||
| 828 | # CONFIG_TOUCHSCREEN_MK712 is not set | 886 | # CONFIG_TOUCHSCREEN_MK712 is not set |
| 887 | # CONFIG_TOUCHSCREEN_PENMOUNT is not set | ||
| 888 | # CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set | ||
| 889 | # CONFIG_TOUCHSCREEN_TOUCHWIN is not set | ||
| 890 | # CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set | ||
| 891 | # CONFIG_TOUCHSCREEN_TOUCHIT213 is not set | ||
| 829 | CONFIG_INPUT_MISC=y | 892 | CONFIG_INPUT_MISC=y |
| 893 | # CONFIG_INPUT_ATI_REMOTE is not set | ||
| 894 | # CONFIG_INPUT_ATI_REMOTE2 is not set | ||
| 895 | # CONFIG_INPUT_KEYSPAN_REMOTE is not set | ||
| 896 | # CONFIG_INPUT_POWERMATE is not set | ||
| 897 | # CONFIG_INPUT_YEALINK is not set | ||
| 898 | # CONFIG_INPUT_CM109 is not set | ||
| 830 | CONFIG_INPUT_UINPUT=m | 899 | CONFIG_INPUT_UINPUT=m |
| 831 | 900 | ||
| 832 | # | 901 | # |
| @@ -839,8 +908,11 @@ CONFIG_INPUT_UINPUT=m | |||
| 839 | # Character devices | 908 | # Character devices |
| 840 | # | 909 | # |
| 841 | CONFIG_VT=y | 910 | CONFIG_VT=y |
| 911 | CONFIG_CONSOLE_TRANSLATIONS=y | ||
| 842 | CONFIG_VT_CONSOLE=y | 912 | CONFIG_VT_CONSOLE=y |
| 843 | CONFIG_HW_CONSOLE=y | 913 | CONFIG_HW_CONSOLE=y |
| 914 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
| 915 | CONFIG_DEVKMEM=y | ||
| 844 | # CONFIG_SERIAL_NONSTANDARD is not set | 916 | # CONFIG_SERIAL_NONSTANDARD is not set |
| 845 | 917 | ||
| 846 | # | 918 | # |
| @@ -849,6 +921,7 @@ CONFIG_HW_CONSOLE=y | |||
| 849 | CONFIG_SERIAL_8250=m | 921 | CONFIG_SERIAL_8250=m |
| 850 | CONFIG_SERIAL_8250_CS=m | 922 | CONFIG_SERIAL_8250_CS=m |
| 851 | CONFIG_SERIAL_8250_NR_UARTS=4 | 923 | CONFIG_SERIAL_8250_NR_UARTS=4 |
| 924 | CONFIG_SERIAL_8250_RUNTIME_UARTS=4 | ||
| 852 | # CONFIG_SERIAL_8250_EXTENDED is not set | 925 | # CONFIG_SERIAL_8250_EXTENDED is not set |
| 853 | 926 | ||
| 854 | # | 927 | # |
| @@ -860,97 +933,130 @@ CONFIG_SERIAL_CORE=y | |||
| 860 | CONFIG_SERIAL_CORE_CONSOLE=y | 933 | CONFIG_SERIAL_CORE_CONSOLE=y |
| 861 | CONFIG_UNIX98_PTYS=y | 934 | CONFIG_UNIX98_PTYS=y |
| 862 | # CONFIG_LEGACY_PTYS is not set | 935 | # CONFIG_LEGACY_PTYS is not set |
| 863 | |||
| 864 | # | ||
| 865 | # IPMI | ||
| 866 | # | ||
| 867 | # CONFIG_IPMI_HANDLER is not set | 936 | # CONFIG_IPMI_HANDLER is not set |
| 868 | 937 | CONFIG_HW_RANDOM=m | |
| 869 | # | ||
| 870 | # Watchdog Cards | ||
| 871 | # | ||
| 872 | # CONFIG_WATCHDOG is not set | ||
| 873 | # CONFIG_NVRAM is not set | 938 | # CONFIG_NVRAM is not set |
| 874 | # CONFIG_RTC is not set | ||
| 875 | # CONFIG_DTLK is not set | ||
| 876 | # CONFIG_R3964 is not set | 939 | # CONFIG_R3964 is not set |
| 877 | 940 | ||
| 878 | # | 941 | # |
| 879 | # Ftape, the floppy tape device driver | ||
| 880 | # | ||
| 881 | |||
| 882 | # | ||
| 883 | # PCMCIA character devices | 942 | # PCMCIA character devices |
| 884 | # | 943 | # |
| 885 | # CONFIG_SYNCLINK_CS is not set | 944 | # CONFIG_SYNCLINK_CS is not set |
| 886 | # CONFIG_CARDMAN_4000 is not set | 945 | # CONFIG_CARDMAN_4000 is not set |
| 887 | # CONFIG_CARDMAN_4040 is not set | 946 | # CONFIG_CARDMAN_4040 is not set |
| 947 | # CONFIG_IPWIRELESS is not set | ||
| 888 | # CONFIG_RAW_DRIVER is not set | 948 | # CONFIG_RAW_DRIVER is not set |
| 889 | |||
| 890 | # | ||
| 891 | # TPM devices | ||
| 892 | # | ||
| 893 | # CONFIG_TCG_TPM is not set | 949 | # CONFIG_TCG_TPM is not set |
| 894 | # CONFIG_TELCLOCK is not set | ||
| 895 | |||
| 896 | # | ||
| 897 | # I2C support | ||
| 898 | # | ||
| 899 | CONFIG_I2C=y | 950 | CONFIG_I2C=y |
| 951 | CONFIG_I2C_BOARDINFO=y | ||
| 900 | # CONFIG_I2C_CHARDEV is not set | 952 | # CONFIG_I2C_CHARDEV is not set |
| 953 | CONFIG_I2C_HELPER_AUTO=y | ||
| 901 | 954 | ||
| 902 | # | 955 | # |
| 903 | # I2C Algorithms | 956 | # I2C Hardware Bus support |
| 904 | # | 957 | # |
| 905 | CONFIG_I2C_ALGOBIT=y | ||
| 906 | # CONFIG_I2C_ALGOPCF is not set | ||
| 907 | # CONFIG_I2C_ALGOPCA is not set | ||
| 908 | 958 | ||
| 909 | # | 959 | # |
| 910 | # I2C Hardware Bus support | 960 | # I2C system bus drivers (mostly embedded / system-on-chip) |
| 911 | # | 961 | # |
| 962 | # CONFIG_I2C_GPIO is not set | ||
| 963 | # CONFIG_I2C_OCORES is not set | ||
| 912 | CONFIG_I2C_PXA=y | 964 | CONFIG_I2C_PXA=y |
| 913 | # CONFIG_I2C_PXA_SLAVE is not set | 965 | # CONFIG_I2C_PXA_SLAVE is not set |
| 966 | # CONFIG_I2C_SIMTEC is not set | ||
| 967 | |||
| 968 | # | ||
| 969 | # External I2C/SMBus adapter drivers | ||
| 970 | # | ||
| 914 | # CONFIG_I2C_PARPORT_LIGHT is not set | 971 | # CONFIG_I2C_PARPORT_LIGHT is not set |
| 972 | # CONFIG_I2C_TAOS_EVM is not set | ||
| 973 | # CONFIG_I2C_TINY_USB is not set | ||
| 974 | |||
| 975 | # | ||
| 976 | # Other I2C/SMBus bus drivers | ||
| 977 | # | ||
| 978 | # CONFIG_I2C_PCA_PLATFORM is not set | ||
| 915 | # CONFIG_I2C_STUB is not set | 979 | # CONFIG_I2C_STUB is not set |
| 916 | # CONFIG_I2C_PCA_ISA is not set | ||
| 917 | 980 | ||
| 918 | # | 981 | # |
| 919 | # Miscellaneous I2C Chip support | 982 | # Miscellaneous I2C Chip support |
| 920 | # | 983 | # |
| 921 | # CONFIG_SENSORS_DS1337 is not set | 984 | # CONFIG_DS1682 is not set |
| 922 | # CONFIG_SENSORS_DS1374 is not set | 985 | # CONFIG_AT24 is not set |
| 923 | # CONFIG_SENSORS_EEPROM is not set | 986 | # CONFIG_SENSORS_EEPROM is not set |
| 924 | # CONFIG_SENSORS_PCF8574 is not set | 987 | # CONFIG_SENSORS_PCF8574 is not set |
| 988 | # CONFIG_PCF8575 is not set | ||
| 925 | # CONFIG_SENSORS_PCA9539 is not set | 989 | # CONFIG_SENSORS_PCA9539 is not set |
| 926 | # CONFIG_SENSORS_PCF8591 is not set | 990 | # CONFIG_SENSORS_PCF8591 is not set |
| 927 | # CONFIG_SENSORS_RTC8564 is not set | 991 | # CONFIG_TPS65010 is not set |
| 928 | # CONFIG_SENSORS_MAX6875 is not set | 992 | # CONFIG_SENSORS_MAX6875 is not set |
| 929 | # CONFIG_RTC_X1205_I2C is not set | 993 | # CONFIG_SENSORS_TSL2550 is not set |
| 930 | # CONFIG_I2C_DEBUG_CORE is not set | 994 | # CONFIG_I2C_DEBUG_CORE is not set |
| 931 | # CONFIG_I2C_DEBUG_ALGO is not set | 995 | # CONFIG_I2C_DEBUG_ALGO is not set |
| 932 | # CONFIG_I2C_DEBUG_BUS is not set | 996 | # CONFIG_I2C_DEBUG_BUS is not set |
| 933 | # CONFIG_I2C_DEBUG_CHIP is not set | 997 | # CONFIG_I2C_DEBUG_CHIP is not set |
| 998 | CONFIG_SPI=y | ||
| 999 | # CONFIG_SPI_DEBUG is not set | ||
| 1000 | CONFIG_SPI_MASTER=y | ||
| 934 | 1001 | ||
| 935 | # | 1002 | # |
| 936 | # Hardware Monitoring support | 1003 | # SPI Master Controller Drivers |
| 937 | # | 1004 | # |
| 1005 | # CONFIG_SPI_BITBANG is not set | ||
| 1006 | CONFIG_SPI_PXA2XX=y | ||
| 1007 | |||
| 1008 | # | ||
| 1009 | # SPI Protocol Masters | ||
| 1010 | # | ||
| 1011 | # CONFIG_SPI_AT25 is not set | ||
| 1012 | # CONFIG_SPI_SPIDEV is not set | ||
| 1013 | # CONFIG_SPI_TLE62X0 is not set | ||
| 1014 | CONFIG_ARCH_REQUIRE_GPIOLIB=y | ||
| 1015 | CONFIG_GPIOLIB=y | ||
| 1016 | # CONFIG_DEBUG_GPIO is not set | ||
| 1017 | # CONFIG_GPIO_SYSFS is not set | ||
| 1018 | |||
| 1019 | # | ||
| 1020 | # I2C GPIO expanders: | ||
| 1021 | # | ||
| 1022 | # CONFIG_GPIO_MAX732X is not set | ||
| 1023 | # CONFIG_GPIO_PCA953X is not set | ||
| 1024 | # CONFIG_GPIO_PCF857X is not set | ||
| 1025 | |||
| 1026 | # | ||
| 1027 | # PCI GPIO expanders: | ||
| 1028 | # | ||
| 1029 | |||
| 1030 | # | ||
| 1031 | # SPI GPIO expanders: | ||
| 1032 | # | ||
| 1033 | # CONFIG_GPIO_MAX7301 is not set | ||
| 1034 | # CONFIG_GPIO_MCP23S08 is not set | ||
| 1035 | # CONFIG_W1 is not set | ||
| 1036 | # CONFIG_POWER_SUPPLY is not set | ||
| 938 | CONFIG_HWMON=y | 1037 | CONFIG_HWMON=y |
| 939 | # CONFIG_HWMON_VID is not set | 1038 | # CONFIG_HWMON_VID is not set |
| 1039 | # CONFIG_SENSORS_AD7414 is not set | ||
| 1040 | # CONFIG_SENSORS_AD7418 is not set | ||
| 1041 | # CONFIG_SENSORS_ADCXX is not set | ||
| 940 | # CONFIG_SENSORS_ADM1021 is not set | 1042 | # CONFIG_SENSORS_ADM1021 is not set |
| 941 | # CONFIG_SENSORS_ADM1025 is not set | 1043 | # CONFIG_SENSORS_ADM1025 is not set |
| 942 | # CONFIG_SENSORS_ADM1026 is not set | 1044 | # CONFIG_SENSORS_ADM1026 is not set |
| 1045 | # CONFIG_SENSORS_ADM1029 is not set | ||
| 943 | # CONFIG_SENSORS_ADM1031 is not set | 1046 | # CONFIG_SENSORS_ADM1031 is not set |
| 944 | # CONFIG_SENSORS_ADM9240 is not set | 1047 | # CONFIG_SENSORS_ADM9240 is not set |
| 945 | # CONFIG_SENSORS_ASB100 is not set | 1048 | # CONFIG_SENSORS_ADT7470 is not set |
| 1049 | # CONFIG_SENSORS_ADT7473 is not set | ||
| 946 | # CONFIG_SENSORS_ATXP1 is not set | 1050 | # CONFIG_SENSORS_ATXP1 is not set |
| 947 | # CONFIG_SENSORS_DS1621 is not set | 1051 | # CONFIG_SENSORS_DS1621 is not set |
| 948 | # CONFIG_SENSORS_FSCHER is not set | 1052 | # CONFIG_SENSORS_F71805F is not set |
| 949 | # CONFIG_SENSORS_FSCPOS is not set | 1053 | # CONFIG_SENSORS_F71882FG is not set |
| 1054 | # CONFIG_SENSORS_F75375S is not set | ||
| 950 | # CONFIG_SENSORS_GL518SM is not set | 1055 | # CONFIG_SENSORS_GL518SM is not set |
| 951 | # CONFIG_SENSORS_GL520SM is not set | 1056 | # CONFIG_SENSORS_GL520SM is not set |
| 952 | # CONFIG_SENSORS_IT87 is not set | 1057 | # CONFIG_SENSORS_IT87 is not set |
| 953 | # CONFIG_SENSORS_LM63 is not set | 1058 | # CONFIG_SENSORS_LM63 is not set |
| 1059 | # CONFIG_SENSORS_LM70 is not set | ||
| 954 | # CONFIG_SENSORS_LM75 is not set | 1060 | # CONFIG_SENSORS_LM75 is not set |
| 955 | # CONFIG_SENSORS_LM77 is not set | 1061 | # CONFIG_SENSORS_LM77 is not set |
| 956 | # CONFIG_SENSORS_LM78 is not set | 1062 | # CONFIG_SENSORS_LM78 is not set |
| @@ -960,70 +1066,193 @@ CONFIG_HWMON=y | |||
| 960 | # CONFIG_SENSORS_LM87 is not set | 1066 | # CONFIG_SENSORS_LM87 is not set |
| 961 | # CONFIG_SENSORS_LM90 is not set | 1067 | # CONFIG_SENSORS_LM90 is not set |
| 962 | # CONFIG_SENSORS_LM92 is not set | 1068 | # CONFIG_SENSORS_LM92 is not set |
| 1069 | # CONFIG_SENSORS_LM93 is not set | ||
| 1070 | CONFIG_SENSORS_MAX1111=y | ||
| 963 | # CONFIG_SENSORS_MAX1619 is not set | 1071 | # CONFIG_SENSORS_MAX1619 is not set |
| 1072 | # CONFIG_SENSORS_MAX6650 is not set | ||
| 964 | # CONFIG_SENSORS_PC87360 is not set | 1073 | # CONFIG_SENSORS_PC87360 is not set |
| 1074 | # CONFIG_SENSORS_PC87427 is not set | ||
| 1075 | # CONFIG_SENSORS_DME1737 is not set | ||
| 965 | # CONFIG_SENSORS_SMSC47M1 is not set | 1076 | # CONFIG_SENSORS_SMSC47M1 is not set |
| 1077 | # CONFIG_SENSORS_SMSC47M192 is not set | ||
| 966 | # CONFIG_SENSORS_SMSC47B397 is not set | 1078 | # CONFIG_SENSORS_SMSC47B397 is not set |
| 1079 | # CONFIG_SENSORS_ADS7828 is not set | ||
| 1080 | # CONFIG_SENSORS_THMC50 is not set | ||
| 1081 | # CONFIG_SENSORS_VT1211 is not set | ||
| 967 | # CONFIG_SENSORS_W83781D is not set | 1082 | # CONFIG_SENSORS_W83781D is not set |
| 1083 | # CONFIG_SENSORS_W83791D is not set | ||
| 968 | # CONFIG_SENSORS_W83792D is not set | 1084 | # CONFIG_SENSORS_W83792D is not set |
| 1085 | # CONFIG_SENSORS_W83793 is not set | ||
| 969 | # CONFIG_SENSORS_W83L785TS is not set | 1086 | # CONFIG_SENSORS_W83L785TS is not set |
| 1087 | # CONFIG_SENSORS_W83L786NG is not set | ||
| 970 | # CONFIG_SENSORS_W83627HF is not set | 1088 | # CONFIG_SENSORS_W83627HF is not set |
| 971 | # CONFIG_SENSORS_W83627EHF is not set | 1089 | # CONFIG_SENSORS_W83627EHF is not set |
| 972 | # CONFIG_HWMON_DEBUG_CHIP is not set | 1090 | # CONFIG_HWMON_DEBUG_CHIP is not set |
| 1091 | # CONFIG_THERMAL is not set | ||
| 1092 | # CONFIG_THERMAL_HWMON is not set | ||
| 1093 | # CONFIG_WATCHDOG is not set | ||
| 973 | 1094 | ||
| 974 | # | 1095 | # |
| 975 | # Misc devices | 1096 | # Sonics Silicon Backplane |
| 976 | # | 1097 | # |
| 1098 | CONFIG_SSB_POSSIBLE=y | ||
| 1099 | # CONFIG_SSB is not set | ||
| 977 | 1100 | ||
| 978 | # | 1101 | # |
| 979 | # Multimedia Capabilities Port drivers | 1102 | # Multifunction device drivers |
| 980 | # | 1103 | # |
| 1104 | # CONFIG_MFD_CORE is not set | ||
| 1105 | # CONFIG_MFD_SM501 is not set | ||
| 1106 | # CONFIG_MFD_ASIC3 is not set | ||
| 1107 | # CONFIG_HTC_EGPIO is not set | ||
| 1108 | # CONFIG_HTC_PASIC3 is not set | ||
| 1109 | # CONFIG_UCB1400_CORE is not set | ||
| 1110 | # CONFIG_MFD_TMIO is not set | ||
| 1111 | # CONFIG_MFD_T7L66XB is not set | ||
| 1112 | # CONFIG_MFD_TC6387XB is not set | ||
| 1113 | # CONFIG_MFD_TC6393XB is not set | ||
| 1114 | # CONFIG_MFD_WM8400 is not set | ||
| 1115 | # CONFIG_MFD_WM8350_I2C is not set | ||
| 981 | 1116 | ||
| 982 | # | 1117 | # |
| 983 | # Multimedia devices | 1118 | # Multimedia devices |
| 984 | # | 1119 | # |
| 985 | CONFIG_VIDEO_DEV=m | ||
| 986 | |||
| 987 | # | ||
| 988 | # Video For Linux | ||
| 989 | # | ||
| 990 | 1120 | ||
| 991 | # | 1121 | # |
| 992 | # Video Adapters | 1122 | # Multimedia core support |
| 993 | # | 1123 | # |
| 1124 | CONFIG_VIDEO_DEV=m | ||
| 1125 | CONFIG_VIDEO_V4L2_COMMON=m | ||
| 1126 | CONFIG_VIDEO_ALLOW_V4L1=y | ||
| 1127 | CONFIG_VIDEO_V4L1_COMPAT=y | ||
| 1128 | # CONFIG_DVB_CORE is not set | ||
| 1129 | CONFIG_VIDEO_MEDIA=m | ||
| 1130 | |||
| 1131 | # | ||
| 1132 | # Multimedia drivers | ||
| 1133 | # | ||
| 1134 | # CONFIG_MEDIA_ATTACH is not set | ||
| 1135 | CONFIG_MEDIA_TUNER=m | ||
| 1136 | # CONFIG_MEDIA_TUNER_CUSTOMIZE is not set | ||
| 1137 | CONFIG_MEDIA_TUNER_SIMPLE=m | ||
| 1138 | CONFIG_MEDIA_TUNER_TDA8290=m | ||
| 1139 | CONFIG_MEDIA_TUNER_TDA9887=m | ||
| 1140 | CONFIG_MEDIA_TUNER_TEA5761=m | ||
| 1141 | CONFIG_MEDIA_TUNER_TEA5767=m | ||
| 1142 | CONFIG_MEDIA_TUNER_MT20XX=m | ||
| 1143 | CONFIG_MEDIA_TUNER_XC2028=m | ||
| 1144 | CONFIG_MEDIA_TUNER_XC5000=m | ||
| 1145 | CONFIG_VIDEO_V4L2=m | ||
| 1146 | CONFIG_VIDEO_V4L1=m | ||
| 1147 | CONFIG_VIDEO_CAPTURE_DRIVERS=y | ||
| 1148 | # CONFIG_VIDEO_ADV_DEBUG is not set | ||
| 1149 | # CONFIG_VIDEO_FIXED_MINOR_RANGES is not set | ||
| 1150 | CONFIG_VIDEO_HELPER_CHIPS_AUTO=y | ||
| 1151 | # CONFIG_VIDEO_VIVI is not set | ||
| 994 | # CONFIG_VIDEO_CPIA is not set | 1152 | # CONFIG_VIDEO_CPIA is not set |
| 1153 | # CONFIG_VIDEO_CPIA2 is not set | ||
| 995 | # CONFIG_VIDEO_SAA5246A is not set | 1154 | # CONFIG_VIDEO_SAA5246A is not set |
| 996 | # CONFIG_VIDEO_SAA5249 is not set | 1155 | # CONFIG_VIDEO_SAA5249 is not set |
| 997 | # CONFIG_TUNER_3036 is not set | 1156 | # CONFIG_SOC_CAMERA is not set |
| 1157 | CONFIG_V4L_USB_DRIVERS=y | ||
| 1158 | # CONFIG_USB_VIDEO_CLASS is not set | ||
| 1159 | CONFIG_USB_GSPCA=m | ||
| 1160 | # CONFIG_USB_M5602 is not set | ||
| 1161 | # CONFIG_USB_GSPCA_CONEX is not set | ||
| 1162 | # CONFIG_USB_GSPCA_ETOMS is not set | ||
| 1163 | # CONFIG_USB_GSPCA_FINEPIX is not set | ||
| 1164 | # CONFIG_USB_GSPCA_MARS is not set | ||
| 1165 | # CONFIG_USB_GSPCA_OV519 is not set | ||
| 1166 | # CONFIG_USB_GSPCA_PAC207 is not set | ||
| 1167 | # CONFIG_USB_GSPCA_PAC7311 is not set | ||
| 1168 | # CONFIG_USB_GSPCA_SONIXB is not set | ||
| 1169 | # CONFIG_USB_GSPCA_SONIXJ is not set | ||
| 1170 | # CONFIG_USB_GSPCA_SPCA500 is not set | ||
| 1171 | # CONFIG_USB_GSPCA_SPCA501 is not set | ||
| 1172 | # CONFIG_USB_GSPCA_SPCA505 is not set | ||
| 1173 | # CONFIG_USB_GSPCA_SPCA506 is not set | ||
| 1174 | # CONFIG_USB_GSPCA_SPCA508 is not set | ||
| 1175 | # CONFIG_USB_GSPCA_SPCA561 is not set | ||
| 1176 | # CONFIG_USB_GSPCA_STK014 is not set | ||
| 1177 | # CONFIG_USB_GSPCA_SUNPLUS is not set | ||
| 1178 | # CONFIG_USB_GSPCA_T613 is not set | ||
| 1179 | # CONFIG_USB_GSPCA_TV8532 is not set | ||
| 1180 | # CONFIG_USB_GSPCA_VC032X is not set | ||
| 1181 | # CONFIG_USB_GSPCA_ZC3XX is not set | ||
| 1182 | # CONFIG_VIDEO_PVRUSB2 is not set | ||
| 998 | # CONFIG_VIDEO_EM28XX is not set | 1183 | # CONFIG_VIDEO_EM28XX is not set |
| 1184 | # CONFIG_VIDEO_USBVISION is not set | ||
| 1185 | CONFIG_VIDEO_USBVIDEO=m | ||
| 1186 | CONFIG_USB_VICAM=m | ||
| 1187 | CONFIG_USB_IBMCAM=m | ||
| 1188 | CONFIG_USB_KONICAWC=m | ||
| 1189 | # CONFIG_USB_QUICKCAM_MESSENGER is not set | ||
| 1190 | # CONFIG_USB_ET61X251 is not set | ||
| 999 | # CONFIG_VIDEO_OVCAMCHIP is not set | 1191 | # CONFIG_VIDEO_OVCAMCHIP is not set |
| 1000 | # CONFIG_VIDEO_AUDIO_DECODER is not set | 1192 | CONFIG_USB_OV511=m |
| 1001 | # CONFIG_VIDEO_DECODER is not set | 1193 | CONFIG_USB_SE401=m |
| 1002 | 1194 | CONFIG_USB_SN9C102=m | |
| 1003 | # | 1195 | CONFIG_USB_STV680=m |
| 1004 | # Radio Adapters | 1196 | # CONFIG_USB_ZC0301 is not set |
| 1005 | # | 1197 | # CONFIG_USB_PWC is not set |
| 1006 | # CONFIG_RADIO_MAESTRO is not set | 1198 | # CONFIG_USB_ZR364XX is not set |
| 1007 | 1199 | # CONFIG_USB_STKWEBCAM is not set | |
| 1008 | # | 1200 | # CONFIG_USB_S2255 is not set |
| 1009 | # Digital Video Broadcasting Devices | 1201 | CONFIG_RADIO_ADAPTERS=y |
| 1010 | # | 1202 | CONFIG_USB_DSBR=m |
| 1011 | # CONFIG_DVB is not set | 1203 | # CONFIG_USB_SI470X is not set |
| 1204 | # CONFIG_USB_MR800 is not set | ||
| 1205 | # CONFIG_DAB is not set | ||
| 1012 | 1206 | ||
| 1013 | # | 1207 | # |
| 1014 | # Graphics support | 1208 | # Graphics support |
| 1015 | # | 1209 | # |
| 1210 | # CONFIG_VGASTATE is not set | ||
| 1211 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
| 1016 | CONFIG_FB=y | 1212 | CONFIG_FB=y |
| 1213 | # CONFIG_FIRMWARE_EDID is not set | ||
| 1214 | # CONFIG_FB_DDC is not set | ||
| 1215 | # CONFIG_FB_BOOT_VESA_SUPPORT is not set | ||
| 1017 | CONFIG_FB_CFB_FILLRECT=y | 1216 | CONFIG_FB_CFB_FILLRECT=y |
| 1018 | CONFIG_FB_CFB_COPYAREA=y | 1217 | CONFIG_FB_CFB_COPYAREA=y |
| 1019 | CONFIG_FB_CFB_IMAGEBLIT=y | 1218 | CONFIG_FB_CFB_IMAGEBLIT=y |
| 1219 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
| 1220 | # CONFIG_FB_SYS_FILLRECT is not set | ||
| 1221 | # CONFIG_FB_SYS_COPYAREA is not set | ||
| 1222 | # CONFIG_FB_SYS_IMAGEBLIT is not set | ||
| 1223 | # CONFIG_FB_FOREIGN_ENDIAN is not set | ||
| 1224 | # CONFIG_FB_SYS_FOPS is not set | ||
| 1225 | # CONFIG_FB_SVGALIB is not set | ||
| 1020 | # CONFIG_FB_MACMODES is not set | 1226 | # CONFIG_FB_MACMODES is not set |
| 1227 | # CONFIG_FB_BACKLIGHT is not set | ||
| 1021 | # CONFIG_FB_MODE_HELPERS is not set | 1228 | # CONFIG_FB_MODE_HELPERS is not set |
| 1022 | # CONFIG_FB_TILEBLITTING is not set | 1229 | # CONFIG_FB_TILEBLITTING is not set |
| 1230 | |||
| 1231 | # | ||
| 1232 | # Frame buffer hardware drivers | ||
| 1233 | # | ||
| 1023 | # CONFIG_FB_S1D13XXX is not set | 1234 | # CONFIG_FB_S1D13XXX is not set |
| 1024 | # CONFIG_FB_PXA is not set | 1235 | # CONFIG_FB_PXA is not set |
| 1236 | # CONFIG_FB_MBX is not set | ||
| 1025 | CONFIG_FB_W100=y | 1237 | CONFIG_FB_W100=y |
| 1026 | # CONFIG_FB_VIRTUAL is not set | 1238 | # CONFIG_FB_VIRTUAL is not set |
| 1239 | # CONFIG_FB_METRONOME is not set | ||
| 1240 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
| 1241 | CONFIG_LCD_CLASS_DEVICE=y | ||
| 1242 | CONFIG_LCD_CORGI=y | ||
| 1243 | # CONFIG_LCD_LTV350QV is not set | ||
| 1244 | # CONFIG_LCD_ILI9320 is not set | ||
| 1245 | # CONFIG_LCD_TDO24M is not set | ||
| 1246 | # CONFIG_LCD_VGG2432A4 is not set | ||
| 1247 | # CONFIG_LCD_PLATFORM is not set | ||
| 1248 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
| 1249 | # CONFIG_BACKLIGHT_CORGI is not set | ||
| 1250 | CONFIG_BACKLIGHT_LOCOMO=y | ||
| 1251 | |||
| 1252 | # | ||
| 1253 | # Display device support | ||
| 1254 | # | ||
| 1255 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 1027 | 1256 | ||
| 1028 | # | 1257 | # |
| 1029 | # Console display driver support | 1258 | # Console display driver support |
| @@ -1031,6 +1260,7 @@ CONFIG_FB_W100=y | |||
| 1031 | # CONFIG_VGA_CONSOLE is not set | 1260 | # CONFIG_VGA_CONSOLE is not set |
| 1032 | CONFIG_DUMMY_CONSOLE=y | 1261 | CONFIG_DUMMY_CONSOLE=y |
| 1033 | CONFIG_FRAMEBUFFER_CONSOLE=y | 1262 | CONFIG_FRAMEBUFFER_CONSOLE=y |
| 1263 | # CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set | ||
| 1034 | # CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set | 1264 | # CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set |
| 1035 | CONFIG_FONTS=y | 1265 | CONFIG_FONTS=y |
| 1036 | CONFIG_FONT_8x8=y | 1266 | CONFIG_FONT_8x8=y |
| @@ -1043,93 +1273,95 @@ CONFIG_FONT_8x16=y | |||
| 1043 | # CONFIG_FONT_SUN8x16 is not set | 1273 | # CONFIG_FONT_SUN8x16 is not set |
| 1044 | # CONFIG_FONT_SUN12x22 is not set | 1274 | # CONFIG_FONT_SUN12x22 is not set |
| 1045 | # CONFIG_FONT_10x18 is not set | 1275 | # CONFIG_FONT_10x18 is not set |
| 1046 | |||
| 1047 | # | ||
| 1048 | # Logo configuration | ||
| 1049 | # | ||
| 1050 | # CONFIG_LOGO is not set | 1276 | # CONFIG_LOGO is not set |
| 1051 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
| 1052 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
| 1053 | CONFIG_BACKLIGHT_DEVICE=y | ||
| 1054 | # CONFIG_LCD_CLASS_DEVICE is not set | ||
| 1055 | CONFIG_BACKLIGHT_CORGI=y | ||
| 1056 | |||
| 1057 | # | ||
| 1058 | # Sound | ||
| 1059 | # | ||
| 1060 | CONFIG_SOUND=y | 1277 | CONFIG_SOUND=y |
| 1278 | CONFIG_SOUND_OSS_CORE=y | ||
| 1279 | # CONFIG_SND is not set | ||
| 1280 | CONFIG_SOUND_PRIME=y | ||
| 1281 | CONFIG_HID_SUPPORT=y | ||
| 1282 | CONFIG_HID=y | ||
| 1283 | # CONFIG_HID_DEBUG is not set | ||
| 1284 | # CONFIG_HIDRAW is not set | ||
| 1061 | 1285 | ||
| 1062 | # | 1286 | # |
| 1063 | # Advanced Linux Sound Architecture | 1287 | # USB Input Devices |
| 1064 | # | 1288 | # |
| 1065 | # CONFIG_SND is not set | 1289 | CONFIG_USB_HID=m |
| 1290 | # CONFIG_HID_PID is not set | ||
| 1291 | # CONFIG_USB_HIDDEV is not set | ||
| 1066 | 1292 | ||
| 1067 | # | 1293 | # |
| 1068 | # Open Sound System | 1294 | # USB HID Boot Protocol drivers |
| 1069 | # | 1295 | # |
| 1070 | CONFIG_SOUND_PRIME=y | 1296 | CONFIG_USB_KBD=m |
| 1071 | # CONFIG_SOUND_MSNDCLAS is not set | 1297 | CONFIG_USB_MOUSE=m |
| 1072 | # CONFIG_SOUND_MSNDPIN is not set | 1298 | |
| 1073 | CONFIG_SOUND_OSS=y | ||
| 1074 | # CONFIG_SOUND_TRACEINIT is not set | ||
| 1075 | # CONFIG_SOUND_DMAP is not set | ||
| 1076 | # CONFIG_SOUND_AD1816 is not set | ||
| 1077 | # CONFIG_SOUND_SGALAXY is not set | ||
| 1078 | # CONFIG_SOUND_ADLIB is not set | ||
| 1079 | # CONFIG_SOUND_ACI_MIXER is not set | ||
| 1080 | # CONFIG_SOUND_CS4232 is not set | ||
| 1081 | # CONFIG_SOUND_SSCAPE is not set | ||
| 1082 | # CONFIG_SOUND_GUS is not set | ||
| 1083 | # CONFIG_SOUND_VMIDI is not set | ||
| 1084 | # CONFIG_SOUND_TRIX is not set | ||
| 1085 | # CONFIG_SOUND_MSS is not set | ||
| 1086 | # CONFIG_SOUND_MPU401 is not set | ||
| 1087 | # CONFIG_SOUND_NM256 is not set | ||
| 1088 | # CONFIG_SOUND_MAD16 is not set | ||
| 1089 | # CONFIG_SOUND_PAS is not set | ||
| 1090 | # CONFIG_SOUND_PSS is not set | ||
| 1091 | # CONFIG_SOUND_SB is not set | ||
| 1092 | # CONFIG_SOUND_AWE32_SYNTH is not set | ||
| 1093 | # CONFIG_SOUND_WAVEFRONT is not set | ||
| 1094 | # CONFIG_SOUND_MAUI is not set | ||
| 1095 | # CONFIG_SOUND_YM3812 is not set | ||
| 1096 | # CONFIG_SOUND_OPL3SA1 is not set | ||
| 1097 | # CONFIG_SOUND_OPL3SA2 is not set | ||
| 1098 | # CONFIG_SOUND_UART6850 is not set | ||
| 1099 | # CONFIG_SOUND_AEDSP16 is not set | ||
| 1100 | # CONFIG_SOUND_TVMIXER is not set | ||
| 1101 | # CONFIG_SOUND_AD1980 is not set | ||
| 1102 | |||
| 1103 | # | ||
| 1104 | # USB support | ||
| 1105 | # | 1299 | # |
| 1300 | # Special HID drivers | ||
| 1301 | # | ||
| 1302 | CONFIG_HID_COMPAT=y | ||
| 1303 | CONFIG_HID_A4TECH=m | ||
| 1304 | CONFIG_HID_APPLE=m | ||
| 1305 | CONFIG_HID_BELKIN=m | ||
| 1306 | CONFIG_HID_BRIGHT=m | ||
| 1307 | CONFIG_HID_CHERRY=m | ||
| 1308 | CONFIG_HID_CHICONY=m | ||
| 1309 | CONFIG_HID_CYPRESS=m | ||
| 1310 | CONFIG_HID_DELL=m | ||
| 1311 | CONFIG_HID_EZKEY=m | ||
| 1312 | CONFIG_HID_GYRATION=m | ||
| 1313 | CONFIG_HID_LOGITECH=m | ||
| 1314 | # CONFIG_LOGITECH_FF is not set | ||
| 1315 | # CONFIG_LOGIRUMBLEPAD2_FF is not set | ||
| 1316 | CONFIG_HID_MICROSOFT=m | ||
| 1317 | CONFIG_HID_MONTEREY=m | ||
| 1318 | CONFIG_HID_PANTHERLORD=m | ||
| 1319 | # CONFIG_PANTHERLORD_FF is not set | ||
| 1320 | CONFIG_HID_PETALYNX=m | ||
| 1321 | CONFIG_HID_SAMSUNG=m | ||
| 1322 | CONFIG_HID_SONY=m | ||
| 1323 | CONFIG_HID_SUNPLUS=m | ||
| 1324 | CONFIG_THRUSTMASTER_FF=m | ||
| 1325 | CONFIG_ZEROPLUS_FF=m | ||
| 1326 | CONFIG_USB_SUPPORT=y | ||
| 1106 | CONFIG_USB_ARCH_HAS_HCD=y | 1327 | CONFIG_USB_ARCH_HAS_HCD=y |
| 1107 | # CONFIG_USB_ARCH_HAS_OHCI is not set | 1328 | # CONFIG_USB_ARCH_HAS_OHCI is not set |
| 1329 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
| 1108 | CONFIG_USB=m | 1330 | CONFIG_USB=m |
| 1109 | # CONFIG_USB_DEBUG is not set | 1331 | # CONFIG_USB_DEBUG is not set |
| 1332 | # CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set | ||
| 1110 | 1333 | ||
| 1111 | # | 1334 | # |
| 1112 | # Miscellaneous USB options | 1335 | # Miscellaneous USB options |
| 1113 | # | 1336 | # |
| 1114 | CONFIG_USB_DEVICEFS=y | 1337 | CONFIG_USB_DEVICEFS=y |
| 1115 | # CONFIG_USB_BANDWIDTH is not set | 1338 | CONFIG_USB_DEVICE_CLASS=y |
| 1116 | # CONFIG_USB_DYNAMIC_MINORS is not set | 1339 | # CONFIG_USB_DYNAMIC_MINORS is not set |
| 1117 | # CONFIG_USB_SUSPEND is not set | 1340 | # CONFIG_USB_SUSPEND is not set |
| 1118 | # CONFIG_USB_OTG is not set | 1341 | # CONFIG_USB_OTG is not set |
| 1342 | # CONFIG_USB_OTG_WHITELIST is not set | ||
| 1343 | # CONFIG_USB_OTG_BLACKLIST_HUB is not set | ||
| 1344 | CONFIG_USB_MON=y | ||
| 1119 | 1345 | ||
| 1120 | # | 1346 | # |
| 1121 | # USB Host Controller Drivers | 1347 | # USB Host Controller Drivers |
| 1122 | # | 1348 | # |
| 1349 | # CONFIG_USB_C67X00_HCD is not set | ||
| 1123 | # CONFIG_USB_ISP116X_HCD is not set | 1350 | # CONFIG_USB_ISP116X_HCD is not set |
| 1351 | # CONFIG_USB_ISP1760_HCD is not set | ||
| 1124 | CONFIG_USB_SL811_HCD=m | 1352 | CONFIG_USB_SL811_HCD=m |
| 1125 | CONFIG_USB_SL811_CS=m | 1353 | CONFIG_USB_SL811_CS=m |
| 1354 | # CONFIG_USB_R8A66597_HCD is not set | ||
| 1355 | # CONFIG_USB_MUSB_HDRC is not set | ||
| 1356 | # CONFIG_USB_GADGET_MUSB_HDRC is not set | ||
| 1126 | 1357 | ||
| 1127 | # | 1358 | # |
| 1128 | # USB Device Class drivers | 1359 | # USB Device Class drivers |
| 1129 | # | 1360 | # |
| 1130 | # CONFIG_OBSOLETE_OSS_USB_DRIVER is not set | ||
| 1131 | CONFIG_USB_ACM=m | 1361 | CONFIG_USB_ACM=m |
| 1132 | CONFIG_USB_PRINTER=m | 1362 | CONFIG_USB_PRINTER=m |
| 1363 | # CONFIG_USB_WDM is not set | ||
| 1364 | # CONFIG_USB_TMC is not set | ||
| 1133 | 1365 | ||
| 1134 | # | 1366 | # |
| 1135 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1367 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
| @@ -1148,33 +1380,11 @@ CONFIG_USB_STORAGE=m | |||
| 1148 | # CONFIG_USB_STORAGE_SDDR09 is not set | 1380 | # CONFIG_USB_STORAGE_SDDR09 is not set |
| 1149 | # CONFIG_USB_STORAGE_SDDR55 is not set | 1381 | # CONFIG_USB_STORAGE_SDDR55 is not set |
| 1150 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | 1382 | # CONFIG_USB_STORAGE_JUMPSHOT is not set |
| 1151 | 1383 | # CONFIG_USB_STORAGE_ALAUDA is not set | |
| 1152 | # | 1384 | # CONFIG_USB_STORAGE_ONETOUCH is not set |
| 1153 | # USB Input Devices | 1385 | # CONFIG_USB_STORAGE_KARMA is not set |
| 1154 | # | 1386 | # CONFIG_USB_STORAGE_CYPRESS_ATACB is not set |
| 1155 | CONFIG_USB_HID=m | 1387 | # CONFIG_USB_LIBUSUAL is not set |
| 1156 | CONFIG_USB_HIDINPUT=y | ||
| 1157 | # CONFIG_HID_FF is not set | ||
| 1158 | # CONFIG_USB_HIDDEV is not set | ||
| 1159 | |||
| 1160 | # | ||
| 1161 | # USB HID Boot Protocol drivers | ||
| 1162 | # | ||
| 1163 | CONFIG_USB_KBD=m | ||
| 1164 | CONFIG_USB_MOUSE=m | ||
| 1165 | CONFIG_USB_AIPTEK=m | ||
| 1166 | CONFIG_USB_WACOM=m | ||
| 1167 | # CONFIG_USB_ACECAD is not set | ||
| 1168 | CONFIG_USB_KBTAB=m | ||
| 1169 | CONFIG_USB_POWERMATE=m | ||
| 1170 | CONFIG_USB_MTOUCH=m | ||
| 1171 | # CONFIG_USB_ITMTOUCH is not set | ||
| 1172 | CONFIG_USB_EGALAX=m | ||
| 1173 | # CONFIG_USB_YEALINK is not set | ||
| 1174 | CONFIG_USB_XPAD=m | ||
| 1175 | CONFIG_USB_ATI_REMOTE=m | ||
| 1176 | # CONFIG_USB_KEYSPAN_REMOTE is not set | ||
| 1177 | # CONFIG_USB_APPLETOUCH is not set | ||
| 1178 | 1388 | ||
| 1179 | # | 1389 | # |
| 1180 | # USB Imaging devices | 1390 | # USB Imaging devices |
| @@ -1183,56 +1393,22 @@ CONFIG_USB_MDC800=m | |||
| 1183 | CONFIG_USB_MICROTEK=m | 1393 | CONFIG_USB_MICROTEK=m |
| 1184 | 1394 | ||
| 1185 | # | 1395 | # |
| 1186 | # USB Multimedia devices | ||
| 1187 | # | ||
| 1188 | CONFIG_USB_DABUSB=m | ||
| 1189 | CONFIG_USB_VICAM=m | ||
| 1190 | CONFIG_USB_DSBR=m | ||
| 1191 | CONFIG_USB_IBMCAM=m | ||
| 1192 | CONFIG_USB_KONICAWC=m | ||
| 1193 | CONFIG_USB_OV511=m | ||
| 1194 | CONFIG_USB_SE401=m | ||
| 1195 | CONFIG_USB_SN9C102=m | ||
| 1196 | CONFIG_USB_STV680=m | ||
| 1197 | # CONFIG_USB_PWC is not set | ||
| 1198 | |||
| 1199 | # | ||
| 1200 | # USB Network Adapters | ||
| 1201 | # | ||
| 1202 | CONFIG_USB_CATC=m | ||
| 1203 | CONFIG_USB_KAWETH=m | ||
| 1204 | CONFIG_USB_PEGASUS=m | ||
| 1205 | CONFIG_USB_RTL8150=m | ||
| 1206 | CONFIG_USB_USBNET=m | ||
| 1207 | CONFIG_USB_NET_AX8817X=m | ||
| 1208 | CONFIG_USB_NET_CDCETHER=m | ||
| 1209 | # CONFIG_USB_NET_GL620A is not set | ||
| 1210 | CONFIG_USB_NET_NET1080=m | ||
| 1211 | # CONFIG_USB_NET_PLUSB is not set | ||
| 1212 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
| 1213 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
| 1214 | CONFIG_USB_NET_ZAURUS=m | ||
| 1215 | # CONFIG_USB_ZD1201 is not set | ||
| 1216 | CONFIG_USB_MON=y | ||
| 1217 | |||
| 1218 | # | ||
| 1219 | # USB port drivers | 1396 | # USB port drivers |
| 1220 | # | 1397 | # |
| 1221 | |||
| 1222 | # | ||
| 1223 | # USB Serial Converter support | ||
| 1224 | # | ||
| 1225 | CONFIG_USB_SERIAL=m | 1398 | CONFIG_USB_SERIAL=m |
| 1399 | CONFIG_USB_EZUSB=y | ||
| 1226 | CONFIG_USB_SERIAL_GENERIC=y | 1400 | CONFIG_USB_SERIAL_GENERIC=y |
| 1227 | # CONFIG_USB_SERIAL_AIRPRIME is not set | 1401 | # CONFIG_USB_SERIAL_AIRCABLE is not set |
| 1228 | # CONFIG_USB_SERIAL_ANYDATA is not set | 1402 | # CONFIG_USB_SERIAL_ARK3116 is not set |
| 1229 | CONFIG_USB_SERIAL_BELKIN=m | 1403 | CONFIG_USB_SERIAL_BELKIN=m |
| 1404 | # CONFIG_USB_SERIAL_CH341 is not set | ||
| 1230 | # CONFIG_USB_SERIAL_WHITEHEAT is not set | 1405 | # CONFIG_USB_SERIAL_WHITEHEAT is not set |
| 1231 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m | 1406 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m |
| 1232 | # CONFIG_USB_SERIAL_CP2101 is not set | 1407 | # CONFIG_USB_SERIAL_CP2101 is not set |
| 1233 | CONFIG_USB_SERIAL_CYPRESS_M8=m | 1408 | CONFIG_USB_SERIAL_CYPRESS_M8=m |
| 1234 | CONFIG_USB_SERIAL_EMPEG=m | 1409 | CONFIG_USB_SERIAL_EMPEG=m |
| 1235 | CONFIG_USB_SERIAL_FTDI_SIO=m | 1410 | CONFIG_USB_SERIAL_FTDI_SIO=m |
| 1411 | # CONFIG_USB_SERIAL_FUNSOFT is not set | ||
| 1236 | CONFIG_USB_SERIAL_VISOR=m | 1412 | CONFIG_USB_SERIAL_VISOR=m |
| 1237 | CONFIG_USB_SERIAL_IPAQ=m | 1413 | CONFIG_USB_SERIAL_IPAQ=m |
| 1238 | CONFIG_USB_SERIAL_IR=m | 1414 | CONFIG_USB_SERIAL_IR=m |
| @@ -1240,6 +1416,7 @@ CONFIG_USB_SERIAL_EDGEPORT=m | |||
| 1240 | CONFIG_USB_SERIAL_EDGEPORT_TI=m | 1416 | CONFIG_USB_SERIAL_EDGEPORT_TI=m |
| 1241 | CONFIG_USB_SERIAL_GARMIN=m | 1417 | CONFIG_USB_SERIAL_GARMIN=m |
| 1242 | CONFIG_USB_SERIAL_IPW=m | 1418 | CONFIG_USB_SERIAL_IPW=m |
| 1419 | # CONFIG_USB_SERIAL_IUU is not set | ||
| 1243 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m | 1420 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m |
| 1244 | CONFIG_USB_SERIAL_KEYSPAN=m | 1421 | CONFIG_USB_SERIAL_KEYSPAN=m |
| 1245 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set | 1422 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set |
| @@ -1257,50 +1434,68 @@ CONFIG_USB_SERIAL_KEYSPAN=m | |||
| 1257 | CONFIG_USB_SERIAL_KLSI=m | 1434 | CONFIG_USB_SERIAL_KLSI=m |
| 1258 | CONFIG_USB_SERIAL_KOBIL_SCT=m | 1435 | CONFIG_USB_SERIAL_KOBIL_SCT=m |
| 1259 | CONFIG_USB_SERIAL_MCT_U232=m | 1436 | CONFIG_USB_SERIAL_MCT_U232=m |
| 1437 | # CONFIG_USB_SERIAL_MOS7720 is not set | ||
| 1438 | # CONFIG_USB_SERIAL_MOS7840 is not set | ||
| 1439 | # CONFIG_USB_SERIAL_MOTOROLA is not set | ||
| 1440 | # CONFIG_USB_SERIAL_NAVMAN is not set | ||
| 1260 | CONFIG_USB_SERIAL_PL2303=m | 1441 | CONFIG_USB_SERIAL_PL2303=m |
| 1442 | # CONFIG_USB_SERIAL_OTI6858 is not set | ||
| 1443 | # CONFIG_USB_SERIAL_SPCP8X5 is not set | ||
| 1261 | # CONFIG_USB_SERIAL_HP4X is not set | 1444 | # CONFIG_USB_SERIAL_HP4X is not set |
| 1262 | CONFIG_USB_SERIAL_SAFE=m | 1445 | CONFIG_USB_SERIAL_SAFE=m |
| 1263 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set | 1446 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set |
| 1447 | # CONFIG_USB_SERIAL_SIERRAWIRELESS is not set | ||
| 1264 | CONFIG_USB_SERIAL_TI=m | 1448 | CONFIG_USB_SERIAL_TI=m |
| 1265 | CONFIG_USB_SERIAL_CYBERJACK=m | 1449 | CONFIG_USB_SERIAL_CYBERJACK=m |
| 1266 | CONFIG_USB_SERIAL_XIRCOM=m | 1450 | CONFIG_USB_SERIAL_XIRCOM=m |
| 1451 | # CONFIG_USB_SERIAL_OPTION is not set | ||
| 1267 | CONFIG_USB_SERIAL_OMNINET=m | 1452 | CONFIG_USB_SERIAL_OMNINET=m |
| 1268 | CONFIG_USB_EZUSB=y | 1453 | # CONFIG_USB_SERIAL_DEBUG is not set |
| 1269 | 1454 | ||
| 1270 | # | 1455 | # |
| 1271 | # USB Miscellaneous drivers | 1456 | # USB Miscellaneous drivers |
| 1272 | # | 1457 | # |
| 1273 | CONFIG_USB_EMI62=m | 1458 | CONFIG_USB_EMI62=m |
| 1274 | CONFIG_USB_EMI26=m | 1459 | CONFIG_USB_EMI26=m |
| 1275 | CONFIG_USB_AUERSWALD=m | 1460 | # CONFIG_USB_ADUTUX is not set |
| 1461 | # CONFIG_USB_SEVSEG is not set | ||
| 1276 | CONFIG_USB_RIO500=m | 1462 | CONFIG_USB_RIO500=m |
| 1277 | CONFIG_USB_LEGOTOWER=m | 1463 | CONFIG_USB_LEGOTOWER=m |
| 1278 | CONFIG_USB_LCD=m | 1464 | CONFIG_USB_LCD=m |
| 1465 | # CONFIG_USB_BERRY_CHARGE is not set | ||
| 1279 | CONFIG_USB_LED=m | 1466 | CONFIG_USB_LED=m |
| 1467 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
| 1280 | CONFIG_USB_CYTHERM=m | 1468 | CONFIG_USB_CYTHERM=m |
| 1281 | CONFIG_USB_PHIDGETKIT=m | 1469 | # CONFIG_USB_PHIDGET is not set |
| 1282 | CONFIG_USB_PHIDGETSERVO=m | ||
| 1283 | CONFIG_USB_IDMOUSE=m | 1470 | CONFIG_USB_IDMOUSE=m |
| 1471 | # CONFIG_USB_FTDI_ELAN is not set | ||
| 1472 | # CONFIG_USB_APPLEDISPLAY is not set | ||
| 1284 | # CONFIG_USB_LD is not set | 1473 | # CONFIG_USB_LD is not set |
| 1474 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
| 1475 | # CONFIG_USB_IOWARRIOR is not set | ||
| 1285 | # CONFIG_USB_TEST is not set | 1476 | # CONFIG_USB_TEST is not set |
| 1286 | 1477 | # CONFIG_USB_ISIGHTFW is not set | |
| 1287 | # | 1478 | # CONFIG_USB_VST is not set |
| 1288 | # USB DSL modem support | ||
| 1289 | # | ||
| 1290 | |||
| 1291 | # | ||
| 1292 | # USB Gadget Support | ||
| 1293 | # | ||
| 1294 | CONFIG_USB_GADGET=y | 1479 | CONFIG_USB_GADGET=y |
| 1480 | # CONFIG_USB_GADGET_DEBUG is not set | ||
| 1295 | # CONFIG_USB_GADGET_DEBUG_FILES is not set | 1481 | # CONFIG_USB_GADGET_DEBUG_FILES is not set |
| 1482 | CONFIG_USB_GADGET_VBUS_DRAW=2 | ||
| 1296 | CONFIG_USB_GADGET_SELECTED=y | 1483 | CONFIG_USB_GADGET_SELECTED=y |
| 1297 | # CONFIG_USB_GADGET_NET2280 is not set | 1484 | # CONFIG_USB_GADGET_AT91 is not set |
| 1298 | CONFIG_USB_GADGET_PXA2XX=y | 1485 | # CONFIG_USB_GADGET_ATMEL_USBA is not set |
| 1299 | CONFIG_USB_PXA2XX=y | 1486 | # CONFIG_USB_GADGET_FSL_USB2 is not set |
| 1300 | # CONFIG_USB_PXA2XX_SMALL is not set | ||
| 1301 | # CONFIG_USB_GADGET_GOKU is not set | ||
| 1302 | # CONFIG_USB_GADGET_LH7A40X is not set | 1487 | # CONFIG_USB_GADGET_LH7A40X is not set |
| 1303 | # CONFIG_USB_GADGET_OMAP is not set | 1488 | # CONFIG_USB_GADGET_OMAP is not set |
| 1489 | CONFIG_USB_GADGET_PXA25X=y | ||
| 1490 | CONFIG_USB_PXA25X=y | ||
| 1491 | # CONFIG_USB_PXA25X_SMALL is not set | ||
| 1492 | # CONFIG_USB_GADGET_PXA27X is not set | ||
| 1493 | # CONFIG_USB_GADGET_S3C2410 is not set | ||
| 1494 | # CONFIG_USB_GADGET_M66592 is not set | ||
| 1495 | # CONFIG_USB_GADGET_AMD5536UDC is not set | ||
| 1496 | # CONFIG_USB_GADGET_FSL_QE is not set | ||
| 1497 | # CONFIG_USB_GADGET_NET2280 is not set | ||
| 1498 | # CONFIG_USB_GADGET_GOKU is not set | ||
| 1304 | # CONFIG_USB_GADGET_DUMMY_HCD is not set | 1499 | # CONFIG_USB_GADGET_DUMMY_HCD is not set |
| 1305 | # CONFIG_USB_GADGET_DUALSPEED is not set | 1500 | # CONFIG_USB_GADGET_DUALSPEED is not set |
| 1306 | CONFIG_USB_ZERO=m | 1501 | CONFIG_USB_ZERO=m |
| @@ -1310,15 +1505,42 @@ CONFIG_USB_GADGETFS=m | |||
| 1310 | CONFIG_USB_FILE_STORAGE=m | 1505 | CONFIG_USB_FILE_STORAGE=m |
| 1311 | # CONFIG_USB_FILE_STORAGE_TEST is not set | 1506 | # CONFIG_USB_FILE_STORAGE_TEST is not set |
| 1312 | CONFIG_USB_G_SERIAL=m | 1507 | CONFIG_USB_G_SERIAL=m |
| 1508 | # CONFIG_USB_MIDI_GADGET is not set | ||
| 1509 | # CONFIG_USB_G_PRINTER is not set | ||
| 1510 | # CONFIG_USB_CDC_COMPOSITE is not set | ||
| 1511 | CONFIG_MMC=y | ||
| 1512 | # CONFIG_MMC_DEBUG is not set | ||
| 1513 | # CONFIG_MMC_UNSAFE_RESUME is not set | ||
| 1313 | 1514 | ||
| 1314 | # | 1515 | # |
| 1315 | # MMC/SD Card support | 1516 | # MMC/SD/SDIO Card Drivers |
| 1316 | # | 1517 | # |
| 1317 | CONFIG_MMC=y | ||
| 1318 | # CONFIG_MMC_DEBUG is not set | ||
| 1319 | CONFIG_MMC_BLOCK=y | 1518 | CONFIG_MMC_BLOCK=y |
| 1519 | CONFIG_MMC_BLOCK_BOUNCE=y | ||
| 1520 | # CONFIG_SDIO_UART is not set | ||
| 1521 | # CONFIG_MMC_TEST is not set | ||
| 1522 | |||
| 1523 | # | ||
| 1524 | # MMC/SD/SDIO Host Controller Drivers | ||
| 1525 | # | ||
| 1320 | CONFIG_MMC_PXA=y | 1526 | CONFIG_MMC_PXA=y |
| 1321 | # CONFIG_MMC_WBSD is not set | 1527 | # CONFIG_MMC_SDHCI is not set |
| 1528 | # CONFIG_MMC_SPI is not set | ||
| 1529 | # CONFIG_MEMSTICK is not set | ||
| 1530 | # CONFIG_ACCESSIBILITY is not set | ||
| 1531 | # CONFIG_NEW_LEDS is not set | ||
| 1532 | CONFIG_RTC_LIB=y | ||
| 1533 | # CONFIG_RTC_CLASS is not set | ||
| 1534 | # CONFIG_DMADEVICES is not set | ||
| 1535 | |||
| 1536 | # | ||
| 1537 | # Voltage and Current regulators | ||
| 1538 | # | ||
| 1539 | # CONFIG_REGULATOR is not set | ||
| 1540 | # CONFIG_REGULATOR_FIXED_VOLTAGE is not set | ||
| 1541 | # CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set | ||
| 1542 | # CONFIG_REGULATOR_BQ24022 is not set | ||
| 1543 | # CONFIG_UIO is not set | ||
| 1322 | 1544 | ||
| 1323 | # | 1545 | # |
| 1324 | # File systems | 1546 | # File systems |
| @@ -1327,16 +1549,17 @@ CONFIG_EXT2_FS=y | |||
| 1327 | # CONFIG_EXT2_FS_XATTR is not set | 1549 | # CONFIG_EXT2_FS_XATTR is not set |
| 1328 | # CONFIG_EXT2_FS_XIP is not set | 1550 | # CONFIG_EXT2_FS_XIP is not set |
| 1329 | # CONFIG_EXT3_FS is not set | 1551 | # CONFIG_EXT3_FS is not set |
| 1330 | # CONFIG_JBD is not set | 1552 | # CONFIG_EXT4_FS is not set |
| 1331 | # CONFIG_REISERFS_FS is not set | 1553 | # CONFIG_REISERFS_FS is not set |
| 1332 | # CONFIG_JFS_FS is not set | 1554 | # CONFIG_JFS_FS is not set |
| 1333 | # CONFIG_FS_POSIX_ACL is not set | 1555 | # CONFIG_FS_POSIX_ACL is not set |
| 1556 | CONFIG_FILE_LOCKING=y | ||
| 1334 | # CONFIG_XFS_FS is not set | 1557 | # CONFIG_XFS_FS is not set |
| 1335 | # CONFIG_MINIX_FS is not set | 1558 | # CONFIG_OCFS2_FS is not set |
| 1336 | # CONFIG_ROMFS_FS is not set | 1559 | CONFIG_DNOTIFY=y |
| 1337 | CONFIG_INOTIFY=y | 1560 | CONFIG_INOTIFY=y |
| 1561 | CONFIG_INOTIFY_USER=y | ||
| 1338 | # CONFIG_QUOTA is not set | 1562 | # CONFIG_QUOTA is not set |
| 1339 | CONFIG_DNOTIFY=y | ||
| 1340 | # CONFIG_AUTOFS_FS is not set | 1563 | # CONFIG_AUTOFS_FS is not set |
| 1341 | # CONFIG_AUTOFS4_FS is not set | 1564 | # CONFIG_AUTOFS4_FS is not set |
| 1342 | # CONFIG_FUSE_FS is not set | 1565 | # CONFIG_FUSE_FS is not set |
| @@ -1361,11 +1584,13 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | |||
| 1361 | # Pseudo filesystems | 1584 | # Pseudo filesystems |
| 1362 | # | 1585 | # |
| 1363 | CONFIG_PROC_FS=y | 1586 | CONFIG_PROC_FS=y |
| 1587 | CONFIG_PROC_SYSCTL=y | ||
| 1588 | CONFIG_PROC_PAGE_MONITOR=y | ||
| 1364 | CONFIG_SYSFS=y | 1589 | CONFIG_SYSFS=y |
| 1365 | CONFIG_TMPFS=y | 1590 | CONFIG_TMPFS=y |
| 1591 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
| 1366 | # CONFIG_HUGETLB_PAGE is not set | 1592 | # CONFIG_HUGETLB_PAGE is not set |
| 1367 | CONFIG_RAMFS=y | 1593 | # CONFIG_CONFIGFS_FS is not set |
| 1368 | # CONFIG_RELAYFS_FS is not set | ||
| 1369 | 1594 | ||
| 1370 | # | 1595 | # |
| 1371 | # Miscellaneous filesystems | 1596 | # Miscellaneous filesystems |
| @@ -1377,39 +1602,42 @@ CONFIG_RAMFS=y | |||
| 1377 | # CONFIG_BEFS_FS is not set | 1602 | # CONFIG_BEFS_FS is not set |
| 1378 | # CONFIG_BFS_FS is not set | 1603 | # CONFIG_BFS_FS is not set |
| 1379 | # CONFIG_EFS_FS is not set | 1604 | # CONFIG_EFS_FS is not set |
| 1380 | # CONFIG_JFFS_FS is not set | ||
| 1381 | CONFIG_JFFS2_FS=y | 1605 | CONFIG_JFFS2_FS=y |
| 1382 | CONFIG_JFFS2_FS_DEBUG=0 | 1606 | CONFIG_JFFS2_FS_DEBUG=0 |
| 1383 | CONFIG_JFFS2_FS_WRITEBUFFER=y | 1607 | CONFIG_JFFS2_FS_WRITEBUFFER=y |
| 1608 | # CONFIG_JFFS2_FS_WBUF_VERIFY is not set | ||
| 1384 | CONFIG_JFFS2_SUMMARY=y | 1609 | CONFIG_JFFS2_SUMMARY=y |
| 1610 | # CONFIG_JFFS2_FS_XATTR is not set | ||
| 1385 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y | 1611 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y |
| 1386 | CONFIG_JFFS2_ZLIB=y | 1612 | CONFIG_JFFS2_ZLIB=y |
| 1613 | # CONFIG_JFFS2_LZO is not set | ||
| 1387 | CONFIG_JFFS2_RTIME=y | 1614 | CONFIG_JFFS2_RTIME=y |
| 1388 | CONFIG_JFFS2_RUBIN=y | 1615 | CONFIG_JFFS2_RUBIN=y |
| 1389 | # CONFIG_JFFS2_CMODE_NONE is not set | 1616 | # CONFIG_JFFS2_CMODE_NONE is not set |
| 1390 | CONFIG_JFFS2_CMODE_PRIORITY=y | 1617 | CONFIG_JFFS2_CMODE_PRIORITY=y |
| 1391 | # CONFIG_JFFS2_CMODE_SIZE is not set | 1618 | # CONFIG_JFFS2_CMODE_SIZE is not set |
| 1619 | # CONFIG_JFFS2_CMODE_FAVOURLZO is not set | ||
| 1392 | CONFIG_CRAMFS=m | 1620 | CONFIG_CRAMFS=m |
| 1393 | # CONFIG_VXFS_FS is not set | 1621 | # CONFIG_VXFS_FS is not set |
| 1622 | # CONFIG_MINIX_FS is not set | ||
| 1623 | # CONFIG_OMFS_FS is not set | ||
| 1394 | # CONFIG_HPFS_FS is not set | 1624 | # CONFIG_HPFS_FS is not set |
| 1395 | # CONFIG_QNX4FS_FS is not set | 1625 | # CONFIG_QNX4FS_FS is not set |
| 1626 | # CONFIG_ROMFS_FS is not set | ||
| 1396 | # CONFIG_SYSV_FS is not set | 1627 | # CONFIG_SYSV_FS is not set |
| 1397 | # CONFIG_UFS_FS is not set | 1628 | # CONFIG_UFS_FS is not set |
| 1398 | 1629 | CONFIG_NETWORK_FILESYSTEMS=y | |
| 1399 | # | ||
| 1400 | # Network File Systems | ||
| 1401 | # | ||
| 1402 | CONFIG_NFS_FS=m | 1630 | CONFIG_NFS_FS=m |
| 1403 | CONFIG_NFS_V3=y | 1631 | CONFIG_NFS_V3=y |
| 1404 | # CONFIG_NFS_V3_ACL is not set | 1632 | # CONFIG_NFS_V3_ACL is not set |
| 1405 | CONFIG_NFS_V4=y | 1633 | CONFIG_NFS_V4=y |
| 1406 | # CONFIG_NFS_DIRECTIO is not set | ||
| 1407 | # CONFIG_NFSD is not set | 1634 | # CONFIG_NFSD is not set |
| 1408 | CONFIG_LOCKD=m | 1635 | CONFIG_LOCKD=m |
| 1409 | CONFIG_LOCKD_V4=y | 1636 | CONFIG_LOCKD_V4=y |
| 1410 | CONFIG_NFS_COMMON=y | 1637 | CONFIG_NFS_COMMON=y |
| 1411 | CONFIG_SUNRPC=m | 1638 | CONFIG_SUNRPC=m |
| 1412 | CONFIG_SUNRPC_GSS=m | 1639 | CONFIG_SUNRPC_GSS=m |
| 1640 | # CONFIG_SUNRPC_REGISTER_V4 is not set | ||
| 1413 | CONFIG_RPCSEC_GSS_KRB5=m | 1641 | CONFIG_RPCSEC_GSS_KRB5=m |
| 1414 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1642 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
| 1415 | CONFIG_SMB_FS=m | 1643 | CONFIG_SMB_FS=m |
| @@ -1419,7 +1647,6 @@ CONFIG_SMB_NLS_REMOTE="cp437" | |||
| 1419 | # CONFIG_NCP_FS is not set | 1647 | # CONFIG_NCP_FS is not set |
| 1420 | # CONFIG_CODA_FS is not set | 1648 | # CONFIG_CODA_FS is not set |
| 1421 | # CONFIG_AFS_FS is not set | 1649 | # CONFIG_AFS_FS is not set |
| 1422 | # CONFIG_9P_FS is not set | ||
| 1423 | 1650 | ||
| 1424 | # | 1651 | # |
| 1425 | # Partition Types | 1652 | # Partition Types |
| @@ -1439,11 +1666,9 @@ CONFIG_MSDOS_PARTITION=y | |||
| 1439 | # CONFIG_SGI_PARTITION is not set | 1666 | # CONFIG_SGI_PARTITION is not set |
| 1440 | # CONFIG_ULTRIX_PARTITION is not set | 1667 | # CONFIG_ULTRIX_PARTITION is not set |
| 1441 | # CONFIG_SUN_PARTITION is not set | 1668 | # CONFIG_SUN_PARTITION is not set |
| 1669 | # CONFIG_KARMA_PARTITION is not set | ||
| 1442 | # CONFIG_EFI_PARTITION is not set | 1670 | # CONFIG_EFI_PARTITION is not set |
| 1443 | 1671 | # CONFIG_SYSV68_PARTITION is not set | |
| 1444 | # | ||
| 1445 | # Native Language Support | ||
| 1446 | # | ||
| 1447 | CONFIG_NLS=y | 1672 | CONFIG_NLS=y |
| 1448 | CONFIG_NLS_DEFAULT="cp437" | 1673 | CONFIG_NLS_DEFAULT="cp437" |
| 1449 | CONFIG_NLS_CODEPAGE_437=y | 1674 | CONFIG_NLS_CODEPAGE_437=y |
| @@ -1484,35 +1709,71 @@ CONFIG_NLS_ISO8859_1=y | |||
| 1484 | # CONFIG_NLS_KOI8_R is not set | 1709 | # CONFIG_NLS_KOI8_R is not set |
| 1485 | # CONFIG_NLS_KOI8_U is not set | 1710 | # CONFIG_NLS_KOI8_U is not set |
| 1486 | CONFIG_NLS_UTF8=y | 1711 | CONFIG_NLS_UTF8=y |
| 1487 | 1712 | # CONFIG_DLM is not set | |
| 1488 | # | ||
| 1489 | # Profiling support | ||
| 1490 | # | ||
| 1491 | CONFIG_PROFILING=y | ||
| 1492 | CONFIG_OPROFILE=m | ||
| 1493 | 1713 | ||
| 1494 | # | 1714 | # |
| 1495 | # Kernel hacking | 1715 | # Kernel hacking |
| 1496 | # | 1716 | # |
| 1497 | # CONFIG_PRINTK_TIME is not set | 1717 | # CONFIG_PRINTK_TIME is not set |
| 1498 | CONFIG_DEBUG_KERNEL=y | 1718 | CONFIG_ENABLE_WARN_DEPRECATED=y |
| 1719 | CONFIG_ENABLE_MUST_CHECK=y | ||
| 1720 | CONFIG_FRAME_WARN=1024 | ||
| 1499 | CONFIG_MAGIC_SYSRQ=y | 1721 | CONFIG_MAGIC_SYSRQ=y |
| 1500 | CONFIG_LOG_BUF_SHIFT=14 | 1722 | # CONFIG_UNUSED_SYMBOLS is not set |
| 1723 | # CONFIG_DEBUG_FS is not set | ||
| 1724 | # CONFIG_HEADERS_CHECK is not set | ||
| 1725 | CONFIG_DEBUG_KERNEL=y | ||
| 1726 | # CONFIG_DEBUG_SHIRQ is not set | ||
| 1501 | CONFIG_DETECT_SOFTLOCKUP=y | 1727 | CONFIG_DETECT_SOFTLOCKUP=y |
| 1728 | # CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set | ||
| 1729 | CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 | ||
| 1730 | CONFIG_SCHED_DEBUG=y | ||
| 1502 | # CONFIG_SCHEDSTATS is not set | 1731 | # CONFIG_SCHEDSTATS is not set |
| 1503 | # CONFIG_DEBUG_SLAB is not set | 1732 | # CONFIG_TIMER_STATS is not set |
| 1733 | # CONFIG_DEBUG_OBJECTS is not set | ||
| 1734 | # CONFIG_SLUB_DEBUG_ON is not set | ||
| 1735 | # CONFIG_SLUB_STATS is not set | ||
| 1504 | # CONFIG_DEBUG_PREEMPT is not set | 1736 | # CONFIG_DEBUG_PREEMPT is not set |
| 1737 | # CONFIG_DEBUG_RT_MUTEXES is not set | ||
| 1738 | # CONFIG_RT_MUTEX_TESTER is not set | ||
| 1505 | # CONFIG_DEBUG_SPINLOCK is not set | 1739 | # CONFIG_DEBUG_SPINLOCK is not set |
| 1740 | # CONFIG_DEBUG_MUTEXES is not set | ||
| 1741 | # CONFIG_DEBUG_LOCK_ALLOC is not set | ||
| 1742 | # CONFIG_PROVE_LOCKING is not set | ||
| 1743 | # CONFIG_LOCK_STAT is not set | ||
| 1506 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1744 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
| 1745 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | ||
| 1507 | # CONFIG_DEBUG_KOBJECT is not set | 1746 | # CONFIG_DEBUG_KOBJECT is not set |
| 1508 | CONFIG_DEBUG_BUGVERBOSE=y | 1747 | CONFIG_DEBUG_BUGVERBOSE=y |
| 1509 | # CONFIG_DEBUG_INFO is not set | 1748 | # CONFIG_DEBUG_INFO is not set |
| 1510 | # CONFIG_DEBUG_FS is not set | ||
| 1511 | # CONFIG_DEBUG_VM is not set | 1749 | # CONFIG_DEBUG_VM is not set |
| 1750 | # CONFIG_DEBUG_WRITECOUNT is not set | ||
| 1751 | # CONFIG_DEBUG_MEMORY_INIT is not set | ||
| 1752 | # CONFIG_DEBUG_LIST is not set | ||
| 1753 | # CONFIG_DEBUG_SG is not set | ||
| 1512 | CONFIG_FRAME_POINTER=y | 1754 | CONFIG_FRAME_POINTER=y |
| 1755 | # CONFIG_BOOT_PRINTK_DELAY is not set | ||
| 1513 | # CONFIG_RCU_TORTURE_TEST is not set | 1756 | # CONFIG_RCU_TORTURE_TEST is not set |
| 1757 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | ||
| 1758 | # CONFIG_BACKTRACE_SELF_TEST is not set | ||
| 1759 | # CONFIG_DEBUG_BLOCK_EXT_DEVT is not set | ||
| 1760 | # CONFIG_FAULT_INJECTION is not set | ||
| 1761 | # CONFIG_LATENCYTOP is not set | ||
| 1762 | # CONFIG_SYSCTL_SYSCALL_CHECK is not set | ||
| 1763 | CONFIG_HAVE_FTRACE=y | ||
| 1764 | CONFIG_HAVE_DYNAMIC_FTRACE=y | ||
| 1765 | # CONFIG_FTRACE is not set | ||
| 1766 | # CONFIG_IRQSOFF_TRACER is not set | ||
| 1767 | # CONFIG_PREEMPT_TRACER is not set | ||
| 1768 | # CONFIG_SCHED_TRACER is not set | ||
| 1769 | # CONFIG_CONTEXT_SWITCH_TRACER is not set | ||
| 1770 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set | ||
| 1771 | # CONFIG_SAMPLES is not set | ||
| 1772 | CONFIG_HAVE_ARCH_KGDB=y | ||
| 1773 | # CONFIG_KGDB is not set | ||
| 1514 | # CONFIG_DEBUG_USER is not set | 1774 | # CONFIG_DEBUG_USER is not set |
| 1515 | CONFIG_DEBUG_ERRORS=y | 1775 | CONFIG_DEBUG_ERRORS=y |
| 1776 | # CONFIG_DEBUG_STACK_USAGE is not set | ||
| 1516 | CONFIG_DEBUG_LL=y | 1777 | CONFIG_DEBUG_LL=y |
| 1517 | # CONFIG_DEBUG_ICEDCC is not set | 1778 | # CONFIG_DEBUG_ICEDCC is not set |
| 1518 | 1779 | ||
| @@ -1521,46 +1782,113 @@ CONFIG_DEBUG_LL=y | |||
| 1521 | # | 1782 | # |
| 1522 | # CONFIG_KEYS is not set | 1783 | # CONFIG_KEYS is not set |
| 1523 | # CONFIG_SECURITY is not set | 1784 | # CONFIG_SECURITY is not set |
| 1785 | # CONFIG_SECURITYFS is not set | ||
| 1786 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
| 1787 | CONFIG_CRYPTO=y | ||
| 1524 | 1788 | ||
| 1525 | # | 1789 | # |
| 1526 | # Cryptographic options | 1790 | # Crypto core or helper |
| 1527 | # | 1791 | # |
| 1528 | CONFIG_CRYPTO=y | 1792 | # CONFIG_CRYPTO_FIPS is not set |
| 1529 | CONFIG_CRYPTO_HMAC=y | 1793 | CONFIG_CRYPTO_ALGAPI=y |
| 1794 | CONFIG_CRYPTO_AEAD=y | ||
| 1795 | CONFIG_CRYPTO_BLKCIPHER=y | ||
| 1796 | CONFIG_CRYPTO_HASH=y | ||
| 1797 | CONFIG_CRYPTO_RNG=y | ||
| 1798 | CONFIG_CRYPTO_MANAGER=y | ||
| 1799 | # CONFIG_CRYPTO_GF128MUL is not set | ||
| 1530 | CONFIG_CRYPTO_NULL=m | 1800 | CONFIG_CRYPTO_NULL=m |
| 1801 | # CONFIG_CRYPTO_CRYPTD is not set | ||
| 1802 | CONFIG_CRYPTO_AUTHENC=m | ||
| 1803 | CONFIG_CRYPTO_TEST=m | ||
| 1804 | |||
| 1805 | # | ||
| 1806 | # Authenticated Encryption with Associated Data | ||
| 1807 | # | ||
| 1808 | # CONFIG_CRYPTO_CCM is not set | ||
| 1809 | # CONFIG_CRYPTO_GCM is not set | ||
| 1810 | # CONFIG_CRYPTO_SEQIV is not set | ||
| 1811 | |||
| 1812 | # | ||
| 1813 | # Block modes | ||
| 1814 | # | ||
| 1815 | CONFIG_CRYPTO_CBC=m | ||
| 1816 | # CONFIG_CRYPTO_CTR is not set | ||
| 1817 | # CONFIG_CRYPTO_CTS is not set | ||
| 1818 | CONFIG_CRYPTO_ECB=m | ||
| 1819 | # CONFIG_CRYPTO_LRW is not set | ||
| 1820 | # CONFIG_CRYPTO_PCBC is not set | ||
| 1821 | # CONFIG_CRYPTO_XTS is not set | ||
| 1822 | |||
| 1823 | # | ||
| 1824 | # Hash modes | ||
| 1825 | # | ||
| 1826 | CONFIG_CRYPTO_HMAC=y | ||
| 1827 | # CONFIG_CRYPTO_XCBC is not set | ||
| 1828 | |||
| 1829 | # | ||
| 1830 | # Digest | ||
| 1831 | # | ||
| 1832 | CONFIG_CRYPTO_CRC32C=m | ||
| 1531 | CONFIG_CRYPTO_MD4=m | 1833 | CONFIG_CRYPTO_MD4=m |
| 1532 | CONFIG_CRYPTO_MD5=m | 1834 | CONFIG_CRYPTO_MD5=m |
| 1835 | CONFIG_CRYPTO_MICHAEL_MIC=m | ||
| 1836 | # CONFIG_CRYPTO_RMD128 is not set | ||
| 1837 | # CONFIG_CRYPTO_RMD160 is not set | ||
| 1838 | # CONFIG_CRYPTO_RMD256 is not set | ||
| 1839 | # CONFIG_CRYPTO_RMD320 is not set | ||
| 1533 | CONFIG_CRYPTO_SHA1=m | 1840 | CONFIG_CRYPTO_SHA1=m |
| 1534 | CONFIG_CRYPTO_SHA256=m | 1841 | CONFIG_CRYPTO_SHA256=m |
| 1535 | CONFIG_CRYPTO_SHA512=m | 1842 | CONFIG_CRYPTO_SHA512=m |
| 1536 | CONFIG_CRYPTO_WP512=m | ||
| 1537 | # CONFIG_CRYPTO_TGR192 is not set | 1843 | # CONFIG_CRYPTO_TGR192 is not set |
| 1538 | CONFIG_CRYPTO_DES=m | 1844 | CONFIG_CRYPTO_WP512=m |
| 1539 | CONFIG_CRYPTO_BLOWFISH=m | 1845 | |
| 1540 | CONFIG_CRYPTO_TWOFISH=m | 1846 | # |
| 1541 | CONFIG_CRYPTO_SERPENT=m | 1847 | # Ciphers |
| 1848 | # | ||
| 1542 | CONFIG_CRYPTO_AES=m | 1849 | CONFIG_CRYPTO_AES=m |
| 1850 | CONFIG_CRYPTO_ANUBIS=m | ||
| 1851 | CONFIG_CRYPTO_ARC4=m | ||
| 1852 | CONFIG_CRYPTO_BLOWFISH=m | ||
| 1853 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
| 1543 | CONFIG_CRYPTO_CAST5=m | 1854 | CONFIG_CRYPTO_CAST5=m |
| 1544 | CONFIG_CRYPTO_CAST6=m | 1855 | CONFIG_CRYPTO_CAST6=m |
| 1545 | CONFIG_CRYPTO_TEA=m | 1856 | CONFIG_CRYPTO_DES=m |
| 1546 | CONFIG_CRYPTO_ARC4=m | 1857 | # CONFIG_CRYPTO_FCRYPT is not set |
| 1547 | CONFIG_CRYPTO_KHAZAD=m | 1858 | CONFIG_CRYPTO_KHAZAD=m |
| 1548 | CONFIG_CRYPTO_ANUBIS=m | 1859 | # CONFIG_CRYPTO_SALSA20 is not set |
| 1860 | # CONFIG_CRYPTO_SEED is not set | ||
| 1861 | CONFIG_CRYPTO_SERPENT=m | ||
| 1862 | CONFIG_CRYPTO_TEA=m | ||
| 1863 | CONFIG_CRYPTO_TWOFISH=m | ||
| 1864 | CONFIG_CRYPTO_TWOFISH_COMMON=m | ||
| 1865 | |||
| 1866 | # | ||
| 1867 | # Compression | ||
| 1868 | # | ||
| 1549 | CONFIG_CRYPTO_DEFLATE=m | 1869 | CONFIG_CRYPTO_DEFLATE=m |
| 1550 | CONFIG_CRYPTO_MICHAEL_MIC=m | 1870 | # CONFIG_CRYPTO_LZO is not set |
| 1551 | CONFIG_CRYPTO_CRC32C=m | ||
| 1552 | CONFIG_CRYPTO_TEST=m | ||
| 1553 | 1871 | ||
| 1554 | # | 1872 | # |
| 1555 | # Hardware crypto devices | 1873 | # Random Number Generation |
| 1556 | # | 1874 | # |
| 1875 | # CONFIG_CRYPTO_ANSI_CPRNG is not set | ||
| 1876 | CONFIG_CRYPTO_HW=y | ||
| 1557 | 1877 | ||
| 1558 | # | 1878 | # |
| 1559 | # Library routines | 1879 | # Library routines |
| 1560 | # | 1880 | # |
| 1881 | CONFIG_BITREVERSE=y | ||
| 1561 | CONFIG_CRC_CCITT=y | 1882 | CONFIG_CRC_CCITT=y |
| 1562 | # CONFIG_CRC16 is not set | 1883 | # CONFIG_CRC16 is not set |
| 1884 | # CONFIG_CRC_T10DIF is not set | ||
| 1885 | # CONFIG_CRC_ITU_T is not set | ||
| 1563 | CONFIG_CRC32=y | 1886 | CONFIG_CRC32=y |
| 1887 | # CONFIG_CRC7 is not set | ||
| 1564 | CONFIG_LIBCRC32C=m | 1888 | CONFIG_LIBCRC32C=m |
| 1565 | CONFIG_ZLIB_INFLATE=y | 1889 | CONFIG_ZLIB_INFLATE=y |
| 1566 | CONFIG_ZLIB_DEFLATE=y | 1890 | CONFIG_ZLIB_DEFLATE=y |
| 1891 | CONFIG_PLIST=y | ||
| 1892 | CONFIG_HAS_IOMEM=y | ||
| 1893 | CONFIG_HAS_IOPORT=y | ||
| 1894 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/arm/configs/msm_defconfig b/arch/arm/configs/msm_defconfig index ae4c5e62086a..3b4ecf2a90dd 100644 --- a/arch/arm/configs/msm_defconfig +++ b/arch/arm/configs/msm_defconfig | |||
| @@ -133,7 +133,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" | |||
| 133 | # CONFIG_ARCH_LH7A40X is not set | 133 | # CONFIG_ARCH_LH7A40X is not set |
| 134 | # CONFIG_ARCH_DAVINCI is not set | 134 | # CONFIG_ARCH_DAVINCI is not set |
| 135 | # CONFIG_ARCH_OMAP is not set | 135 | # CONFIG_ARCH_OMAP is not set |
| 136 | CONFIG_ARCH_MSM7X00A=y | 136 | CONFIG_ARCH_MSM=y |
| 137 | 137 | ||
| 138 | # | 138 | # |
| 139 | # Boot options | 139 | # Boot options |
diff --git a/arch/arm/configs/spitz_defconfig b/arch/arm/configs/spitz_defconfig index 7d59fb1f1cea..4df5b4db2aa0 100644 --- a/arch/arm/configs/spitz_defconfig +++ b/arch/arm/configs/spitz_defconfig | |||
| @@ -1,71 +1,111 @@ | |||
| 1 | # | 1 | # |
| 2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
| 3 | # Linux kernel version: 2.6.15-rc2 | 3 | # Linux kernel version: 2.6.27 |
| 4 | # Mon Nov 28 10:26:52 2005 | 4 | # Mon Oct 20 10:25:37 2008 |
| 5 | # | 5 | # |
| 6 | CONFIG_ARM=y | 6 | CONFIG_ARM=y |
| 7 | CONFIG_SYS_SUPPORTS_APM_EMULATION=y | ||
| 8 | CONFIG_GENERIC_GPIO=y | ||
| 9 | CONFIG_GENERIC_TIME=y | ||
| 10 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
| 7 | CONFIG_MMU=y | 11 | CONFIG_MMU=y |
| 8 | CONFIG_UID16=y | 12 | # CONFIG_NO_IOPORT is not set |
| 13 | CONFIG_GENERIC_HARDIRQS=y | ||
| 14 | CONFIG_STACKTRACE_SUPPORT=y | ||
| 15 | CONFIG_HAVE_LATENCYTOP_SUPPORT=y | ||
| 16 | CONFIG_LOCKDEP_SUPPORT=y | ||
| 17 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
| 18 | CONFIG_HARDIRQS_SW_RESEND=y | ||
| 19 | CONFIG_GENERIC_IRQ_PROBE=y | ||
| 9 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 20 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
| 21 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
| 22 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
| 23 | CONFIG_GENERIC_HWEIGHT=y | ||
| 10 | CONFIG_GENERIC_CALIBRATE_DELAY=y | 24 | CONFIG_GENERIC_CALIBRATE_DELAY=y |
| 25 | CONFIG_ARCH_MTD_XIP=y | ||
| 26 | CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y | ||
| 27 | CONFIG_VECTORS_BASE=0xffff0000 | ||
| 28 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
| 11 | 29 | ||
| 12 | # | 30 | # |
| 13 | # Code maturity level options | 31 | # General setup |
| 14 | # | 32 | # |
| 15 | CONFIG_EXPERIMENTAL=y | 33 | CONFIG_EXPERIMENTAL=y |
| 16 | CONFIG_CLEAN_COMPILE=y | ||
| 17 | CONFIG_BROKEN_ON_SMP=y | 34 | CONFIG_BROKEN_ON_SMP=y |
| 18 | CONFIG_LOCK_KERNEL=y | 35 | CONFIG_LOCK_KERNEL=y |
| 19 | CONFIG_INIT_ENV_ARG_LIMIT=32 | 36 | CONFIG_INIT_ENV_ARG_LIMIT=32 |
| 20 | |||
| 21 | # | ||
| 22 | # General setup | ||
| 23 | # | ||
| 24 | CONFIG_LOCALVERSION="" | 37 | CONFIG_LOCALVERSION="" |
| 25 | CONFIG_LOCALVERSION_AUTO=y | 38 | CONFIG_LOCALVERSION_AUTO=y |
| 26 | CONFIG_SWAP=y | 39 | CONFIG_SWAP=y |
| 27 | CONFIG_SYSVIPC=y | 40 | CONFIG_SYSVIPC=y |
| 41 | CONFIG_SYSVIPC_SYSCTL=y | ||
| 28 | # CONFIG_POSIX_MQUEUE is not set | 42 | # CONFIG_POSIX_MQUEUE is not set |
| 29 | CONFIG_BSD_PROCESS_ACCT=y | 43 | CONFIG_BSD_PROCESS_ACCT=y |
| 30 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set | 44 | # CONFIG_BSD_PROCESS_ACCT_V3 is not set |
| 31 | CONFIG_SYSCTL=y | 45 | # CONFIG_TASKSTATS is not set |
| 32 | # CONFIG_AUDIT is not set | 46 | # CONFIG_AUDIT is not set |
| 33 | CONFIG_HOTPLUG=y | ||
| 34 | CONFIG_KOBJECT_UEVENT=y | ||
| 35 | # CONFIG_IKCONFIG is not set | 47 | # CONFIG_IKCONFIG is not set |
| 36 | CONFIG_INITRAMFS_SOURCE="" | 48 | CONFIG_LOG_BUF_SHIFT=14 |
| 49 | # CONFIG_CGROUPS is not set | ||
| 50 | # CONFIG_GROUP_SCHED is not set | ||
| 51 | CONFIG_SYSFS_DEPRECATED=y | ||
| 52 | CONFIG_SYSFS_DEPRECATED_V2=y | ||
| 53 | # CONFIG_RELAY is not set | ||
| 54 | # CONFIG_NAMESPACES is not set | ||
| 55 | # CONFIG_BLK_DEV_INITRD is not set | ||
| 56 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | ||
| 57 | CONFIG_SYSCTL=y | ||
| 37 | CONFIG_EMBEDDED=y | 58 | CONFIG_EMBEDDED=y |
| 59 | CONFIG_UID16=y | ||
| 60 | CONFIG_SYSCTL_SYSCALL=y | ||
| 38 | CONFIG_KALLSYMS=y | 61 | CONFIG_KALLSYMS=y |
| 39 | # CONFIG_KALLSYMS_ALL is not set | 62 | # CONFIG_KALLSYMS_ALL is not set |
| 40 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | 63 | # CONFIG_KALLSYMS_EXTRA_PASS is not set |
| 64 | CONFIG_HOTPLUG=y | ||
| 41 | CONFIG_PRINTK=y | 65 | CONFIG_PRINTK=y |
| 42 | CONFIG_BUG=y | 66 | CONFIG_BUG=y |
| 67 | CONFIG_ELF_CORE=y | ||
| 68 | CONFIG_COMPAT_BRK=y | ||
| 43 | CONFIG_BASE_FULL=y | 69 | CONFIG_BASE_FULL=y |
| 44 | CONFIG_FUTEX=y | 70 | CONFIG_FUTEX=y |
| 71 | CONFIG_ANON_INODES=y | ||
| 45 | CONFIG_EPOLL=y | 72 | CONFIG_EPOLL=y |
| 46 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | 73 | CONFIG_SIGNALFD=y |
| 74 | CONFIG_TIMERFD=y | ||
| 75 | CONFIG_EVENTFD=y | ||
| 47 | CONFIG_SHMEM=y | 76 | CONFIG_SHMEM=y |
| 48 | CONFIG_CC_ALIGN_FUNCTIONS=0 | 77 | CONFIG_AIO=y |
| 49 | CONFIG_CC_ALIGN_LABELS=0 | 78 | CONFIG_VM_EVENT_COUNTERS=y |
| 50 | CONFIG_CC_ALIGN_LOOPS=0 | 79 | CONFIG_SLUB_DEBUG=y |
| 51 | CONFIG_CC_ALIGN_JUMPS=0 | 80 | # CONFIG_SLAB is not set |
| 81 | CONFIG_SLUB=y | ||
| 82 | # CONFIG_SLOB is not set | ||
| 83 | CONFIG_PROFILING=y | ||
| 84 | # CONFIG_MARKERS is not set | ||
| 85 | CONFIG_OPROFILE=m | ||
| 86 | CONFIG_HAVE_OPROFILE=y | ||
| 87 | # CONFIG_KPROBES is not set | ||
| 88 | CONFIG_HAVE_KPROBES=y | ||
| 89 | CONFIG_HAVE_KRETPROBES=y | ||
| 90 | CONFIG_HAVE_CLK=y | ||
| 91 | CONFIG_HAVE_GENERIC_DMA_COHERENT=y | ||
| 92 | CONFIG_SLABINFO=y | ||
| 93 | CONFIG_RT_MUTEXES=y | ||
| 52 | # CONFIG_TINY_SHMEM is not set | 94 | # CONFIG_TINY_SHMEM is not set |
| 53 | CONFIG_BASE_SMALL=0 | 95 | CONFIG_BASE_SMALL=0 |
| 54 | |||
| 55 | # | ||
| 56 | # Loadable module support | ||
| 57 | # | ||
| 58 | CONFIG_MODULES=y | 96 | CONFIG_MODULES=y |
| 97 | # CONFIG_MODULE_FORCE_LOAD is not set | ||
| 59 | CONFIG_MODULE_UNLOAD=y | 98 | CONFIG_MODULE_UNLOAD=y |
| 60 | CONFIG_MODULE_FORCE_UNLOAD=y | 99 | CONFIG_MODULE_FORCE_UNLOAD=y |
| 61 | CONFIG_OBSOLETE_MODPARM=y | ||
| 62 | # CONFIG_MODVERSIONS is not set | 100 | # CONFIG_MODVERSIONS is not set |
| 63 | # CONFIG_MODULE_SRCVERSION_ALL is not set | 101 | # CONFIG_MODULE_SRCVERSION_ALL is not set |
| 64 | CONFIG_KMOD=y | 102 | CONFIG_KMOD=y |
| 65 | 103 | CONFIG_BLOCK=y | |
| 66 | # | 104 | # CONFIG_LBD is not set |
| 67 | # Block layer | 105 | # CONFIG_BLK_DEV_IO_TRACE is not set |
| 68 | # | 106 | # CONFIG_LSF is not set |
| 107 | # CONFIG_BLK_DEV_BSG is not set | ||
| 108 | # CONFIG_BLK_DEV_INTEGRITY is not set | ||
| 69 | 109 | ||
| 70 | # | 110 | # |
| 71 | # IO Schedulers | 111 | # IO Schedulers |
| @@ -79,49 +119,95 @@ CONFIG_DEFAULT_AS=y | |||
| 79 | # CONFIG_DEFAULT_CFQ is not set | 119 | # CONFIG_DEFAULT_CFQ is not set |
| 80 | # CONFIG_DEFAULT_NOOP is not set | 120 | # CONFIG_DEFAULT_NOOP is not set |
| 81 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 121 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
| 122 | CONFIG_CLASSIC_RCU=y | ||
| 82 | 123 | ||
| 83 | # | 124 | # |
| 84 | # System Type | 125 | # System Type |
| 85 | # | 126 | # |
| 127 | # CONFIG_ARCH_AAEC2000 is not set | ||
| 128 | # CONFIG_ARCH_INTEGRATOR is not set | ||
| 129 | # CONFIG_ARCH_REALVIEW is not set | ||
| 130 | # CONFIG_ARCH_VERSATILE is not set | ||
| 131 | # CONFIG_ARCH_AT91 is not set | ||
| 86 | # CONFIG_ARCH_CLPS7500 is not set | 132 | # CONFIG_ARCH_CLPS7500 is not set |
| 87 | # CONFIG_ARCH_CLPS711X is not set | 133 | # CONFIG_ARCH_CLPS711X is not set |
| 88 | # CONFIG_ARCH_CO285 is not set | ||
| 89 | # CONFIG_ARCH_EBSA110 is not set | 134 | # CONFIG_ARCH_EBSA110 is not set |
| 135 | # CONFIG_ARCH_EP93XX is not set | ||
| 90 | # CONFIG_ARCH_FOOTBRIDGE is not set | 136 | # CONFIG_ARCH_FOOTBRIDGE is not set |
| 91 | # CONFIG_ARCH_INTEGRATOR is not set | 137 | # CONFIG_ARCH_NETX is not set |
| 92 | # CONFIG_ARCH_IOP3XX is not set | 138 | # CONFIG_ARCH_H720X is not set |
| 93 | # CONFIG_ARCH_IXP4XX is not set | 139 | # CONFIG_ARCH_IMX is not set |
| 140 | # CONFIG_ARCH_IOP13XX is not set | ||
| 141 | # CONFIG_ARCH_IOP32X is not set | ||
| 142 | # CONFIG_ARCH_IOP33X is not set | ||
| 143 | # CONFIG_ARCH_IXP23XX is not set | ||
| 94 | # CONFIG_ARCH_IXP2000 is not set | 144 | # CONFIG_ARCH_IXP2000 is not set |
| 145 | # CONFIG_ARCH_IXP4XX is not set | ||
| 95 | # CONFIG_ARCH_L7200 is not set | 146 | # CONFIG_ARCH_L7200 is not set |
| 147 | # CONFIG_ARCH_KIRKWOOD is not set | ||
| 148 | # CONFIG_ARCH_KS8695 is not set | ||
| 149 | # CONFIG_ARCH_NS9XXX is not set | ||
| 150 | # CONFIG_ARCH_LOKI is not set | ||
| 151 | # CONFIG_ARCH_MV78XX0 is not set | ||
| 152 | # CONFIG_ARCH_MXC is not set | ||
| 153 | # CONFIG_ARCH_ORION5X is not set | ||
| 154 | # CONFIG_ARCH_PNX4008 is not set | ||
| 96 | CONFIG_ARCH_PXA=y | 155 | CONFIG_ARCH_PXA=y |
| 97 | # CONFIG_ARCH_RPC is not set | 156 | # CONFIG_ARCH_RPC is not set |
| 98 | # CONFIG_ARCH_SA1100 is not set | 157 | # CONFIG_ARCH_SA1100 is not set |
| 99 | # CONFIG_ARCH_S3C2410 is not set | 158 | # CONFIG_ARCH_S3C2410 is not set |
| 100 | # CONFIG_ARCH_SHARK is not set | 159 | # CONFIG_ARCH_SHARK is not set |
| 101 | # CONFIG_ARCH_LH7A40X is not set | 160 | # CONFIG_ARCH_LH7A40X is not set |
| 161 | # CONFIG_ARCH_DAVINCI is not set | ||
| 102 | # CONFIG_ARCH_OMAP is not set | 162 | # CONFIG_ARCH_OMAP is not set |
| 103 | # CONFIG_ARCH_VERSATILE is not set | 163 | # CONFIG_ARCH_MSM7X00A is not set |
| 104 | # CONFIG_ARCH_REALVIEW is not set | ||
| 105 | # CONFIG_ARCH_IMX is not set | ||
| 106 | # CONFIG_ARCH_H720X is not set | ||
| 107 | # CONFIG_ARCH_AAEC2000 is not set | ||
| 108 | 164 | ||
| 109 | # | 165 | # |
| 110 | # Intel PXA2xx Implementations | 166 | # Intel PXA2xx/PXA3xx Implementations |
| 111 | # | 167 | # |
| 168 | # CONFIG_ARCH_GUMSTIX is not set | ||
| 112 | # CONFIG_ARCH_LUBBOCK is not set | 169 | # CONFIG_ARCH_LUBBOCK is not set |
| 170 | # CONFIG_MACH_LOGICPD_PXA270 is not set | ||
| 113 | # CONFIG_MACH_MAINSTONE is not set | 171 | # CONFIG_MACH_MAINSTONE is not set |
| 172 | # CONFIG_MACH_MP900C is not set | ||
| 114 | # CONFIG_ARCH_PXA_IDP is not set | 173 | # CONFIG_ARCH_PXA_IDP is not set |
| 115 | CONFIG_PXA_SHARPSL=y | 174 | CONFIG_PXA_SHARPSL=y |
| 116 | # CONFIG_PXA_SHARPSL_25x is not set | 175 | # CONFIG_MACH_POODLE is not set |
| 117 | CONFIG_PXA_SHARPSL_27x=y | 176 | # CONFIG_MACH_CORGI is not set |
| 177 | # CONFIG_MACH_SHEPHERD is not set | ||
| 178 | # CONFIG_MACH_HUSKY is not set | ||
| 118 | CONFIG_MACH_AKITA=y | 179 | CONFIG_MACH_AKITA=y |
| 119 | CONFIG_MACH_SPITZ=y | 180 | CONFIG_MACH_SPITZ=y |
| 120 | CONFIG_MACH_BORZOI=y | 181 | CONFIG_MACH_BORZOI=y |
| 182 | # CONFIG_MACH_TOSA is not set | ||
| 183 | # CONFIG_ARCH_VIPER is not set | ||
| 184 | # CONFIG_ARCH_PXA_ESERIES is not set | ||
| 185 | # CONFIG_TRIZEPS_PXA is not set | ||
| 186 | # CONFIG_MACH_EM_X270 is not set | ||
| 187 | # CONFIG_MACH_COLIBRI is not set | ||
| 188 | # CONFIG_MACH_ZYLONITE is not set | ||
| 189 | # CONFIG_MACH_LITTLETON is not set | ||
| 190 | # CONFIG_MACH_TAVOREVB is not set | ||
| 191 | # CONFIG_MACH_SAAR is not set | ||
| 192 | # CONFIG_MACH_ARMCORE is not set | ||
| 193 | # CONFIG_MACH_CM_X300 is not set | ||
| 194 | # CONFIG_MACH_MAGICIAN is not set | ||
| 195 | # CONFIG_MACH_MIOA701 is not set | ||
| 196 | # CONFIG_MACH_PCM027 is not set | ||
| 197 | # CONFIG_ARCH_PXA_PALM is not set | ||
| 198 | # CONFIG_PXA_EZX is not set | ||
| 121 | CONFIG_PXA27x=y | 199 | CONFIG_PXA27x=y |
| 122 | CONFIG_IWMMXT=y | ||
| 123 | CONFIG_PXA_SHARP_Cxx00=y | 200 | CONFIG_PXA_SHARP_Cxx00=y |
| 124 | CONFIG_PXA_SSP=y | 201 | CONFIG_PXA_SSP=y |
| 202 | # CONFIG_PXA_PWM is not set | ||
| 203 | |||
| 204 | # | ||
| 205 | # Boot options | ||
| 206 | # | ||
| 207 | |||
| 208 | # | ||
| 209 | # Power management | ||
| 210 | # | ||
| 125 | 211 | ||
| 126 | # | 212 | # |
| 127 | # Processor Type | 213 | # Processor Type |
| @@ -130,25 +216,29 @@ CONFIG_CPU_32=y | |||
| 130 | CONFIG_CPU_XSCALE=y | 216 | CONFIG_CPU_XSCALE=y |
| 131 | CONFIG_CPU_32v5=y | 217 | CONFIG_CPU_32v5=y |
| 132 | CONFIG_CPU_ABRT_EV5T=y | 218 | CONFIG_CPU_ABRT_EV5T=y |
| 219 | CONFIG_CPU_PABRT_NOIFAR=y | ||
| 133 | CONFIG_CPU_CACHE_VIVT=y | 220 | CONFIG_CPU_CACHE_VIVT=y |
| 134 | CONFIG_CPU_TLB_V4WBI=y | 221 | CONFIG_CPU_TLB_V4WBI=y |
| 222 | CONFIG_CPU_CP15=y | ||
| 223 | CONFIG_CPU_CP15_MMU=y | ||
| 135 | 224 | ||
| 136 | # | 225 | # |
| 137 | # Processor Features | 226 | # Processor Features |
| 138 | # | 227 | # |
| 139 | CONFIG_ARM_THUMB=y | 228 | CONFIG_ARM_THUMB=y |
| 229 | # CONFIG_CPU_DCACHE_DISABLE is not set | ||
| 230 | # CONFIG_OUTER_CACHE is not set | ||
| 231 | CONFIG_IWMMXT=y | ||
| 140 | CONFIG_XSCALE_PMU=y | 232 | CONFIG_XSCALE_PMU=y |
| 141 | CONFIG_SHARP_PARAM=y | 233 | CONFIG_SHARP_PARAM=y |
| 234 | CONFIG_SHARPSL_PM=y | ||
| 142 | CONFIG_SHARP_SCOOP=y | 235 | CONFIG_SHARP_SCOOP=y |
| 143 | 236 | ||
| 144 | # | 237 | # |
| 145 | # Bus support | 238 | # Bus support |
| 146 | # | 239 | # |
| 147 | CONFIG_ISA_DMA_API=y | 240 | # CONFIG_PCI_SYSCALL is not set |
| 148 | 241 | # CONFIG_ARCH_SUPPORTS_MSI is not set | |
| 149 | # | ||
| 150 | # PCCARD (PCMCIA/CardBus) support | ||
| 151 | # | ||
| 152 | CONFIG_PCCARD=y | 242 | CONFIG_PCCARD=y |
| 153 | # CONFIG_PCMCIA_DEBUG is not set | 243 | # CONFIG_PCMCIA_DEBUG is not set |
| 154 | CONFIG_PCMCIA=y | 244 | CONFIG_PCMCIA=y |
| @@ -163,16 +253,32 @@ CONFIG_PCMCIA_PXA2XX=y | |||
| 163 | # | 253 | # |
| 164 | # Kernel Features | 254 | # Kernel Features |
| 165 | # | 255 | # |
| 256 | CONFIG_TICK_ONESHOT=y | ||
| 257 | # CONFIG_NO_HZ is not set | ||
| 258 | # CONFIG_HIGH_RES_TIMERS is not set | ||
| 259 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
| 260 | CONFIG_VMSPLIT_3G=y | ||
| 261 | # CONFIG_VMSPLIT_2G is not set | ||
| 262 | # CONFIG_VMSPLIT_1G is not set | ||
| 263 | CONFIG_PAGE_OFFSET=0xC0000000 | ||
| 166 | CONFIG_PREEMPT=y | 264 | CONFIG_PREEMPT=y |
| 167 | # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set | 265 | CONFIG_HZ=100 |
| 266 | # CONFIG_AEABI is not set | ||
| 267 | CONFIG_ARCH_FLATMEM_HAS_HOLES=y | ||
| 268 | # CONFIG_ARCH_SPARSEMEM_DEFAULT is not set | ||
| 269 | # CONFIG_ARCH_SELECT_MEMORY_MODEL is not set | ||
| 168 | CONFIG_SELECT_MEMORY_MODEL=y | 270 | CONFIG_SELECT_MEMORY_MODEL=y |
| 169 | CONFIG_FLATMEM_MANUAL=y | 271 | CONFIG_FLATMEM_MANUAL=y |
| 170 | # CONFIG_DISCONTIGMEM_MANUAL is not set | 272 | # CONFIG_DISCONTIGMEM_MANUAL is not set |
| 171 | # CONFIG_SPARSEMEM_MANUAL is not set | 273 | # CONFIG_SPARSEMEM_MANUAL is not set |
| 172 | CONFIG_FLATMEM=y | 274 | CONFIG_FLATMEM=y |
| 173 | CONFIG_FLAT_NODE_MEM_MAP=y | 275 | CONFIG_FLAT_NODE_MEM_MAP=y |
| 174 | # CONFIG_SPARSEMEM_STATIC is not set | 276 | CONFIG_PAGEFLAGS_EXTENDED=y |
| 175 | CONFIG_SPLIT_PTLOCK_CPUS=4096 | 277 | CONFIG_SPLIT_PTLOCK_CPUS=4096 |
| 278 | # CONFIG_RESOURCES_64BIT is not set | ||
| 279 | # CONFIG_PHYS_ADDR_T_64BIT is not set | ||
| 280 | CONFIG_ZONE_DMA_FLAG=0 | ||
| 281 | CONFIG_VIRT_TO_BUS=y | ||
| 176 | CONFIG_ALIGNMENT_TRAP=y | 282 | CONFIG_ALIGNMENT_TRAP=y |
| 177 | 283 | ||
| 178 | # | 284 | # |
| @@ -182,6 +288,13 @@ CONFIG_ZBOOT_ROM_TEXT=0x0 | |||
| 182 | CONFIG_ZBOOT_ROM_BSS=0x0 | 288 | CONFIG_ZBOOT_ROM_BSS=0x0 |
| 183 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" | 289 | CONFIG_CMDLINE="console=ttyS0,115200n8 console=tty1 noinitrd root=/dev/mtdblock2 rootfstype=jffs2 debug" |
| 184 | # CONFIG_XIP_KERNEL is not set | 290 | # CONFIG_XIP_KERNEL is not set |
| 291 | # CONFIG_KEXEC is not set | ||
| 292 | |||
| 293 | # | ||
| 294 | # CPU Power Management | ||
| 295 | # | ||
| 296 | # CONFIG_CPU_FREQ is not set | ||
| 297 | # CONFIG_CPU_IDLE is not set | ||
| 185 | 298 | ||
| 186 | # | 299 | # |
| 187 | # Floating point emulation | 300 | # Floating point emulation |
| @@ -198,6 +311,7 @@ CONFIG_FPE_NWFPE=y | |||
| 198 | # Userspace binary formats | 311 | # Userspace binary formats |
| 199 | # | 312 | # |
| 200 | CONFIG_BINFMT_ELF=y | 313 | CONFIG_BINFMT_ELF=y |
| 314 | CONFIG_HAVE_AOUT=y | ||
| 201 | CONFIG_BINFMT_AOUT=m | 315 | CONFIG_BINFMT_AOUT=m |
| 202 | CONFIG_BINFMT_MISC=m | 316 | CONFIG_BINFMT_MISC=m |
| 203 | # CONFIG_ARTHUR is not set | 317 | # CONFIG_ARTHUR is not set |
| @@ -206,12 +320,12 @@ CONFIG_BINFMT_MISC=m | |||
| 206 | # Power management options | 320 | # Power management options |
| 207 | # | 321 | # |
| 208 | CONFIG_PM=y | 322 | CONFIG_PM=y |
| 209 | # CONFIG_PM_LEGACY is not set | 323 | # CONFIG_PM_DEBUG is not set |
| 210 | CONFIG_APM=y | 324 | CONFIG_PM_SLEEP=y |
| 211 | 325 | CONFIG_SUSPEND=y | |
| 212 | # | 326 | CONFIG_SUSPEND_FREEZER=y |
| 213 | # Networking | 327 | CONFIG_APM_EMULATION=y |
| 214 | # | 328 | CONFIG_ARCH_SUSPEND_POSSIBLE=y |
| 215 | CONFIG_NET=y | 329 | CONFIG_NET=y |
| 216 | 330 | ||
| 217 | # | 331 | # |
| @@ -222,6 +336,10 @@ CONFIG_PACKET_MMAP=y | |||
| 222 | CONFIG_UNIX=y | 336 | CONFIG_UNIX=y |
| 223 | CONFIG_XFRM=y | 337 | CONFIG_XFRM=y |
| 224 | # CONFIG_XFRM_USER is not set | 338 | # CONFIG_XFRM_USER is not set |
| 339 | # CONFIG_XFRM_SUB_POLICY is not set | ||
| 340 | # CONFIG_XFRM_MIGRATE is not set | ||
| 341 | # CONFIG_XFRM_STATISTICS is not set | ||
| 342 | CONFIG_XFRM_IPCOMP=m | ||
| 225 | # CONFIG_NET_KEY is not set | 343 | # CONFIG_NET_KEY is not set |
| 226 | CONFIG_INET=y | 344 | CONFIG_INET=y |
| 227 | # CONFIG_IP_MULTICAST is not set | 345 | # CONFIG_IP_MULTICAST is not set |
| @@ -235,140 +353,131 @@ CONFIG_SYN_COOKIES=y | |||
| 235 | # CONFIG_INET_AH is not set | 353 | # CONFIG_INET_AH is not set |
| 236 | # CONFIG_INET_ESP is not set | 354 | # CONFIG_INET_ESP is not set |
| 237 | # CONFIG_INET_IPCOMP is not set | 355 | # CONFIG_INET_IPCOMP is not set |
| 238 | # CONFIG_INET_TUNNEL is not set | 356 | # CONFIG_INET_XFRM_TUNNEL is not set |
| 357 | CONFIG_INET_TUNNEL=m | ||
| 358 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
| 359 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
| 360 | CONFIG_INET_XFRM_MODE_BEET=y | ||
| 361 | # CONFIG_INET_LRO is not set | ||
| 239 | CONFIG_INET_DIAG=y | 362 | CONFIG_INET_DIAG=y |
| 240 | CONFIG_INET_TCP_DIAG=y | 363 | CONFIG_INET_TCP_DIAG=y |
| 241 | # CONFIG_TCP_CONG_ADVANCED is not set | 364 | # CONFIG_TCP_CONG_ADVANCED is not set |
| 242 | CONFIG_TCP_CONG_BIC=y | 365 | CONFIG_TCP_CONG_CUBIC=y |
| 243 | 366 | CONFIG_DEFAULT_TCP_CONG="cubic" | |
| 244 | # | 367 | # CONFIG_TCP_MD5SIG is not set |
| 245 | # IP: Virtual Server Configuration | ||
| 246 | # | ||
| 247 | # CONFIG_IP_VS is not set | ||
| 248 | CONFIG_IPV6=m | 368 | CONFIG_IPV6=m |
| 249 | # CONFIG_IPV6_PRIVACY is not set | 369 | # CONFIG_IPV6_PRIVACY is not set |
| 370 | # CONFIG_IPV6_ROUTER_PREF is not set | ||
| 371 | # CONFIG_IPV6_OPTIMISTIC_DAD is not set | ||
| 250 | CONFIG_INET6_AH=m | 372 | CONFIG_INET6_AH=m |
| 251 | CONFIG_INET6_ESP=m | 373 | CONFIG_INET6_ESP=m |
| 252 | CONFIG_INET6_IPCOMP=m | 374 | CONFIG_INET6_IPCOMP=m |
| 375 | # CONFIG_IPV6_MIP6 is not set | ||
| 376 | CONFIG_INET6_XFRM_TUNNEL=m | ||
| 253 | CONFIG_INET6_TUNNEL=m | 377 | CONFIG_INET6_TUNNEL=m |
| 378 | CONFIG_INET6_XFRM_MODE_TRANSPORT=m | ||
| 379 | CONFIG_INET6_XFRM_MODE_TUNNEL=m | ||
| 380 | CONFIG_INET6_XFRM_MODE_BEET=m | ||
| 381 | # CONFIG_INET6_XFRM_MODE_ROUTEOPTIMIZATION is not set | ||
| 382 | CONFIG_IPV6_SIT=m | ||
| 383 | CONFIG_IPV6_NDISC_NODETYPE=y | ||
| 254 | CONFIG_IPV6_TUNNEL=m | 384 | CONFIG_IPV6_TUNNEL=m |
| 385 | # CONFIG_IPV6_MULTIPLE_TABLES is not set | ||
| 386 | # CONFIG_IPV6_MROUTE is not set | ||
| 387 | # CONFIG_NETWORK_SECMARK is not set | ||
| 255 | CONFIG_NETFILTER=y | 388 | CONFIG_NETFILTER=y |
| 256 | # CONFIG_NETFILTER_DEBUG is not set | 389 | # CONFIG_NETFILTER_DEBUG is not set |
| 390 | CONFIG_NETFILTER_ADVANCED=y | ||
| 257 | 391 | ||
| 258 | # | 392 | # |
| 259 | # Core Netfilter Configuration | 393 | # Core Netfilter Configuration |
| 260 | # | 394 | # |
| 261 | # CONFIG_NETFILTER_NETLINK is not set | 395 | # CONFIG_NETFILTER_NETLINK_QUEUE is not set |
| 396 | # CONFIG_NETFILTER_NETLINK_LOG is not set | ||
| 397 | # CONFIG_NF_CONNTRACK is not set | ||
| 398 | CONFIG_NETFILTER_XTABLES=m | ||
| 399 | # CONFIG_NETFILTER_XT_TARGET_CLASSIFY is not set | ||
| 400 | # CONFIG_NETFILTER_XT_TARGET_DSCP is not set | ||
| 401 | # CONFIG_NETFILTER_XT_TARGET_MARK is not set | ||
| 402 | # CONFIG_NETFILTER_XT_TARGET_NFLOG is not set | ||
| 403 | # CONFIG_NETFILTER_XT_TARGET_NFQUEUE is not set | ||
| 404 | # CONFIG_NETFILTER_XT_TARGET_RATEEST is not set | ||
| 405 | # CONFIG_NETFILTER_XT_TARGET_TRACE is not set | ||
| 406 | # CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set | ||
| 407 | # CONFIG_NETFILTER_XT_TARGET_TCPOPTSTRIP is not set | ||
| 408 | # CONFIG_NETFILTER_XT_MATCH_COMMENT is not set | ||
| 409 | # CONFIG_NETFILTER_XT_MATCH_DCCP is not set | ||
| 410 | # CONFIG_NETFILTER_XT_MATCH_DSCP is not set | ||
| 411 | # CONFIG_NETFILTER_XT_MATCH_ESP is not set | ||
| 412 | # CONFIG_NETFILTER_XT_MATCH_HASHLIMIT is not set | ||
| 413 | # CONFIG_NETFILTER_XT_MATCH_IPRANGE is not set | ||
| 414 | # CONFIG_NETFILTER_XT_MATCH_LENGTH is not set | ||
| 415 | # CONFIG_NETFILTER_XT_MATCH_LIMIT is not set | ||
| 416 | # CONFIG_NETFILTER_XT_MATCH_MAC is not set | ||
| 417 | # CONFIG_NETFILTER_XT_MATCH_MARK is not set | ||
| 418 | # CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set | ||
| 419 | # CONFIG_NETFILTER_XT_MATCH_OWNER is not set | ||
| 420 | # CONFIG_NETFILTER_XT_MATCH_POLICY is not set | ||
| 421 | # CONFIG_NETFILTER_XT_MATCH_PKTTYPE is not set | ||
| 422 | # CONFIG_NETFILTER_XT_MATCH_QUOTA is not set | ||
| 423 | # CONFIG_NETFILTER_XT_MATCH_RATEEST is not set | ||
| 424 | # CONFIG_NETFILTER_XT_MATCH_REALM is not set | ||
| 425 | # CONFIG_NETFILTER_XT_MATCH_RECENT is not set | ||
| 426 | # CONFIG_NETFILTER_XT_MATCH_SCTP is not set | ||
| 427 | # CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set | ||
| 428 | # CONFIG_NETFILTER_XT_MATCH_STRING is not set | ||
| 429 | # CONFIG_NETFILTER_XT_MATCH_TCPMSS is not set | ||
| 430 | # CONFIG_NETFILTER_XT_MATCH_TIME is not set | ||
| 431 | # CONFIG_NETFILTER_XT_MATCH_U32 is not set | ||
| 432 | # CONFIG_IP_VS is not set | ||
| 262 | 433 | ||
| 263 | # | 434 | # |
| 264 | # IP: Netfilter Configuration | 435 | # IP: Netfilter Configuration |
| 265 | # | 436 | # |
| 266 | CONFIG_IP_NF_CONNTRACK=m | 437 | # CONFIG_NF_DEFRAG_IPV4 is not set |
| 267 | # CONFIG_IP_NF_CT_ACCT is not set | ||
| 268 | # CONFIG_IP_NF_CONNTRACK_MARK is not set | ||
| 269 | # CONFIG_IP_NF_CONNTRACK_EVENTS is not set | ||
| 270 | CONFIG_IP_NF_CT_PROTO_SCTP=m | ||
| 271 | CONFIG_IP_NF_FTP=m | ||
| 272 | CONFIG_IP_NF_IRC=m | ||
| 273 | # CONFIG_IP_NF_NETBIOS_NS is not set | ||
| 274 | CONFIG_IP_NF_TFTP=m | ||
| 275 | CONFIG_IP_NF_AMANDA=m | ||
| 276 | # CONFIG_IP_NF_PPTP is not set | ||
| 277 | CONFIG_IP_NF_QUEUE=m | 438 | CONFIG_IP_NF_QUEUE=m |
| 278 | CONFIG_IP_NF_IPTABLES=m | 439 | CONFIG_IP_NF_IPTABLES=m |
| 279 | CONFIG_IP_NF_MATCH_LIMIT=m | 440 | CONFIG_IP_NF_MATCH_ADDRTYPE=m |
| 280 | CONFIG_IP_NF_MATCH_IPRANGE=m | 441 | # CONFIG_IP_NF_MATCH_AH is not set |
| 281 | CONFIG_IP_NF_MATCH_MAC=m | ||
| 282 | CONFIG_IP_NF_MATCH_PKTTYPE=m | ||
| 283 | CONFIG_IP_NF_MATCH_MARK=m | ||
| 284 | CONFIG_IP_NF_MATCH_MULTIPORT=m | ||
| 285 | CONFIG_IP_NF_MATCH_TOS=m | ||
| 286 | CONFIG_IP_NF_MATCH_RECENT=m | ||
| 287 | CONFIG_IP_NF_MATCH_ECN=m | 442 | CONFIG_IP_NF_MATCH_ECN=m |
| 288 | CONFIG_IP_NF_MATCH_DSCP=m | ||
| 289 | CONFIG_IP_NF_MATCH_AH_ESP=m | ||
| 290 | CONFIG_IP_NF_MATCH_LENGTH=m | ||
| 291 | CONFIG_IP_NF_MATCH_TTL=m | 443 | CONFIG_IP_NF_MATCH_TTL=m |
| 292 | CONFIG_IP_NF_MATCH_TCPMSS=m | ||
| 293 | CONFIG_IP_NF_MATCH_HELPER=m | ||
| 294 | CONFIG_IP_NF_MATCH_STATE=m | ||
| 295 | CONFIG_IP_NF_MATCH_CONNTRACK=m | ||
| 296 | CONFIG_IP_NF_MATCH_OWNER=m | ||
| 297 | CONFIG_IP_NF_MATCH_ADDRTYPE=m | ||
| 298 | CONFIG_IP_NF_MATCH_REALM=m | ||
| 299 | CONFIG_IP_NF_MATCH_SCTP=m | ||
| 300 | # CONFIG_IP_NF_MATCH_DCCP is not set | ||
| 301 | CONFIG_IP_NF_MATCH_COMMENT=m | ||
| 302 | CONFIG_IP_NF_MATCH_HASHLIMIT=m | ||
| 303 | # CONFIG_IP_NF_MATCH_STRING is not set | ||
| 304 | CONFIG_IP_NF_FILTER=m | 444 | CONFIG_IP_NF_FILTER=m |
| 305 | # CONFIG_IP_NF_TARGET_REJECT is not set | 445 | # CONFIG_IP_NF_TARGET_REJECT is not set |
| 306 | CONFIG_IP_NF_TARGET_LOG=m | 446 | CONFIG_IP_NF_TARGET_LOG=m |
| 307 | CONFIG_IP_NF_TARGET_ULOG=m | 447 | CONFIG_IP_NF_TARGET_ULOG=m |
| 308 | CONFIG_IP_NF_TARGET_TCPMSS=m | ||
| 309 | # CONFIG_IP_NF_TARGET_NFQUEUE is not set | ||
| 310 | CONFIG_IP_NF_NAT=m | ||
| 311 | CONFIG_IP_NF_NAT_NEEDED=y | ||
| 312 | # CONFIG_IP_NF_TARGET_MASQUERADE is not set | ||
| 313 | # CONFIG_IP_NF_TARGET_REDIRECT is not set | ||
| 314 | # CONFIG_IP_NF_TARGET_NETMAP is not set | ||
| 315 | # CONFIG_IP_NF_TARGET_SAME is not set | ||
| 316 | # CONFIG_IP_NF_NAT_SNMP_BASIC is not set | ||
| 317 | CONFIG_IP_NF_NAT_IRC=m | ||
| 318 | CONFIG_IP_NF_NAT_FTP=m | ||
| 319 | CONFIG_IP_NF_NAT_TFTP=m | ||
| 320 | CONFIG_IP_NF_NAT_AMANDA=m | ||
| 321 | CONFIG_IP_NF_MANGLE=m | 448 | CONFIG_IP_NF_MANGLE=m |
| 322 | # CONFIG_IP_NF_TARGET_TOS is not set | ||
| 323 | # CONFIG_IP_NF_TARGET_ECN is not set | 449 | # CONFIG_IP_NF_TARGET_ECN is not set |
| 324 | # CONFIG_IP_NF_TARGET_DSCP is not set | ||
| 325 | # CONFIG_IP_NF_TARGET_MARK is not set | ||
| 326 | # CONFIG_IP_NF_TARGET_CLASSIFY is not set | ||
| 327 | # CONFIG_IP_NF_TARGET_TTL is not set | 450 | # CONFIG_IP_NF_TARGET_TTL is not set |
| 328 | CONFIG_IP_NF_RAW=m | 451 | CONFIG_IP_NF_RAW=m |
| 329 | # CONFIG_IP_NF_TARGET_NOTRACK is not set | ||
| 330 | CONFIG_IP_NF_ARPTABLES=m | 452 | CONFIG_IP_NF_ARPTABLES=m |
| 331 | CONFIG_IP_NF_ARPFILTER=m | 453 | CONFIG_IP_NF_ARPFILTER=m |
| 332 | CONFIG_IP_NF_ARP_MANGLE=m | 454 | CONFIG_IP_NF_ARP_MANGLE=m |
| 333 | 455 | ||
| 334 | # | 456 | # |
| 335 | # IPv6: Netfilter Configuration (EXPERIMENTAL) | 457 | # IPv6: Netfilter Configuration |
| 336 | # | 458 | # |
| 337 | CONFIG_IP6_NF_QUEUE=m | 459 | CONFIG_IP6_NF_QUEUE=m |
| 338 | CONFIG_IP6_NF_IPTABLES=m | 460 | CONFIG_IP6_NF_IPTABLES=m |
| 339 | CONFIG_IP6_NF_MATCH_LIMIT=m | 461 | # CONFIG_IP6_NF_MATCH_AH is not set |
| 340 | CONFIG_IP6_NF_MATCH_MAC=m | 462 | CONFIG_IP6_NF_MATCH_EUI64=m |
| 341 | CONFIG_IP6_NF_MATCH_RT=m | ||
| 342 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
| 343 | CONFIG_IP6_NF_MATCH_FRAG=m | 463 | CONFIG_IP6_NF_MATCH_FRAG=m |
| 464 | CONFIG_IP6_NF_MATCH_OPTS=m | ||
| 344 | CONFIG_IP6_NF_MATCH_HL=m | 465 | CONFIG_IP6_NF_MATCH_HL=m |
| 345 | CONFIG_IP6_NF_MATCH_MULTIPORT=m | ||
| 346 | CONFIG_IP6_NF_MATCH_OWNER=m | ||
| 347 | CONFIG_IP6_NF_MATCH_MARK=m | ||
| 348 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m | 466 | CONFIG_IP6_NF_MATCH_IPV6HEADER=m |
| 349 | CONFIG_IP6_NF_MATCH_AHESP=m | 467 | # CONFIG_IP6_NF_MATCH_MH is not set |
| 350 | CONFIG_IP6_NF_MATCH_LENGTH=m | 468 | CONFIG_IP6_NF_MATCH_RT=m |
| 351 | CONFIG_IP6_NF_MATCH_EUI64=m | ||
| 352 | CONFIG_IP6_NF_FILTER=m | ||
| 353 | # CONFIG_IP6_NF_TARGET_LOG is not set | 469 | # CONFIG_IP6_NF_TARGET_LOG is not set |
| 470 | CONFIG_IP6_NF_FILTER=m | ||
| 354 | # CONFIG_IP6_NF_TARGET_REJECT is not set | 471 | # CONFIG_IP6_NF_TARGET_REJECT is not set |
| 355 | # CONFIG_IP6_NF_TARGET_NFQUEUE is not set | ||
| 356 | CONFIG_IP6_NF_MANGLE=m | 472 | CONFIG_IP6_NF_MANGLE=m |
| 357 | # CONFIG_IP6_NF_TARGET_MARK is not set | ||
| 358 | # CONFIG_IP6_NF_TARGET_HL is not set | 473 | # CONFIG_IP6_NF_TARGET_HL is not set |
| 359 | CONFIG_IP6_NF_RAW=m | 474 | CONFIG_IP6_NF_RAW=m |
| 360 | |||
| 361 | # | ||
| 362 | # DCCP Configuration (EXPERIMENTAL) | ||
| 363 | # | ||
| 364 | # CONFIG_IP_DCCP is not set | 475 | # CONFIG_IP_DCCP is not set |
| 365 | |||
| 366 | # | ||
| 367 | # SCTP Configuration (EXPERIMENTAL) | ||
| 368 | # | ||
| 369 | # CONFIG_IP_SCTP is not set | 476 | # CONFIG_IP_SCTP is not set |
| 477 | # CONFIG_TIPC is not set | ||
| 370 | # CONFIG_ATM is not set | 478 | # CONFIG_ATM is not set |
| 371 | # CONFIG_BRIDGE is not set | 479 | # CONFIG_BRIDGE is not set |
| 480 | # CONFIG_NET_DSA is not set | ||
| 372 | # CONFIG_VLAN_8021Q is not set | 481 | # CONFIG_VLAN_8021Q is not set |
| 373 | # CONFIG_DECNET is not set | 482 | # CONFIG_DECNET is not set |
| 374 | # CONFIG_LLC2 is not set | 483 | # CONFIG_LLC2 is not set |
| @@ -376,21 +485,16 @@ CONFIG_IP6_NF_RAW=m | |||
| 376 | # CONFIG_ATALK is not set | 485 | # CONFIG_ATALK is not set |
| 377 | # CONFIG_X25 is not set | 486 | # CONFIG_X25 is not set |
| 378 | # CONFIG_LAPB is not set | 487 | # CONFIG_LAPB is not set |
| 379 | # CONFIG_NET_DIVERT is not set | ||
| 380 | # CONFIG_ECONET is not set | 488 | # CONFIG_ECONET is not set |
| 381 | # CONFIG_WAN_ROUTER is not set | 489 | # CONFIG_WAN_ROUTER is not set |
| 382 | |||
| 383 | # | ||
| 384 | # QoS and/or fair queueing | ||
| 385 | # | ||
| 386 | # CONFIG_NET_SCHED is not set | 490 | # CONFIG_NET_SCHED is not set |
| 387 | CONFIG_NET_CLS_ROUTE=y | ||
| 388 | 491 | ||
| 389 | # | 492 | # |
| 390 | # Network testing | 493 | # Network testing |
| 391 | # | 494 | # |
| 392 | # CONFIG_NET_PKTGEN is not set | 495 | # CONFIG_NET_PKTGEN is not set |
| 393 | # CONFIG_HAMRADIO is not set | 496 | # CONFIG_HAMRADIO is not set |
| 497 | # CONFIG_CAN is not set | ||
| 394 | CONFIG_IRDA=m | 498 | CONFIG_IRDA=m |
| 395 | 499 | ||
| 396 | # | 500 | # |
| @@ -420,27 +524,17 @@ CONFIG_IRCOMM=m | |||
| 420 | # | 524 | # |
| 421 | # Dongle support | 525 | # Dongle support |
| 422 | # | 526 | # |
| 423 | 527 | # CONFIG_KINGSUN_DONGLE is not set | |
| 424 | # | 528 | # CONFIG_KSDAZZLE_DONGLE is not set |
| 425 | # Old SIR device drivers | 529 | # CONFIG_KS959_DONGLE is not set |
| 426 | # | ||
| 427 | # CONFIG_IRPORT_SIR is not set | ||
| 428 | |||
| 429 | # | ||
| 430 | # Old Serial dongle support | ||
| 431 | # | ||
| 432 | 530 | ||
| 433 | # | 531 | # |
| 434 | # FIR device drivers | 532 | # FIR device drivers |
| 435 | # | 533 | # |
| 436 | # CONFIG_USB_IRDA is not set | 534 | # CONFIG_USB_IRDA is not set |
| 437 | # CONFIG_SIGMATEL_FIR is not set | 535 | # CONFIG_SIGMATEL_FIR is not set |
| 438 | # CONFIG_NSC_FIR is not set | ||
| 439 | # CONFIG_WINBOND_FIR is not set | ||
| 440 | # CONFIG_SMC_IRCC_FIR is not set | ||
| 441 | # CONFIG_ALI_FIR is not set | ||
| 442 | # CONFIG_VIA_FIR is not set | ||
| 443 | CONFIG_PXA_FICP=m | 536 | CONFIG_PXA_FICP=m |
| 537 | # CONFIG_MCS_FIR is not set | ||
| 444 | CONFIG_BT=m | 538 | CONFIG_BT=m |
| 445 | CONFIG_BT_L2CAP=m | 539 | CONFIG_BT_L2CAP=m |
| 446 | CONFIG_BT_SCO=m | 540 | CONFIG_BT_SCO=m |
| @@ -456,9 +550,12 @@ CONFIG_BT_HIDP=m | |||
| 456 | # | 550 | # |
| 457 | CONFIG_BT_HCIUSB=m | 551 | CONFIG_BT_HCIUSB=m |
| 458 | # CONFIG_BT_HCIUSB_SCO is not set | 552 | # CONFIG_BT_HCIUSB_SCO is not set |
| 553 | # CONFIG_BT_HCIBTUSB is not set | ||
| 554 | # CONFIG_BT_HCIBTSDIO is not set | ||
| 459 | CONFIG_BT_HCIUART=m | 555 | CONFIG_BT_HCIUART=m |
| 460 | CONFIG_BT_HCIUART_H4=y | 556 | CONFIG_BT_HCIUART_H4=y |
| 461 | CONFIG_BT_HCIUART_BCSP=y | 557 | CONFIG_BT_HCIUART_BCSP=y |
| 558 | # CONFIG_BT_HCIUART_LL is not set | ||
| 462 | CONFIG_BT_HCIBCM203X=m | 559 | CONFIG_BT_HCIBCM203X=m |
| 463 | CONFIG_BT_HCIBPA10X=m | 560 | CONFIG_BT_HCIBPA10X=m |
| 464 | CONFIG_BT_HCIBFUSB=m | 561 | CONFIG_BT_HCIBFUSB=m |
| @@ -467,11 +564,20 @@ CONFIG_BT_HCIBT3C=m | |||
| 467 | CONFIG_BT_HCIBLUECARD=m | 564 | CONFIG_BT_HCIBLUECARD=m |
| 468 | CONFIG_BT_HCIBTUART=m | 565 | CONFIG_BT_HCIBTUART=m |
| 469 | CONFIG_BT_HCIVHCI=m | 566 | CONFIG_BT_HCIVHCI=m |
| 567 | # CONFIG_AF_RXRPC is not set | ||
| 568 | # CONFIG_PHONET is not set | ||
| 569 | CONFIG_WIRELESS=y | ||
| 570 | # CONFIG_CFG80211 is not set | ||
| 571 | # CONFIG_WIRELESS_OLD_REGULATORY is not set | ||
| 572 | # CONFIG_WIRELESS_EXT is not set | ||
| 573 | # CONFIG_MAC80211 is not set | ||
| 470 | CONFIG_IEEE80211=m | 574 | CONFIG_IEEE80211=m |
| 471 | # CONFIG_IEEE80211_DEBUG is not set | 575 | # CONFIG_IEEE80211_DEBUG is not set |
| 472 | CONFIG_IEEE80211_CRYPT_WEP=m | 576 | CONFIG_IEEE80211_CRYPT_WEP=m |
| 473 | # CONFIG_IEEE80211_CRYPT_CCMP is not set | 577 | # CONFIG_IEEE80211_CRYPT_CCMP is not set |
| 474 | # CONFIG_IEEE80211_CRYPT_TKIP is not set | 578 | # CONFIG_IEEE80211_CRYPT_TKIP is not set |
| 579 | # CONFIG_RFKILL is not set | ||
| 580 | # CONFIG_NET_9P is not set | ||
| 475 | 581 | ||
| 476 | # | 582 | # |
| 477 | # Device Drivers | 583 | # Device Drivers |
| @@ -480,19 +586,16 @@ CONFIG_IEEE80211_CRYPT_WEP=m | |||
| 480 | # | 586 | # |
| 481 | # Generic Driver Options | 587 | # Generic Driver Options |
| 482 | # | 588 | # |
| 589 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
| 483 | CONFIG_STANDALONE=y | 590 | CONFIG_STANDALONE=y |
| 484 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 591 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
| 485 | CONFIG_FW_LOADER=y | 592 | CONFIG_FW_LOADER=y |
| 593 | CONFIG_FIRMWARE_IN_KERNEL=y | ||
| 594 | CONFIG_EXTRA_FIRMWARE="" | ||
| 486 | # CONFIG_DEBUG_DRIVER is not set | 595 | # CONFIG_DEBUG_DRIVER is not set |
| 487 | 596 | # CONFIG_DEBUG_DEVRES is not set | |
| 488 | # | 597 | # CONFIG_SYS_HYPERVISOR is not set |
| 489 | # Connector - unified userspace <-> kernelspace linker | ||
| 490 | # | ||
| 491 | # CONFIG_CONNECTOR is not set | 598 | # CONFIG_CONNECTOR is not set |
| 492 | |||
| 493 | # | ||
| 494 | # Memory Technology Devices (MTD) | ||
| 495 | # | ||
| 496 | CONFIG_MTD=y | 599 | CONFIG_MTD=y |
| 497 | # CONFIG_MTD_DEBUG is not set | 600 | # CONFIG_MTD_DEBUG is not set |
| 498 | # CONFIG_MTD_CONCAT is not set | 601 | # CONFIG_MTD_CONCAT is not set |
| @@ -500,16 +603,20 @@ CONFIG_MTD_PARTITIONS=y | |||
| 500 | # CONFIG_MTD_REDBOOT_PARTS is not set | 603 | # CONFIG_MTD_REDBOOT_PARTS is not set |
| 501 | CONFIG_MTD_CMDLINE_PARTS=y | 604 | CONFIG_MTD_CMDLINE_PARTS=y |
| 502 | # CONFIG_MTD_AFS_PARTS is not set | 605 | # CONFIG_MTD_AFS_PARTS is not set |
| 606 | # CONFIG_MTD_AR7_PARTS is not set | ||
| 503 | 607 | ||
| 504 | # | 608 | # |
| 505 | # User Modules And Translation Layers | 609 | # User Modules And Translation Layers |
| 506 | # | 610 | # |
| 507 | CONFIG_MTD_CHAR=y | 611 | CONFIG_MTD_CHAR=y |
| 612 | CONFIG_MTD_BLKDEVS=y | ||
| 508 | CONFIG_MTD_BLOCK=y | 613 | CONFIG_MTD_BLOCK=y |
| 509 | # CONFIG_FTL is not set | 614 | # CONFIG_FTL is not set |
| 510 | # CONFIG_NFTL is not set | 615 | # CONFIG_NFTL is not set |
| 511 | # CONFIG_INFTL is not set | 616 | # CONFIG_INFTL is not set |
| 512 | # CONFIG_RFD_FTL is not set | 617 | # CONFIG_RFD_FTL is not set |
| 618 | # CONFIG_SSFDC is not set | ||
| 619 | # CONFIG_MTD_OOPS is not set | ||
| 513 | 620 | ||
| 514 | # | 621 | # |
| 515 | # RAM/ROM/Flash chip drivers | 622 | # RAM/ROM/Flash chip drivers |
| @@ -534,16 +641,18 @@ CONFIG_MTD_ROM=y | |||
| 534 | # Mapping drivers for chip access | 641 | # Mapping drivers for chip access |
| 535 | # | 642 | # |
| 536 | CONFIG_MTD_COMPLEX_MAPPINGS=y | 643 | CONFIG_MTD_COMPLEX_MAPPINGS=y |
| 644 | # CONFIG_MTD_PHYSMAP is not set | ||
| 537 | CONFIG_MTD_SHARP_SL=y | 645 | CONFIG_MTD_SHARP_SL=y |
| 538 | # CONFIG_MTD_PLATRAM is not set | 646 | # CONFIG_MTD_PLATRAM is not set |
| 539 | 647 | ||
| 540 | # | 648 | # |
| 541 | # Self-contained MTD device drivers | 649 | # Self-contained MTD device drivers |
| 542 | # | 650 | # |
| 651 | # CONFIG_MTD_DATAFLASH is not set | ||
| 652 | # CONFIG_MTD_M25P80 is not set | ||
| 543 | # CONFIG_MTD_SLRAM is not set | 653 | # CONFIG_MTD_SLRAM is not set |
| 544 | # CONFIG_MTD_PHRAM is not set | 654 | # CONFIG_MTD_PHRAM is not set |
| 545 | # CONFIG_MTD_MTDRAM is not set | 655 | # CONFIG_MTD_MTDRAM is not set |
| 546 | # CONFIG_MTD_BLKMTD is not set | ||
| 547 | # CONFIG_MTD_BLOCK2MTD is not set | 656 | # CONFIG_MTD_BLOCK2MTD is not set |
| 548 | 657 | ||
| 549 | # | 658 | # |
| @@ -552,78 +661,66 @@ CONFIG_MTD_SHARP_SL=y | |||
| 552 | # CONFIG_MTD_DOC2000 is not set | 661 | # CONFIG_MTD_DOC2000 is not set |
| 553 | # CONFIG_MTD_DOC2001 is not set | 662 | # CONFIG_MTD_DOC2001 is not set |
| 554 | # CONFIG_MTD_DOC2001PLUS is not set | 663 | # CONFIG_MTD_DOC2001PLUS is not set |
| 555 | |||
| 556 | # | ||
| 557 | # NAND Flash Device Drivers | ||
| 558 | # | ||
| 559 | CONFIG_MTD_NAND=y | 664 | CONFIG_MTD_NAND=y |
| 560 | CONFIG_MTD_NAND_VERIFY_WRITE=y | 665 | CONFIG_MTD_NAND_VERIFY_WRITE=y |
| 666 | # CONFIG_MTD_NAND_ECC_SMC is not set | ||
| 667 | # CONFIG_MTD_NAND_MUSEUM_IDS is not set | ||
| 561 | # CONFIG_MTD_NAND_H1900 is not set | 668 | # CONFIG_MTD_NAND_H1900 is not set |
| 562 | CONFIG_MTD_NAND_IDS=y | 669 | CONFIG_MTD_NAND_IDS=y |
| 563 | # CONFIG_MTD_NAND_DISKONCHIP is not set | 670 | # CONFIG_MTD_NAND_DISKONCHIP is not set |
| 564 | CONFIG_MTD_NAND_SHARPSL=y | 671 | CONFIG_MTD_NAND_SHARPSL=y |
| 565 | # CONFIG_MTD_NAND_NANDSIM is not set | 672 | # CONFIG_MTD_NAND_NANDSIM is not set |
| 566 | 673 | # CONFIG_MTD_NAND_PLATFORM is not set | |
| 567 | # | 674 | # CONFIG_MTD_ALAUDA is not set |
| 568 | # OneNAND Flash Device Drivers | ||
| 569 | # | ||
| 570 | # CONFIG_MTD_ONENAND is not set | 675 | # CONFIG_MTD_ONENAND is not set |
| 571 | 676 | ||
| 572 | # | 677 | # |
| 573 | # Parallel port support | 678 | # UBI - Unsorted block images |
| 574 | # | 679 | # |
| 680 | # CONFIG_MTD_UBI is not set | ||
| 575 | # CONFIG_PARPORT is not set | 681 | # CONFIG_PARPORT is not set |
| 576 | 682 | CONFIG_BLK_DEV=y | |
| 577 | # | ||
| 578 | # Plug and Play support | ||
| 579 | # | ||
| 580 | |||
| 581 | # | ||
| 582 | # Block devices | ||
| 583 | # | ||
| 584 | # CONFIG_BLK_DEV_COW_COMMON is not set | 683 | # CONFIG_BLK_DEV_COW_COMMON is not set |
| 585 | CONFIG_BLK_DEV_LOOP=y | 684 | CONFIG_BLK_DEV_LOOP=y |
| 586 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set | 685 | # CONFIG_BLK_DEV_CRYPTOLOOP is not set |
| 587 | # CONFIG_BLK_DEV_NBD is not set | 686 | # CONFIG_BLK_DEV_NBD is not set |
| 588 | # CONFIG_BLK_DEV_UB is not set | 687 | # CONFIG_BLK_DEV_UB is not set |
| 589 | # CONFIG_BLK_DEV_RAM is not set | 688 | # CONFIG_BLK_DEV_RAM is not set |
| 590 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
| 591 | # CONFIG_CDROM_PKTCDVD is not set | 689 | # CONFIG_CDROM_PKTCDVD is not set |
| 592 | # CONFIG_ATA_OVER_ETH is not set | 690 | # CONFIG_ATA_OVER_ETH is not set |
| 593 | 691 | CONFIG_MISC_DEVICES=y | |
| 594 | # | 692 | # CONFIG_EEPROM_93CX6 is not set |
| 595 | # ATA/ATAPI/MFM/RLL support | 693 | # CONFIG_ENCLOSURE_SERVICES is not set |
| 596 | # | 694 | CONFIG_HAVE_IDE=y |
| 597 | CONFIG_IDE=y | 695 | CONFIG_IDE=y |
| 598 | CONFIG_BLK_DEV_IDE=y | ||
| 599 | 696 | ||
| 600 | # | 697 | # |
| 601 | # Please see Documentation/ide.txt for help/info on IDE drives | 698 | # Please see Documentation/ide/ide.txt for help/info on IDE drives |
| 602 | # | 699 | # |
| 603 | # CONFIG_BLK_DEV_IDE_SATA is not set | 700 | # CONFIG_BLK_DEV_IDE_SATA is not set |
| 604 | CONFIG_BLK_DEV_IDEDISK=y | 701 | CONFIG_BLK_DEV_IDEDISK=y |
| 605 | # CONFIG_IDEDISK_MULTI_MODE is not set | ||
| 606 | CONFIG_BLK_DEV_IDECS=y | 702 | CONFIG_BLK_DEV_IDECS=y |
| 607 | # CONFIG_BLK_DEV_IDECD is not set | 703 | # CONFIG_BLK_DEV_IDECD is not set |
| 608 | # CONFIG_BLK_DEV_IDETAPE is not set | 704 | # CONFIG_BLK_DEV_IDETAPE is not set |
| 609 | # CONFIG_BLK_DEV_IDEFLOPPY is not set | 705 | # CONFIG_BLK_DEV_IDEFLOPPY is not set |
| 610 | # CONFIG_BLK_DEV_IDESCSI is not set | 706 | # CONFIG_BLK_DEV_IDESCSI is not set |
| 611 | # CONFIG_IDE_TASK_IOCTL is not set | 707 | # CONFIG_IDE_TASK_IOCTL is not set |
| 708 | CONFIG_IDE_PROC_FS=y | ||
| 612 | 709 | ||
| 613 | # | 710 | # |
| 614 | # IDE chipset support/bugfixes | 711 | # IDE chipset support/bugfixes |
| 615 | # | 712 | # |
| 616 | CONFIG_IDE_GENERIC=y | 713 | # CONFIG_BLK_DEV_PLATFORM is not set |
| 617 | # CONFIG_IDE_ARM is not set | ||
| 618 | # CONFIG_BLK_DEV_IDEDMA is not set | 714 | # CONFIG_BLK_DEV_IDEDMA is not set |
| 619 | # CONFIG_IDEDMA_AUTO is not set | ||
| 620 | # CONFIG_BLK_DEV_HD is not set | ||
| 621 | 715 | ||
| 622 | # | 716 | # |
| 623 | # SCSI device support | 717 | # SCSI device support |
| 624 | # | 718 | # |
| 625 | # CONFIG_RAID_ATTRS is not set | 719 | # CONFIG_RAID_ATTRS is not set |
| 626 | CONFIG_SCSI=m | 720 | CONFIG_SCSI=m |
| 721 | CONFIG_SCSI_DMA=y | ||
| 722 | # CONFIG_SCSI_TGT is not set | ||
| 723 | # CONFIG_SCSI_NETLINK is not set | ||
| 627 | CONFIG_SCSI_PROC_FS=y | 724 | CONFIG_SCSI_PROC_FS=y |
| 628 | 725 | ||
| 629 | # | 726 | # |
| @@ -643,121 +740,76 @@ CONFIG_CHR_DEV_SG=m | |||
| 643 | CONFIG_SCSI_MULTI_LUN=y | 740 | CONFIG_SCSI_MULTI_LUN=y |
| 644 | # CONFIG_SCSI_CONSTANTS is not set | 741 | # CONFIG_SCSI_CONSTANTS is not set |
| 645 | # CONFIG_SCSI_LOGGING is not set | 742 | # CONFIG_SCSI_LOGGING is not set |
| 743 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
| 744 | CONFIG_SCSI_WAIT_SCAN=m | ||
| 646 | 745 | ||
| 647 | # | 746 | # |
| 648 | # SCSI Transport Attributes | 747 | # SCSI Transports |
| 649 | # | 748 | # |
| 650 | # CONFIG_SCSI_SPI_ATTRS is not set | 749 | # CONFIG_SCSI_SPI_ATTRS is not set |
| 651 | # CONFIG_SCSI_FC_ATTRS is not set | 750 | # CONFIG_SCSI_FC_ATTRS is not set |
| 652 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 751 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
| 653 | # CONFIG_SCSI_SAS_ATTRS is not set | 752 | # CONFIG_SCSI_SAS_LIBSAS is not set |
| 654 | 753 | # CONFIG_SCSI_SRP_ATTRS is not set | |
| 655 | # | 754 | CONFIG_SCSI_LOWLEVEL=y |
| 656 | # SCSI low-level drivers | ||
| 657 | # | ||
| 658 | # CONFIG_ISCSI_TCP is not set | 755 | # CONFIG_ISCSI_TCP is not set |
| 659 | # CONFIG_SCSI_SATA is not set | ||
| 660 | # CONFIG_SCSI_DEBUG is not set | 756 | # CONFIG_SCSI_DEBUG is not set |
| 661 | 757 | # CONFIG_SCSI_LOWLEVEL_PCMCIA is not set | |
| 662 | # | 758 | # CONFIG_SCSI_DH is not set |
| 663 | # PCMCIA SCSI adapter support | 759 | # CONFIG_ATA is not set |
| 664 | # | ||
| 665 | # CONFIG_PCMCIA_AHA152X is not set | ||
| 666 | # CONFIG_PCMCIA_FDOMAIN is not set | ||
| 667 | # CONFIG_PCMCIA_NINJA_SCSI is not set | ||
| 668 | # CONFIG_PCMCIA_QLOGIC is not set | ||
| 669 | # CONFIG_PCMCIA_SYM53C500 is not set | ||
| 670 | |||
| 671 | # | ||
| 672 | # Multi-device support (RAID and LVM) | ||
| 673 | # | ||
| 674 | # CONFIG_MD is not set | 760 | # CONFIG_MD is not set |
| 675 | |||
| 676 | # | ||
| 677 | # Fusion MPT device support | ||
| 678 | # | ||
| 679 | # CONFIG_FUSION is not set | ||
| 680 | |||
| 681 | # | ||
| 682 | # IEEE 1394 (FireWire) support | ||
| 683 | # | ||
| 684 | |||
| 685 | # | ||
| 686 | # I2O device support | ||
| 687 | # | ||
| 688 | |||
| 689 | # | ||
| 690 | # Network device support | ||
| 691 | # | ||
| 692 | CONFIG_NETDEVICES=y | 761 | CONFIG_NETDEVICES=y |
| 693 | # CONFIG_DUMMY is not set | 762 | # CONFIG_DUMMY is not set |
| 694 | # CONFIG_BONDING is not set | 763 | # CONFIG_BONDING is not set |
| 764 | # CONFIG_MACVLAN is not set | ||
| 695 | # CONFIG_EQUALIZER is not set | 765 | # CONFIG_EQUALIZER is not set |
| 696 | # CONFIG_TUN is not set | 766 | # CONFIG_TUN is not set |
| 697 | 767 | # CONFIG_VETH is not set | |
| 698 | # | ||
| 699 | # PHY device support | ||
| 700 | # | ||
| 701 | # CONFIG_PHYLIB is not set | 768 | # CONFIG_PHYLIB is not set |
| 702 | |||
| 703 | # | ||
| 704 | # Ethernet (10 or 100Mbit) | ||
| 705 | # | ||
| 706 | CONFIG_NET_ETHERNET=y | 769 | CONFIG_NET_ETHERNET=y |
| 707 | CONFIG_MII=m | 770 | CONFIG_MII=m |
| 771 | # CONFIG_AX88796 is not set | ||
| 708 | # CONFIG_SMC91X is not set | 772 | # CONFIG_SMC91X is not set |
| 709 | # CONFIG_DM9000 is not set | 773 | # CONFIG_DM9000 is not set |
| 774 | # CONFIG_ENC28J60 is not set | ||
| 775 | # CONFIG_SMC911X is not set | ||
| 776 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
| 777 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
| 778 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
| 779 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
| 780 | # CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set | ||
| 781 | # CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set | ||
| 782 | # CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set | ||
| 783 | # CONFIG_B44 is not set | ||
| 784 | CONFIG_NETDEV_1000=y | ||
| 785 | CONFIG_NETDEV_10000=y | ||
| 710 | 786 | ||
| 711 | # | 787 | # |
| 712 | # Ethernet (1000 Mbit) | 788 | # Wireless LAN |
| 713 | # | ||
| 714 | |||
| 715 | # | ||
| 716 | # Ethernet (10000 Mbit) | ||
| 717 | # | ||
| 718 | |||
| 719 | # | ||
| 720 | # Token Ring devices | ||
| 721 | # | 789 | # |
| 790 | # CONFIG_WLAN_PRE80211 is not set | ||
| 791 | # CONFIG_WLAN_80211 is not set | ||
| 792 | # CONFIG_IWLWIFI_LEDS is not set | ||
| 722 | 793 | ||
| 723 | # | 794 | # |
| 724 | # Wireless LAN (non-hamradio) | 795 | # USB Network Adapters |
| 725 | # | ||
| 726 | CONFIG_NET_RADIO=y | ||
| 727 | |||
| 728 | # | ||
| 729 | # Obsolete Wireless cards support (pre-802.11) | ||
| 730 | # | ||
| 731 | # CONFIG_STRIP is not set | ||
| 732 | # CONFIG_PCMCIA_WAVELAN is not set | ||
| 733 | # CONFIG_PCMCIA_NETWAVE is not set | ||
| 734 | |||
| 735 | # | ||
| 736 | # Wireless 802.11 Frequency Hopping cards support | ||
| 737 | # | ||
| 738 | # CONFIG_PCMCIA_RAYCS is not set | ||
| 739 | |||
| 740 | # | ||
| 741 | # Wireless 802.11b ISA/PCI cards support | ||
| 742 | # | ||
| 743 | CONFIG_HERMES=m | ||
| 744 | # CONFIG_ATMEL is not set | ||
| 745 | |||
| 746 | # | ||
| 747 | # Wireless 802.11b Pcmcia/Cardbus cards support | ||
| 748 | # | ||
| 749 | CONFIG_PCMCIA_HERMES=m | ||
| 750 | CONFIG_PCMCIA_SPECTRUM=m | ||
| 751 | # CONFIG_AIRO_CS is not set | ||
| 752 | # CONFIG_PCMCIA_WL3501 is not set | ||
| 753 | CONFIG_HOSTAP=m | ||
| 754 | CONFIG_HOSTAP_FIRMWARE=y | ||
| 755 | CONFIG_HOSTAP_CS=m | ||
| 756 | CONFIG_NET_WIRELESS=y | ||
| 757 | |||
| 758 | # | ||
| 759 | # PCMCIA network device support | ||
| 760 | # | 796 | # |
| 797 | CONFIG_USB_CATC=m | ||
| 798 | CONFIG_USB_KAWETH=m | ||
| 799 | CONFIG_USB_PEGASUS=m | ||
| 800 | CONFIG_USB_RTL8150=m | ||
| 801 | CONFIG_USB_USBNET=m | ||
| 802 | CONFIG_USB_NET_AX8817X=m | ||
| 803 | CONFIG_USB_NET_CDCETHER=m | ||
| 804 | # CONFIG_USB_NET_DM9601 is not set | ||
| 805 | # CONFIG_USB_NET_SMSC95XX is not set | ||
| 806 | # CONFIG_USB_NET_GL620A is not set | ||
| 807 | CONFIG_USB_NET_NET1080=m | ||
| 808 | # CONFIG_USB_NET_PLUSB is not set | ||
| 809 | # CONFIG_USB_NET_MCS7830 is not set | ||
| 810 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
| 811 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
| 812 | CONFIG_USB_NET_ZAURUS=m | ||
| 761 | CONFIG_NET_PCMCIA=y | 813 | CONFIG_NET_PCMCIA=y |
| 762 | # CONFIG_PCMCIA_3C589 is not set | 814 | # CONFIG_PCMCIA_3C589 is not set |
| 763 | # CONFIG_PCMCIA_3C574 is not set | 815 | # CONFIG_PCMCIA_3C574 is not set |
| @@ -767,10 +819,6 @@ CONFIG_PCMCIA_PCNET=m | |||
| 767 | # CONFIG_PCMCIA_SMC91C92 is not set | 819 | # CONFIG_PCMCIA_SMC91C92 is not set |
| 768 | # CONFIG_PCMCIA_XIRC2PS is not set | 820 | # CONFIG_PCMCIA_XIRC2PS is not set |
| 769 | # CONFIG_PCMCIA_AXNET is not set | 821 | # CONFIG_PCMCIA_AXNET is not set |
| 770 | |||
| 771 | # | ||
| 772 | # Wan interfaces | ||
| 773 | # | ||
| 774 | # CONFIG_WAN is not set | 822 | # CONFIG_WAN is not set |
| 775 | CONFIG_PPP=m | 823 | CONFIG_PPP=m |
| 776 | # CONFIG_PPP_MULTILINK is not set | 824 | # CONFIG_PPP_MULTILINK is not set |
| @@ -781,31 +829,29 @@ CONFIG_PPP_ASYNC=m | |||
| 781 | CONFIG_PPP_BSDCOMP=m | 829 | CONFIG_PPP_BSDCOMP=m |
| 782 | # CONFIG_PPP_MPPE is not set | 830 | # CONFIG_PPP_MPPE is not set |
| 783 | # CONFIG_PPPOE is not set | 831 | # CONFIG_PPPOE is not set |
| 832 | # CONFIG_PPPOL2TP is not set | ||
| 784 | # CONFIG_SLIP is not set | 833 | # CONFIG_SLIP is not set |
| 785 | # CONFIG_SHAPER is not set | 834 | CONFIG_SLHC=m |
| 786 | # CONFIG_NETCONSOLE is not set | 835 | # CONFIG_NETCONSOLE is not set |
| 787 | # CONFIG_NETPOLL is not set | 836 | # CONFIG_NETPOLL is not set |
| 788 | # CONFIG_NET_POLL_CONTROLLER is not set | 837 | # CONFIG_NET_POLL_CONTROLLER is not set |
| 789 | |||
| 790 | # | ||
| 791 | # ISDN subsystem | ||
| 792 | # | ||
| 793 | # CONFIG_ISDN is not set | 838 | # CONFIG_ISDN is not set |
| 794 | 839 | ||
| 795 | # | 840 | # |
| 796 | # Input device support | 841 | # Input device support |
| 797 | # | 842 | # |
| 798 | CONFIG_INPUT=y | 843 | CONFIG_INPUT=y |
| 844 | CONFIG_INPUT_FF_MEMLESS=m | ||
| 845 | # CONFIG_INPUT_POLLDEV is not set | ||
| 799 | 846 | ||
| 800 | # | 847 | # |
| 801 | # Userland interfaces | 848 | # Userland interfaces |
| 802 | # | 849 | # |
| 803 | # CONFIG_INPUT_MOUSEDEV is not set | 850 | # CONFIG_INPUT_MOUSEDEV is not set |
| 804 | # CONFIG_INPUT_JOYDEV is not set | 851 | # CONFIG_INPUT_JOYDEV is not set |
| 805 | # CONFIG_INPUT_TSDEV is not set | ||
| 806 | CONFIG_INPUT_EVDEV=y | 852 | CONFIG_INPUT_EVDEV=y |
| 807 | # CONFIG_INPUT_EVBUG is not set | 853 | # CONFIG_INPUT_EVBUG is not set |
| 808 | # CONFIG_INPUT_POWER is not set | 854 | # CONFIG_INPUT_APMPOWER is not set |
| 809 | 855 | ||
| 810 | # | 856 | # |
| 811 | # Input Device Drivers | 857 | # Input Device Drivers |
| @@ -816,17 +862,35 @@ CONFIG_INPUT_KEYBOARD=y | |||
| 816 | # CONFIG_KEYBOARD_LKKBD is not set | 862 | # CONFIG_KEYBOARD_LKKBD is not set |
| 817 | # CONFIG_KEYBOARD_XTKBD is not set | 863 | # CONFIG_KEYBOARD_XTKBD is not set |
| 818 | # CONFIG_KEYBOARD_NEWTON is not set | 864 | # CONFIG_KEYBOARD_NEWTON is not set |
| 865 | # CONFIG_KEYBOARD_STOWAWAY is not set | ||
| 819 | # CONFIG_KEYBOARD_CORGI is not set | 866 | # CONFIG_KEYBOARD_CORGI is not set |
| 820 | CONFIG_KEYBOARD_SPITZ=y | 867 | CONFIG_KEYBOARD_SPITZ=y |
| 868 | # CONFIG_KEYBOARD_PXA27x is not set | ||
| 869 | # CONFIG_KEYBOARD_GPIO is not set | ||
| 821 | # CONFIG_INPUT_MOUSE is not set | 870 | # CONFIG_INPUT_MOUSE is not set |
| 822 | # CONFIG_INPUT_JOYSTICK is not set | 871 | # CONFIG_INPUT_JOYSTICK is not set |
| 872 | # CONFIG_INPUT_TABLET is not set | ||
| 823 | CONFIG_INPUT_TOUCHSCREEN=y | 873 | CONFIG_INPUT_TOUCHSCREEN=y |
| 824 | CONFIG_TOUCHSCREEN_CORGI=y | 874 | CONFIG_TOUCHSCREEN_ADS7846=y |
| 875 | # CONFIG_TOUCHSCREEN_CORGI is not set | ||
| 876 | # CONFIG_TOUCHSCREEN_FUJITSU is not set | ||
| 825 | # CONFIG_TOUCHSCREEN_GUNZE is not set | 877 | # CONFIG_TOUCHSCREEN_GUNZE is not set |
| 826 | # CONFIG_TOUCHSCREEN_ELO is not set | 878 | # CONFIG_TOUCHSCREEN_ELO is not set |
| 827 | # CONFIG_TOUCHSCREEN_MTOUCH is not set | 879 | # CONFIG_TOUCHSCREEN_MTOUCH is not set |
| 880 | # CONFIG_TOUCHSCREEN_INEXIO is not set | ||
| 828 | # CONFIG_TOUCHSCREEN_MK712 is not set | 881 | # CONFIG_TOUCHSCREEN_MK712 is not set |
| 882 | # CONFIG_TOUCHSCREEN_PENMOUNT is not set | ||
| 883 | # CONFIG_TOUCHSCREEN_TOUCHRIGHT is not set | ||
| 884 | # CONFIG_TOUCHSCREEN_TOUCHWIN is not set | ||
| 885 | # CONFIG_TOUCHSCREEN_USB_COMPOSITE is not set | ||
| 886 | # CONFIG_TOUCHSCREEN_TOUCHIT213 is not set | ||
| 829 | CONFIG_INPUT_MISC=y | 887 | CONFIG_INPUT_MISC=y |
| 888 | # CONFIG_INPUT_ATI_REMOTE is not set | ||
| 889 | # CONFIG_INPUT_ATI_REMOTE2 is not set | ||
| 890 | # CONFIG_INPUT_KEYSPAN_REMOTE is not set | ||
| 891 | # CONFIG_INPUT_POWERMATE is not set | ||
| 892 | # CONFIG_INPUT_YEALINK is not set | ||
| 893 | # CONFIG_INPUT_CM109 is not set | ||
| 830 | CONFIG_INPUT_UINPUT=m | 894 | CONFIG_INPUT_UINPUT=m |
| 831 | 895 | ||
| 832 | # | 896 | # |
| @@ -839,8 +903,11 @@ CONFIG_INPUT_UINPUT=m | |||
| 839 | # Character devices | 903 | # Character devices |
| 840 | # | 904 | # |
| 841 | CONFIG_VT=y | 905 | CONFIG_VT=y |
| 906 | CONFIG_CONSOLE_TRANSLATIONS=y | ||
| 842 | CONFIG_VT_CONSOLE=y | 907 | CONFIG_VT_CONSOLE=y |
| 843 | CONFIG_HW_CONSOLE=y | 908 | CONFIG_HW_CONSOLE=y |
| 909 | # CONFIG_VT_HW_CONSOLE_BINDING is not set | ||
| 910 | CONFIG_DEVKMEM=y | ||
| 844 | # CONFIG_SERIAL_NONSTANDARD is not set | 911 | # CONFIG_SERIAL_NONSTANDARD is not set |
| 845 | 912 | ||
| 846 | # | 913 | # |
| @@ -849,6 +916,7 @@ CONFIG_HW_CONSOLE=y | |||
| 849 | CONFIG_SERIAL_8250=m | 916 | CONFIG_SERIAL_8250=m |
| 850 | CONFIG_SERIAL_8250_CS=m | 917 | CONFIG_SERIAL_8250_CS=m |
| 851 | CONFIG_SERIAL_8250_NR_UARTS=4 | 918 | CONFIG_SERIAL_8250_NR_UARTS=4 |
| 919 | CONFIG_SERIAL_8250_RUNTIME_UARTS=4 | ||
| 852 | # CONFIG_SERIAL_8250_EXTENDED is not set | 920 | # CONFIG_SERIAL_8250_EXTENDED is not set |
| 853 | 921 | ||
| 854 | # | 922 | # |
| @@ -860,101 +928,253 @@ CONFIG_SERIAL_CORE=y | |||
| 860 | CONFIG_SERIAL_CORE_CONSOLE=y | 928 | CONFIG_SERIAL_CORE_CONSOLE=y |
| 861 | CONFIG_UNIX98_PTYS=y | 929 | CONFIG_UNIX98_PTYS=y |
| 862 | # CONFIG_LEGACY_PTYS is not set | 930 | # CONFIG_LEGACY_PTYS is not set |
| 863 | |||
| 864 | # | ||
| 865 | # IPMI | ||
| 866 | # | ||
| 867 | # CONFIG_IPMI_HANDLER is not set | 931 | # CONFIG_IPMI_HANDLER is not set |
| 868 | 932 | CONFIG_HW_RANDOM=m | |
| 869 | # | ||
| 870 | # Watchdog Cards | ||
| 871 | # | ||
| 872 | # CONFIG_WATCHDOG is not set | ||
| 873 | # CONFIG_NVRAM is not set | 933 | # CONFIG_NVRAM is not set |
| 874 | # CONFIG_RTC is not set | ||
| 875 | # CONFIG_DTLK is not set | ||
| 876 | # CONFIG_R3964 is not set | 934 | # CONFIG_R3964 is not set |
| 877 | 935 | ||
| 878 | # | 936 | # |
| 879 | # Ftape, the floppy tape device driver | ||
| 880 | # | ||
| 881 | |||
| 882 | # | ||
| 883 | # PCMCIA character devices | 937 | # PCMCIA character devices |
| 884 | # | 938 | # |
| 885 | # CONFIG_SYNCLINK_CS is not set | 939 | # CONFIG_SYNCLINK_CS is not set |
| 886 | # CONFIG_CARDMAN_4000 is not set | 940 | # CONFIG_CARDMAN_4000 is not set |
| 887 | # CONFIG_CARDMAN_4040 is not set | 941 | # CONFIG_CARDMAN_4040 is not set |
| 942 | # CONFIG_IPWIRELESS is not set | ||
| 888 | # CONFIG_RAW_DRIVER is not set | 943 | # CONFIG_RAW_DRIVER is not set |
| 889 | |||
| 890 | # | ||
| 891 | # TPM devices | ||
| 892 | # | ||
| 893 | # CONFIG_TCG_TPM is not set | 944 | # CONFIG_TCG_TPM is not set |
| 894 | # CONFIG_TELCLOCK is not set | ||
| 895 | |||
| 896 | # | ||
| 897 | # I2C support | ||
| 898 | # | ||
| 899 | CONFIG_I2C=y | 945 | CONFIG_I2C=y |
| 946 | CONFIG_I2C_BOARDINFO=y | ||
| 900 | # CONFIG_I2C_CHARDEV is not set | 947 | # CONFIG_I2C_CHARDEV is not set |
| 948 | CONFIG_I2C_HELPER_AUTO=y | ||
| 901 | 949 | ||
| 902 | # | 950 | # |
| 903 | # I2C Algorithms | 951 | # I2C Hardware Bus support |
| 904 | # | 952 | # |
| 905 | # CONFIG_I2C_ALGOBIT is not set | ||
| 906 | # CONFIG_I2C_ALGOPCF is not set | ||
| 907 | # CONFIG_I2C_ALGOPCA is not set | ||
| 908 | 953 | ||
| 909 | # | 954 | # |
| 910 | # I2C Hardware Bus support | 955 | # I2C system bus drivers (mostly embedded / system-on-chip) |
| 911 | # | 956 | # |
| 957 | # CONFIG_I2C_GPIO is not set | ||
| 958 | # CONFIG_I2C_OCORES is not set | ||
| 912 | CONFIG_I2C_PXA=y | 959 | CONFIG_I2C_PXA=y |
| 913 | # CONFIG_I2C_PXA_SLAVE is not set | 960 | # CONFIG_I2C_PXA_SLAVE is not set |
| 961 | # CONFIG_I2C_SIMTEC is not set | ||
| 962 | |||
| 963 | # | ||
| 964 | # External I2C/SMBus adapter drivers | ||
| 965 | # | ||
| 914 | # CONFIG_I2C_PARPORT_LIGHT is not set | 966 | # CONFIG_I2C_PARPORT_LIGHT is not set |
| 967 | # CONFIG_I2C_TAOS_EVM is not set | ||
| 968 | # CONFIG_I2C_TINY_USB is not set | ||
| 969 | |||
| 970 | # | ||
| 971 | # Other I2C/SMBus bus drivers | ||
| 972 | # | ||
| 973 | # CONFIG_I2C_PCA_PLATFORM is not set | ||
| 915 | # CONFIG_I2C_STUB is not set | 974 | # CONFIG_I2C_STUB is not set |
| 916 | # CONFIG_I2C_PCA_ISA is not set | ||
| 917 | 975 | ||
| 918 | # | 976 | # |
| 919 | # Hardware Monitoring support | 977 | # Miscellaneous I2C Chip support |
| 978 | # | ||
| 979 | # CONFIG_DS1682 is not set | ||
| 980 | # CONFIG_AT24 is not set | ||
| 981 | # CONFIG_SENSORS_EEPROM is not set | ||
| 982 | # CONFIG_SENSORS_PCF8574 is not set | ||
| 983 | # CONFIG_PCF8575 is not set | ||
| 984 | # CONFIG_SENSORS_PCA9539 is not set | ||
| 985 | # CONFIG_SENSORS_PCF8591 is not set | ||
| 986 | # CONFIG_TPS65010 is not set | ||
| 987 | # CONFIG_SENSORS_MAX6875 is not set | ||
| 988 | # CONFIG_SENSORS_TSL2550 is not set | ||
| 989 | # CONFIG_I2C_DEBUG_CORE is not set | ||
| 990 | # CONFIG_I2C_DEBUG_ALGO is not set | ||
| 991 | # CONFIG_I2C_DEBUG_BUS is not set | ||
| 992 | # CONFIG_I2C_DEBUG_CHIP is not set | ||
| 993 | CONFIG_SPI=y | ||
| 994 | # CONFIG_SPI_DEBUG is not set | ||
| 995 | CONFIG_SPI_MASTER=y | ||
| 996 | |||
| 997 | # | ||
| 998 | # SPI Master Controller Drivers | ||
| 999 | # | ||
| 1000 | # CONFIG_SPI_BITBANG is not set | ||
| 1001 | CONFIG_SPI_PXA2XX=y | ||
| 1002 | |||
| 1003 | # | ||
| 1004 | # SPI Protocol Masters | ||
| 1005 | # | ||
| 1006 | # CONFIG_SPI_AT25 is not set | ||
| 1007 | # CONFIG_SPI_SPIDEV is not set | ||
| 1008 | # CONFIG_SPI_TLE62X0 is not set | ||
| 1009 | CONFIG_ARCH_REQUIRE_GPIOLIB=y | ||
| 1010 | CONFIG_GPIOLIB=y | ||
| 1011 | # CONFIG_DEBUG_GPIO is not set | ||
| 1012 | # CONFIG_GPIO_SYSFS is not set | ||
| 1013 | |||
| 1014 | # | ||
| 1015 | # I2C GPIO expanders: | ||
| 1016 | # | ||
| 1017 | # CONFIG_GPIO_MAX732X is not set | ||
| 1018 | # CONFIG_GPIO_PCA953X is not set | ||
| 1019 | # CONFIG_GPIO_PCF857X is not set | ||
| 1020 | |||
| 1021 | # | ||
| 1022 | # PCI GPIO expanders: | ||
| 1023 | # | ||
| 1024 | |||
| 1025 | # | ||
| 1026 | # SPI GPIO expanders: | ||
| 920 | # | 1027 | # |
| 1028 | # CONFIG_GPIO_MAX7301 is not set | ||
| 1029 | # CONFIG_GPIO_MCP23S08 is not set | ||
| 1030 | # CONFIG_W1 is not set | ||
| 1031 | # CONFIG_POWER_SUPPLY is not set | ||
| 921 | CONFIG_HWMON=y | 1032 | CONFIG_HWMON=y |
| 922 | # CONFIG_HWMON_VID is not set | 1033 | # CONFIG_HWMON_VID is not set |
| 1034 | # CONFIG_SENSORS_AD7414 is not set | ||
| 1035 | # CONFIG_SENSORS_AD7418 is not set | ||
| 1036 | # CONFIG_SENSORS_ADCXX is not set | ||
| 1037 | # CONFIG_SENSORS_ADM1021 is not set | ||
| 1038 | # CONFIG_SENSORS_ADM1025 is not set | ||
| 1039 | # CONFIG_SENSORS_ADM1026 is not set | ||
| 1040 | # CONFIG_SENSORS_ADM1029 is not set | ||
| 1041 | # CONFIG_SENSORS_ADM1031 is not set | ||
| 1042 | # CONFIG_SENSORS_ADM9240 is not set | ||
| 1043 | # CONFIG_SENSORS_ADT7470 is not set | ||
| 1044 | # CONFIG_SENSORS_ADT7473 is not set | ||
| 1045 | # CONFIG_SENSORS_ATXP1 is not set | ||
| 1046 | # CONFIG_SENSORS_DS1621 is not set | ||
| 1047 | # CONFIG_SENSORS_F71805F is not set | ||
| 1048 | # CONFIG_SENSORS_F71882FG is not set | ||
| 1049 | # CONFIG_SENSORS_F75375S is not set | ||
| 1050 | # CONFIG_SENSORS_GL518SM is not set | ||
| 1051 | # CONFIG_SENSORS_GL520SM is not set | ||
| 1052 | # CONFIG_SENSORS_IT87 is not set | ||
| 1053 | # CONFIG_SENSORS_LM63 is not set | ||
| 1054 | # CONFIG_SENSORS_LM70 is not set | ||
| 1055 | # CONFIG_SENSORS_LM75 is not set | ||
| 1056 | # CONFIG_SENSORS_LM77 is not set | ||
| 1057 | # CONFIG_SENSORS_LM78 is not set | ||
| 1058 | # CONFIG_SENSORS_LM80 is not set | ||
| 1059 | # CONFIG_SENSORS_LM83 is not set | ||
| 1060 | # CONFIG_SENSORS_LM85 is not set | ||
| 1061 | # CONFIG_SENSORS_LM87 is not set | ||
| 1062 | # CONFIG_SENSORS_LM90 is not set | ||
| 1063 | # CONFIG_SENSORS_LM92 is not set | ||
| 1064 | # CONFIG_SENSORS_LM93 is not set | ||
| 1065 | CONFIG_SENSORS_MAX1111=y | ||
| 1066 | # CONFIG_SENSORS_MAX1619 is not set | ||
| 1067 | # CONFIG_SENSORS_MAX6650 is not set | ||
| 1068 | # CONFIG_SENSORS_PC87360 is not set | ||
| 1069 | # CONFIG_SENSORS_PC87427 is not set | ||
| 1070 | # CONFIG_SENSORS_DME1737 is not set | ||
| 1071 | # CONFIG_SENSORS_SMSC47M1 is not set | ||
| 1072 | # CONFIG_SENSORS_SMSC47M192 is not set | ||
| 1073 | # CONFIG_SENSORS_SMSC47B397 is not set | ||
| 1074 | # CONFIG_SENSORS_ADS7828 is not set | ||
| 1075 | # CONFIG_SENSORS_THMC50 is not set | ||
| 1076 | # CONFIG_SENSORS_VT1211 is not set | ||
| 1077 | # CONFIG_SENSORS_W83781D is not set | ||
| 1078 | # CONFIG_SENSORS_W83791D is not set | ||
| 1079 | # CONFIG_SENSORS_W83792D is not set | ||
| 1080 | # CONFIG_SENSORS_W83793 is not set | ||
| 1081 | # CONFIG_SENSORS_W83L785TS is not set | ||
| 1082 | # CONFIG_SENSORS_W83L786NG is not set | ||
| 1083 | # CONFIG_SENSORS_W83627HF is not set | ||
| 1084 | # CONFIG_SENSORS_W83627EHF is not set | ||
| 923 | # CONFIG_HWMON_DEBUG_CHIP is not set | 1085 | # CONFIG_HWMON_DEBUG_CHIP is not set |
| 1086 | # CONFIG_THERMAL is not set | ||
| 1087 | # CONFIG_THERMAL_HWMON is not set | ||
| 1088 | # CONFIG_WATCHDOG is not set | ||
| 924 | 1089 | ||
| 925 | # | 1090 | # |
| 926 | # Misc devices | 1091 | # Sonics Silicon Backplane |
| 927 | # | 1092 | # |
| 1093 | CONFIG_SSB_POSSIBLE=y | ||
| 1094 | # CONFIG_SSB is not set | ||
| 928 | 1095 | ||
| 929 | # | 1096 | # |
| 930 | # Multimedia Capabilities Port drivers | 1097 | # Multifunction device drivers |
| 931 | # | 1098 | # |
| 1099 | # CONFIG_MFD_CORE is not set | ||
| 1100 | # CONFIG_MFD_SM501 is not set | ||
| 1101 | # CONFIG_MFD_ASIC3 is not set | ||
| 1102 | # CONFIG_HTC_EGPIO is not set | ||
| 1103 | # CONFIG_HTC_PASIC3 is not set | ||
| 1104 | # CONFIG_UCB1400_CORE is not set | ||
| 1105 | # CONFIG_MFD_TMIO is not set | ||
| 1106 | # CONFIG_MFD_T7L66XB is not set | ||
| 1107 | # CONFIG_MFD_TC6387XB is not set | ||
| 1108 | # CONFIG_MFD_TC6393XB is not set | ||
| 1109 | # CONFIG_MFD_WM8400 is not set | ||
| 1110 | # CONFIG_MFD_WM8350_I2C is not set | ||
| 932 | 1111 | ||
| 933 | # | 1112 | # |
| 934 | # Multimedia devices | 1113 | # Multimedia devices |
| 935 | # | 1114 | # |
| 1115 | |||
| 1116 | # | ||
| 1117 | # Multimedia core support | ||
| 1118 | # | ||
| 936 | # CONFIG_VIDEO_DEV is not set | 1119 | # CONFIG_VIDEO_DEV is not set |
| 1120 | # CONFIG_DVB_CORE is not set | ||
| 1121 | # CONFIG_VIDEO_MEDIA is not set | ||
| 937 | 1122 | ||
| 938 | # | 1123 | # |
| 939 | # Digital Video Broadcasting Devices | 1124 | # Multimedia drivers |
| 940 | # | 1125 | # |
| 941 | # CONFIG_DVB is not set | 1126 | # CONFIG_DAB is not set |
| 942 | 1127 | ||
| 943 | # | 1128 | # |
| 944 | # Graphics support | 1129 | # Graphics support |
| 945 | # | 1130 | # |
| 1131 | # CONFIG_VGASTATE is not set | ||
| 1132 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
| 946 | CONFIG_FB=y | 1133 | CONFIG_FB=y |
| 1134 | # CONFIG_FIRMWARE_EDID is not set | ||
| 1135 | # CONFIG_FB_DDC is not set | ||
| 1136 | # CONFIG_FB_BOOT_VESA_SUPPORT is not set | ||
| 947 | CONFIG_FB_CFB_FILLRECT=y | 1137 | CONFIG_FB_CFB_FILLRECT=y |
| 948 | CONFIG_FB_CFB_COPYAREA=y | 1138 | CONFIG_FB_CFB_COPYAREA=y |
| 949 | CONFIG_FB_CFB_IMAGEBLIT=y | 1139 | CONFIG_FB_CFB_IMAGEBLIT=y |
| 1140 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
| 1141 | # CONFIG_FB_SYS_FILLRECT is not set | ||
| 1142 | # CONFIG_FB_SYS_COPYAREA is not set | ||
| 1143 | # CONFIG_FB_SYS_IMAGEBLIT is not set | ||
| 1144 | # CONFIG_FB_FOREIGN_ENDIAN is not set | ||
| 1145 | # CONFIG_FB_SYS_FOPS is not set | ||
| 1146 | # CONFIG_FB_SVGALIB is not set | ||
| 950 | # CONFIG_FB_MACMODES is not set | 1147 | # CONFIG_FB_MACMODES is not set |
| 1148 | # CONFIG_FB_BACKLIGHT is not set | ||
| 951 | # CONFIG_FB_MODE_HELPERS is not set | 1149 | # CONFIG_FB_MODE_HELPERS is not set |
| 952 | # CONFIG_FB_TILEBLITTING is not set | 1150 | # CONFIG_FB_TILEBLITTING is not set |
| 1151 | |||
| 1152 | # | ||
| 1153 | # Frame buffer hardware drivers | ||
| 1154 | # | ||
| 953 | # CONFIG_FB_S1D13XXX is not set | 1155 | # CONFIG_FB_S1D13XXX is not set |
| 954 | CONFIG_FB_PXA=y | 1156 | CONFIG_FB_PXA=y |
| 1157 | # CONFIG_FB_PXA_SMARTPANEL is not set | ||
| 955 | # CONFIG_FB_PXA_PARAMETERS is not set | 1158 | # CONFIG_FB_PXA_PARAMETERS is not set |
| 1159 | # CONFIG_FB_MBX is not set | ||
| 956 | # CONFIG_FB_W100 is not set | 1160 | # CONFIG_FB_W100 is not set |
| 957 | # CONFIG_FB_VIRTUAL is not set | 1161 | # CONFIG_FB_VIRTUAL is not set |
| 1162 | # CONFIG_FB_METRONOME is not set | ||
| 1163 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | ||
| 1164 | CONFIG_LCD_CLASS_DEVICE=y | ||
| 1165 | CONFIG_LCD_CORGI=y | ||
| 1166 | # CONFIG_LCD_LTV350QV is not set | ||
| 1167 | # CONFIG_LCD_ILI9320 is not set | ||
| 1168 | # CONFIG_LCD_TDO24M is not set | ||
| 1169 | # CONFIG_LCD_VGG2432A4 is not set | ||
| 1170 | # CONFIG_LCD_PLATFORM is not set | ||
| 1171 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | ||
| 1172 | # CONFIG_BACKLIGHT_CORGI is not set | ||
| 1173 | |||
| 1174 | # | ||
| 1175 | # Display device support | ||
| 1176 | # | ||
| 1177 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 958 | 1178 | ||
| 959 | # | 1179 | # |
| 960 | # Console display driver support | 1180 | # Console display driver support |
| @@ -962,6 +1182,7 @@ CONFIG_FB_PXA=y | |||
| 962 | # CONFIG_VGA_CONSOLE is not set | 1182 | # CONFIG_VGA_CONSOLE is not set |
| 963 | CONFIG_DUMMY_CONSOLE=y | 1183 | CONFIG_DUMMY_CONSOLE=y |
| 964 | CONFIG_FRAMEBUFFER_CONSOLE=y | 1184 | CONFIG_FRAMEBUFFER_CONSOLE=y |
| 1185 | # CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY is not set | ||
| 965 | CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y | 1186 | CONFIG_FRAMEBUFFER_CONSOLE_ROTATION=y |
| 966 | CONFIG_FONTS=y | 1187 | CONFIG_FONTS=y |
| 967 | CONFIG_FONT_8x8=y | 1188 | CONFIG_FONT_8x8=y |
| @@ -974,55 +1195,96 @@ CONFIG_FONT_8x16=y | |||
| 974 | # CONFIG_FONT_SUN8x16 is not set | 1195 | # CONFIG_FONT_SUN8x16 is not set |
| 975 | # CONFIG_FONT_SUN12x22 is not set | 1196 | # CONFIG_FONT_SUN12x22 is not set |
| 976 | # CONFIG_FONT_10x18 is not set | 1197 | # CONFIG_FONT_10x18 is not set |
| 1198 | # CONFIG_LOGO is not set | ||
| 1199 | # CONFIG_SOUND is not set | ||
| 1200 | CONFIG_HID_SUPPORT=y | ||
| 1201 | CONFIG_HID=y | ||
| 1202 | # CONFIG_HID_DEBUG is not set | ||
| 1203 | # CONFIG_HIDRAW is not set | ||
| 977 | 1204 | ||
| 978 | # | 1205 | # |
| 979 | # Logo configuration | 1206 | # USB Input Devices |
| 980 | # | 1207 | # |
| 981 | # CONFIG_LOGO is not set | 1208 | CONFIG_USB_HID=m |
| 982 | CONFIG_BACKLIGHT_LCD_SUPPORT=y | 1209 | # CONFIG_HID_PID is not set |
| 983 | CONFIG_BACKLIGHT_CLASS_DEVICE=y | 1210 | # CONFIG_USB_HIDDEV is not set |
| 984 | CONFIG_BACKLIGHT_DEVICE=y | ||
| 985 | CONFIG_LCD_CLASS_DEVICE=y | ||
| 986 | CONFIG_LCD_DEVICE=y | ||
| 987 | CONFIG_BACKLIGHT_CORGI=y | ||
| 988 | 1211 | ||
| 989 | # | 1212 | # |
| 990 | # Sound | 1213 | # USB HID Boot Protocol drivers |
| 991 | # | 1214 | # |
| 992 | # CONFIG_SOUND is not set | 1215 | CONFIG_USB_KBD=m |
| 1216 | CONFIG_USB_MOUSE=m | ||
| 993 | 1217 | ||
| 994 | # | 1218 | # |
| 995 | # USB support | 1219 | # Special HID drivers |
| 996 | # | 1220 | # |
| 1221 | CONFIG_HID_COMPAT=y | ||
| 1222 | CONFIG_HID_A4TECH=m | ||
| 1223 | CONFIG_HID_APPLE=m | ||
| 1224 | CONFIG_HID_BELKIN=m | ||
| 1225 | CONFIG_HID_BRIGHT=m | ||
| 1226 | CONFIG_HID_CHERRY=m | ||
| 1227 | CONFIG_HID_CHICONY=m | ||
| 1228 | CONFIG_HID_CYPRESS=m | ||
| 1229 | CONFIG_HID_DELL=m | ||
| 1230 | CONFIG_HID_EZKEY=m | ||
| 1231 | CONFIG_HID_GYRATION=m | ||
| 1232 | CONFIG_HID_LOGITECH=m | ||
| 1233 | # CONFIG_LOGITECH_FF is not set | ||
| 1234 | # CONFIG_LOGIRUMBLEPAD2_FF is not set | ||
| 1235 | CONFIG_HID_MICROSOFT=m | ||
| 1236 | CONFIG_HID_MONTEREY=m | ||
| 1237 | CONFIG_HID_PANTHERLORD=m | ||
| 1238 | # CONFIG_PANTHERLORD_FF is not set | ||
| 1239 | CONFIG_HID_PETALYNX=m | ||
| 1240 | CONFIG_HID_SAMSUNG=m | ||
| 1241 | CONFIG_HID_SONY=m | ||
| 1242 | CONFIG_HID_SUNPLUS=m | ||
| 1243 | CONFIG_THRUSTMASTER_FF=m | ||
| 1244 | CONFIG_ZEROPLUS_FF=m | ||
| 1245 | CONFIG_USB_SUPPORT=y | ||
| 997 | CONFIG_USB_ARCH_HAS_HCD=y | 1246 | CONFIG_USB_ARCH_HAS_HCD=y |
| 998 | CONFIG_USB_ARCH_HAS_OHCI=y | 1247 | CONFIG_USB_ARCH_HAS_OHCI=y |
| 1248 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
| 999 | CONFIG_USB=m | 1249 | CONFIG_USB=m |
| 1000 | # CONFIG_USB_DEBUG is not set | 1250 | # CONFIG_USB_DEBUG is not set |
| 1251 | # CONFIG_USB_ANNOUNCE_NEW_DEVICES is not set | ||
| 1001 | 1252 | ||
| 1002 | # | 1253 | # |
| 1003 | # Miscellaneous USB options | 1254 | # Miscellaneous USB options |
| 1004 | # | 1255 | # |
| 1005 | CONFIG_USB_DEVICEFS=y | 1256 | CONFIG_USB_DEVICEFS=y |
| 1006 | # CONFIG_USB_BANDWIDTH is not set | 1257 | CONFIG_USB_DEVICE_CLASS=y |
| 1007 | # CONFIG_USB_DYNAMIC_MINORS is not set | 1258 | # CONFIG_USB_DYNAMIC_MINORS is not set |
| 1008 | # CONFIG_USB_SUSPEND is not set | 1259 | # CONFIG_USB_SUSPEND is not set |
| 1009 | # CONFIG_USB_OTG is not set | 1260 | # CONFIG_USB_OTG is not set |
| 1261 | # CONFIG_USB_OTG_WHITELIST is not set | ||
| 1262 | # CONFIG_USB_OTG_BLACKLIST_HUB is not set | ||
| 1263 | CONFIG_USB_MON=y | ||
| 1010 | 1264 | ||
| 1011 | # | 1265 | # |
| 1012 | # USB Host Controller Drivers | 1266 | # USB Host Controller Drivers |
| 1013 | # | 1267 | # |
| 1268 | # CONFIG_USB_C67X00_HCD is not set | ||
| 1014 | # CONFIG_USB_ISP116X_HCD is not set | 1269 | # CONFIG_USB_ISP116X_HCD is not set |
| 1270 | # CONFIG_USB_ISP1760_HCD is not set | ||
| 1015 | CONFIG_USB_OHCI_HCD=m | 1271 | CONFIG_USB_OHCI_HCD=m |
| 1016 | # CONFIG_USB_OHCI_BIG_ENDIAN is not set | 1272 | # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set |
| 1273 | # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set | ||
| 1017 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y | 1274 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y |
| 1018 | CONFIG_USB_SL811_HCD=m | 1275 | CONFIG_USB_SL811_HCD=m |
| 1019 | CONFIG_USB_SL811_CS=m | 1276 | CONFIG_USB_SL811_CS=m |
| 1277 | # CONFIG_USB_R8A66597_HCD is not set | ||
| 1278 | # CONFIG_USB_MUSB_HDRC is not set | ||
| 1279 | # CONFIG_USB_GADGET_MUSB_HDRC is not set | ||
| 1020 | 1280 | ||
| 1021 | # | 1281 | # |
| 1022 | # USB Device Class drivers | 1282 | # USB Device Class drivers |
| 1023 | # | 1283 | # |
| 1024 | CONFIG_USB_ACM=m | 1284 | CONFIG_USB_ACM=m |
| 1025 | CONFIG_USB_PRINTER=m | 1285 | CONFIG_USB_PRINTER=m |
| 1286 | # CONFIG_USB_WDM is not set | ||
| 1287 | # CONFIG_USB_TMC is not set | ||
| 1026 | 1288 | ||
| 1027 | # | 1289 | # |
| 1028 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1290 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
| @@ -1041,33 +1303,11 @@ CONFIG_USB_STORAGE=m | |||
| 1041 | # CONFIG_USB_STORAGE_SDDR09 is not set | 1303 | # CONFIG_USB_STORAGE_SDDR09 is not set |
| 1042 | # CONFIG_USB_STORAGE_SDDR55 is not set | 1304 | # CONFIG_USB_STORAGE_SDDR55 is not set |
| 1043 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | 1305 | # CONFIG_USB_STORAGE_JUMPSHOT is not set |
| 1044 | 1306 | # CONFIG_USB_STORAGE_ALAUDA is not set | |
| 1045 | # | 1307 | # CONFIG_USB_STORAGE_ONETOUCH is not set |
| 1046 | # USB Input Devices | 1308 | # CONFIG_USB_STORAGE_KARMA is not set |
| 1047 | # | 1309 | # CONFIG_USB_STORAGE_CYPRESS_ATACB is not set |
| 1048 | CONFIG_USB_HID=m | 1310 | # CONFIG_USB_LIBUSUAL is not set |
| 1049 | CONFIG_USB_HIDINPUT=y | ||
| 1050 | # CONFIG_HID_FF is not set | ||
| 1051 | # CONFIG_USB_HIDDEV is not set | ||
| 1052 | |||
| 1053 | # | ||
| 1054 | # USB HID Boot Protocol drivers | ||
| 1055 | # | ||
| 1056 | CONFIG_USB_KBD=m | ||
| 1057 | CONFIG_USB_MOUSE=m | ||
| 1058 | CONFIG_USB_AIPTEK=m | ||
| 1059 | CONFIG_USB_WACOM=m | ||
| 1060 | # CONFIG_USB_ACECAD is not set | ||
| 1061 | CONFIG_USB_KBTAB=m | ||
| 1062 | CONFIG_USB_POWERMATE=m | ||
| 1063 | CONFIG_USB_MTOUCH=m | ||
| 1064 | # CONFIG_USB_ITMTOUCH is not set | ||
| 1065 | CONFIG_USB_EGALAX=m | ||
| 1066 | # CONFIG_USB_YEALINK is not set | ||
| 1067 | CONFIG_USB_XPAD=m | ||
| 1068 | CONFIG_USB_ATI_REMOTE=m | ||
| 1069 | # CONFIG_USB_KEYSPAN_REMOTE is not set | ||
| 1070 | # CONFIG_USB_APPLETOUCH is not set | ||
| 1071 | 1311 | ||
| 1072 | # | 1312 | # |
| 1073 | # USB Imaging devices | 1313 | # USB Imaging devices |
| @@ -1076,51 +1316,22 @@ CONFIG_USB_MDC800=m | |||
| 1076 | CONFIG_USB_MICROTEK=m | 1316 | CONFIG_USB_MICROTEK=m |
| 1077 | 1317 | ||
| 1078 | # | 1318 | # |
| 1079 | # USB Multimedia devices | ||
| 1080 | # | ||
| 1081 | CONFIG_USB_DABUSB=m | ||
| 1082 | |||
| 1083 | # | ||
| 1084 | # Video4Linux support is needed for USB Multimedia device support | ||
| 1085 | # | ||
| 1086 | |||
| 1087 | # | ||
| 1088 | # USB Network Adapters | ||
| 1089 | # | ||
| 1090 | CONFIG_USB_CATC=m | ||
| 1091 | CONFIG_USB_KAWETH=m | ||
| 1092 | CONFIG_USB_PEGASUS=m | ||
| 1093 | CONFIG_USB_RTL8150=m | ||
| 1094 | CONFIG_USB_USBNET=m | ||
| 1095 | CONFIG_USB_NET_AX8817X=m | ||
| 1096 | CONFIG_USB_NET_CDCETHER=m | ||
| 1097 | # CONFIG_USB_NET_GL620A is not set | ||
| 1098 | CONFIG_USB_NET_NET1080=m | ||
| 1099 | # CONFIG_USB_NET_PLUSB is not set | ||
| 1100 | # CONFIG_USB_NET_RNDIS_HOST is not set | ||
| 1101 | # CONFIG_USB_NET_CDC_SUBSET is not set | ||
| 1102 | CONFIG_USB_NET_ZAURUS=m | ||
| 1103 | # CONFIG_USB_ZD1201 is not set | ||
| 1104 | CONFIG_USB_MON=y | ||
| 1105 | |||
| 1106 | # | ||
| 1107 | # USB port drivers | 1319 | # USB port drivers |
| 1108 | # | 1320 | # |
| 1109 | |||
| 1110 | # | ||
| 1111 | # USB Serial Converter support | ||
| 1112 | # | ||
| 1113 | CONFIG_USB_SERIAL=m | 1321 | CONFIG_USB_SERIAL=m |
| 1322 | CONFIG_USB_EZUSB=y | ||
| 1114 | CONFIG_USB_SERIAL_GENERIC=y | 1323 | CONFIG_USB_SERIAL_GENERIC=y |
| 1115 | # CONFIG_USB_SERIAL_AIRPRIME is not set | 1324 | # CONFIG_USB_SERIAL_AIRCABLE is not set |
| 1116 | # CONFIG_USB_SERIAL_ANYDATA is not set | 1325 | # CONFIG_USB_SERIAL_ARK3116 is not set |
| 1117 | CONFIG_USB_SERIAL_BELKIN=m | 1326 | CONFIG_USB_SERIAL_BELKIN=m |
| 1327 | # CONFIG_USB_SERIAL_CH341 is not set | ||
| 1118 | # CONFIG_USB_SERIAL_WHITEHEAT is not set | 1328 | # CONFIG_USB_SERIAL_WHITEHEAT is not set |
| 1119 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m | 1329 | CONFIG_USB_SERIAL_DIGI_ACCELEPORT=m |
| 1120 | # CONFIG_USB_SERIAL_CP2101 is not set | 1330 | # CONFIG_USB_SERIAL_CP2101 is not set |
| 1121 | CONFIG_USB_SERIAL_CYPRESS_M8=m | 1331 | CONFIG_USB_SERIAL_CYPRESS_M8=m |
| 1122 | CONFIG_USB_SERIAL_EMPEG=m | 1332 | CONFIG_USB_SERIAL_EMPEG=m |
| 1123 | CONFIG_USB_SERIAL_FTDI_SIO=m | 1333 | CONFIG_USB_SERIAL_FTDI_SIO=m |
| 1334 | # CONFIG_USB_SERIAL_FUNSOFT is not set | ||
| 1124 | CONFIG_USB_SERIAL_VISOR=m | 1335 | CONFIG_USB_SERIAL_VISOR=m |
| 1125 | CONFIG_USB_SERIAL_IPAQ=m | 1336 | CONFIG_USB_SERIAL_IPAQ=m |
| 1126 | CONFIG_USB_SERIAL_IR=m | 1337 | CONFIG_USB_SERIAL_IR=m |
| @@ -1128,6 +1339,7 @@ CONFIG_USB_SERIAL_EDGEPORT=m | |||
| 1128 | CONFIG_USB_SERIAL_EDGEPORT_TI=m | 1339 | CONFIG_USB_SERIAL_EDGEPORT_TI=m |
| 1129 | CONFIG_USB_SERIAL_GARMIN=m | 1340 | CONFIG_USB_SERIAL_GARMIN=m |
| 1130 | CONFIG_USB_SERIAL_IPW=m | 1341 | CONFIG_USB_SERIAL_IPW=m |
| 1342 | # CONFIG_USB_SERIAL_IUU is not set | ||
| 1131 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m | 1343 | CONFIG_USB_SERIAL_KEYSPAN_PDA=m |
| 1132 | CONFIG_USB_SERIAL_KEYSPAN=m | 1344 | CONFIG_USB_SERIAL_KEYSPAN=m |
| 1133 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set | 1345 | # CONFIG_USB_SERIAL_KEYSPAN_MPR is not set |
| @@ -1145,49 +1357,66 @@ CONFIG_USB_SERIAL_KEYSPAN=m | |||
| 1145 | CONFIG_USB_SERIAL_KLSI=m | 1357 | CONFIG_USB_SERIAL_KLSI=m |
| 1146 | CONFIG_USB_SERIAL_KOBIL_SCT=m | 1358 | CONFIG_USB_SERIAL_KOBIL_SCT=m |
| 1147 | CONFIG_USB_SERIAL_MCT_U232=m | 1359 | CONFIG_USB_SERIAL_MCT_U232=m |
| 1360 | # CONFIG_USB_SERIAL_MOS7720 is not set | ||
| 1361 | # CONFIG_USB_SERIAL_MOS7840 is not set | ||
| 1362 | # CONFIG_USB_SERIAL_MOTOROLA is not set | ||
| 1363 | # CONFIG_USB_SERIAL_NAVMAN is not set | ||
| 1148 | CONFIG_USB_SERIAL_PL2303=m | 1364 | CONFIG_USB_SERIAL_PL2303=m |
| 1365 | # CONFIG_USB_SERIAL_OTI6858 is not set | ||
| 1366 | # CONFIG_USB_SERIAL_SPCP8X5 is not set | ||
| 1149 | # CONFIG_USB_SERIAL_HP4X is not set | 1367 | # CONFIG_USB_SERIAL_HP4X is not set |
| 1150 | CONFIG_USB_SERIAL_SAFE=m | 1368 | CONFIG_USB_SERIAL_SAFE=m |
| 1151 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set | 1369 | # CONFIG_USB_SERIAL_SAFE_PADDED is not set |
| 1370 | # CONFIG_USB_SERIAL_SIERRAWIRELESS is not set | ||
| 1152 | CONFIG_USB_SERIAL_TI=m | 1371 | CONFIG_USB_SERIAL_TI=m |
| 1153 | CONFIG_USB_SERIAL_CYBERJACK=m | 1372 | CONFIG_USB_SERIAL_CYBERJACK=m |
| 1154 | CONFIG_USB_SERIAL_XIRCOM=m | 1373 | CONFIG_USB_SERIAL_XIRCOM=m |
| 1155 | # CONFIG_USB_SERIAL_OPTION is not set | 1374 | # CONFIG_USB_SERIAL_OPTION is not set |
| 1156 | CONFIG_USB_SERIAL_OMNINET=m | 1375 | CONFIG_USB_SERIAL_OMNINET=m |
| 1157 | CONFIG_USB_EZUSB=y | 1376 | # CONFIG_USB_SERIAL_DEBUG is not set |
| 1158 | 1377 | ||
| 1159 | # | 1378 | # |
| 1160 | # USB Miscellaneous drivers | 1379 | # USB Miscellaneous drivers |
| 1161 | # | 1380 | # |
| 1162 | CONFIG_USB_EMI62=m | 1381 | CONFIG_USB_EMI62=m |
| 1163 | CONFIG_USB_EMI26=m | 1382 | CONFIG_USB_EMI26=m |
| 1164 | CONFIG_USB_AUERSWALD=m | 1383 | # CONFIG_USB_ADUTUX is not set |
| 1384 | # CONFIG_USB_SEVSEG is not set | ||
| 1165 | CONFIG_USB_RIO500=m | 1385 | CONFIG_USB_RIO500=m |
| 1166 | CONFIG_USB_LEGOTOWER=m | 1386 | CONFIG_USB_LEGOTOWER=m |
| 1167 | CONFIG_USB_LCD=m | 1387 | CONFIG_USB_LCD=m |
| 1388 | # CONFIG_USB_BERRY_CHARGE is not set | ||
| 1168 | CONFIG_USB_LED=m | 1389 | CONFIG_USB_LED=m |
| 1390 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
| 1169 | CONFIG_USB_CYTHERM=m | 1391 | CONFIG_USB_CYTHERM=m |
| 1170 | CONFIG_USB_PHIDGETKIT=m | 1392 | # CONFIG_USB_PHIDGET is not set |
| 1171 | CONFIG_USB_PHIDGETSERVO=m | ||
| 1172 | CONFIG_USB_IDMOUSE=m | 1393 | CONFIG_USB_IDMOUSE=m |
| 1394 | # CONFIG_USB_FTDI_ELAN is not set | ||
| 1395 | # CONFIG_USB_APPLEDISPLAY is not set | ||
| 1173 | # CONFIG_USB_LD is not set | 1396 | # CONFIG_USB_LD is not set |
| 1397 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
| 1398 | # CONFIG_USB_IOWARRIOR is not set | ||
| 1174 | # CONFIG_USB_TEST is not set | 1399 | # CONFIG_USB_TEST is not set |
| 1175 | 1400 | # CONFIG_USB_ISIGHTFW is not set | |
| 1176 | # | 1401 | # CONFIG_USB_VST is not set |
| 1177 | # USB DSL modem support | ||
| 1178 | # | ||
| 1179 | |||
| 1180 | # | ||
| 1181 | # USB Gadget Support | ||
| 1182 | # | ||
| 1183 | CONFIG_USB_GADGET=m | 1402 | CONFIG_USB_GADGET=m |
| 1403 | # CONFIG_USB_GADGET_DEBUG is not set | ||
| 1184 | # CONFIG_USB_GADGET_DEBUG_FILES is not set | 1404 | # CONFIG_USB_GADGET_DEBUG_FILES is not set |
| 1405 | CONFIG_USB_GADGET_VBUS_DRAW=2 | ||
| 1185 | CONFIG_USB_GADGET_SELECTED=y | 1406 | CONFIG_USB_GADGET_SELECTED=y |
| 1186 | # CONFIG_USB_GADGET_NET2280 is not set | 1407 | # CONFIG_USB_GADGET_AT91 is not set |
| 1187 | # CONFIG_USB_GADGET_PXA2XX is not set | 1408 | # CONFIG_USB_GADGET_ATMEL_USBA is not set |
| 1188 | # CONFIG_USB_GADGET_GOKU is not set | 1409 | # CONFIG_USB_GADGET_FSL_USB2 is not set |
| 1189 | # CONFIG_USB_GADGET_LH7A40X is not set | 1410 | # CONFIG_USB_GADGET_LH7A40X is not set |
| 1190 | # CONFIG_USB_GADGET_OMAP is not set | 1411 | # CONFIG_USB_GADGET_OMAP is not set |
| 1412 | # CONFIG_USB_GADGET_PXA25X is not set | ||
| 1413 | # CONFIG_USB_GADGET_PXA27X is not set | ||
| 1414 | # CONFIG_USB_GADGET_S3C2410 is not set | ||
| 1415 | # CONFIG_USB_GADGET_M66592 is not set | ||
| 1416 | # CONFIG_USB_GADGET_AMD5536UDC is not set | ||
| 1417 | # CONFIG_USB_GADGET_FSL_QE is not set | ||
| 1418 | # CONFIG_USB_GADGET_NET2280 is not set | ||
| 1419 | # CONFIG_USB_GADGET_GOKU is not set | ||
| 1191 | CONFIG_USB_GADGET_DUMMY_HCD=y | 1420 | CONFIG_USB_GADGET_DUMMY_HCD=y |
| 1192 | CONFIG_USB_DUMMY_HCD=m | 1421 | CONFIG_USB_DUMMY_HCD=m |
| 1193 | CONFIG_USB_GADGET_DUALSPEED=y | 1422 | CONFIG_USB_GADGET_DUALSPEED=y |
| @@ -1198,15 +1427,42 @@ CONFIG_USB_GADGETFS=m | |||
| 1198 | CONFIG_USB_FILE_STORAGE=m | 1427 | CONFIG_USB_FILE_STORAGE=m |
| 1199 | # CONFIG_USB_FILE_STORAGE_TEST is not set | 1428 | # CONFIG_USB_FILE_STORAGE_TEST is not set |
| 1200 | CONFIG_USB_G_SERIAL=m | 1429 | CONFIG_USB_G_SERIAL=m |
| 1430 | # CONFIG_USB_MIDI_GADGET is not set | ||
| 1431 | # CONFIG_USB_G_PRINTER is not set | ||
| 1432 | # CONFIG_USB_CDC_COMPOSITE is not set | ||
| 1433 | CONFIG_MMC=y | ||
| 1434 | # CONFIG_MMC_DEBUG is not set | ||
| 1435 | # CONFIG_MMC_UNSAFE_RESUME is not set | ||
| 1201 | 1436 | ||
| 1202 | # | 1437 | # |
| 1203 | # MMC/SD Card support | 1438 | # MMC/SD/SDIO Card Drivers |
| 1204 | # | 1439 | # |
| 1205 | CONFIG_MMC=y | ||
| 1206 | # CONFIG_MMC_DEBUG is not set | ||
| 1207 | CONFIG_MMC_BLOCK=y | 1440 | CONFIG_MMC_BLOCK=y |
| 1441 | CONFIG_MMC_BLOCK_BOUNCE=y | ||
| 1442 | # CONFIG_SDIO_UART is not set | ||
| 1443 | # CONFIG_MMC_TEST is not set | ||
| 1444 | |||
| 1445 | # | ||
| 1446 | # MMC/SD/SDIO Host Controller Drivers | ||
| 1447 | # | ||
| 1208 | CONFIG_MMC_PXA=y | 1448 | CONFIG_MMC_PXA=y |
| 1209 | # CONFIG_MMC_WBSD is not set | 1449 | # CONFIG_MMC_SDHCI is not set |
| 1450 | # CONFIG_MMC_SPI is not set | ||
| 1451 | # CONFIG_MEMSTICK is not set | ||
| 1452 | # CONFIG_ACCESSIBILITY is not set | ||
| 1453 | # CONFIG_NEW_LEDS is not set | ||
| 1454 | CONFIG_RTC_LIB=y | ||
| 1455 | # CONFIG_RTC_CLASS is not set | ||
| 1456 | # CONFIG_DMADEVICES is not set | ||
| 1457 | |||
| 1458 | # | ||
| 1459 | # Voltage and Current regulators | ||
| 1460 | # | ||
| 1461 | # CONFIG_REGULATOR is not set | ||
| 1462 | # CONFIG_REGULATOR_FIXED_VOLTAGE is not set | ||
| 1463 | # CONFIG_REGULATOR_VIRTUAL_CONSUMER is not set | ||
| 1464 | # CONFIG_REGULATOR_BQ24022 is not set | ||
| 1465 | # CONFIG_UIO is not set | ||
| 1210 | 1466 | ||
| 1211 | # | 1467 | # |
| 1212 | # File systems | 1468 | # File systems |
| @@ -1218,18 +1474,19 @@ CONFIG_EXT2_FS_SECURITY=y | |||
| 1218 | # CONFIG_EXT2_FS_XIP is not set | 1474 | # CONFIG_EXT2_FS_XIP is not set |
| 1219 | CONFIG_EXT3_FS=y | 1475 | CONFIG_EXT3_FS=y |
| 1220 | # CONFIG_EXT3_FS_XATTR is not set | 1476 | # CONFIG_EXT3_FS_XATTR is not set |
| 1477 | # CONFIG_EXT4_FS is not set | ||
| 1221 | CONFIG_JBD=y | 1478 | CONFIG_JBD=y |
| 1222 | # CONFIG_JBD_DEBUG is not set | ||
| 1223 | CONFIG_FS_MBCACHE=y | 1479 | CONFIG_FS_MBCACHE=y |
| 1224 | # CONFIG_REISERFS_FS is not set | 1480 | # CONFIG_REISERFS_FS is not set |
| 1225 | # CONFIG_JFS_FS is not set | 1481 | # CONFIG_JFS_FS is not set |
| 1226 | CONFIG_FS_POSIX_ACL=y | 1482 | CONFIG_FS_POSIX_ACL=y |
| 1483 | CONFIG_FILE_LOCKING=y | ||
| 1227 | # CONFIG_XFS_FS is not set | 1484 | # CONFIG_XFS_FS is not set |
| 1228 | # CONFIG_MINIX_FS is not set | 1485 | # CONFIG_OCFS2_FS is not set |
| 1229 | # CONFIG_ROMFS_FS is not set | 1486 | CONFIG_DNOTIFY=y |
| 1230 | CONFIG_INOTIFY=y | 1487 | CONFIG_INOTIFY=y |
| 1488 | CONFIG_INOTIFY_USER=y | ||
| 1231 | # CONFIG_QUOTA is not set | 1489 | # CONFIG_QUOTA is not set |
| 1232 | CONFIG_DNOTIFY=y | ||
| 1233 | # CONFIG_AUTOFS_FS is not set | 1490 | # CONFIG_AUTOFS_FS is not set |
| 1234 | # CONFIG_AUTOFS4_FS is not set | 1491 | # CONFIG_AUTOFS4_FS is not set |
| 1235 | # CONFIG_FUSE_FS is not set | 1492 | # CONFIG_FUSE_FS is not set |
| @@ -1254,11 +1511,13 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" | |||
| 1254 | # Pseudo filesystems | 1511 | # Pseudo filesystems |
| 1255 | # | 1512 | # |
| 1256 | CONFIG_PROC_FS=y | 1513 | CONFIG_PROC_FS=y |
| 1514 | CONFIG_PROC_SYSCTL=y | ||
| 1515 | CONFIG_PROC_PAGE_MONITOR=y | ||
| 1257 | CONFIG_SYSFS=y | 1516 | CONFIG_SYSFS=y |
| 1258 | CONFIG_TMPFS=y | 1517 | CONFIG_TMPFS=y |
| 1518 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
| 1259 | # CONFIG_HUGETLB_PAGE is not set | 1519 | # CONFIG_HUGETLB_PAGE is not set |
| 1260 | CONFIG_RAMFS=y | 1520 | # CONFIG_CONFIGFS_FS is not set |
| 1261 | # CONFIG_RELAYFS_FS is not set | ||
| 1262 | 1521 | ||
| 1263 | # | 1522 | # |
| 1264 | # Miscellaneous filesystems | 1523 | # Miscellaneous filesystems |
| @@ -1270,39 +1529,42 @@ CONFIG_RAMFS=y | |||
| 1270 | # CONFIG_BEFS_FS is not set | 1529 | # CONFIG_BEFS_FS is not set |
| 1271 | # CONFIG_BFS_FS is not set | 1530 | # CONFIG_BFS_FS is not set |
| 1272 | # CONFIG_EFS_FS is not set | 1531 | # CONFIG_EFS_FS is not set |
| 1273 | # CONFIG_JFFS_FS is not set | ||
| 1274 | CONFIG_JFFS2_FS=y | 1532 | CONFIG_JFFS2_FS=y |
| 1275 | CONFIG_JFFS2_FS_DEBUG=0 | 1533 | CONFIG_JFFS2_FS_DEBUG=0 |
| 1276 | CONFIG_JFFS2_FS_WRITEBUFFER=y | 1534 | CONFIG_JFFS2_FS_WRITEBUFFER=y |
| 1535 | # CONFIG_JFFS2_FS_WBUF_VERIFY is not set | ||
| 1277 | CONFIG_JFFS2_SUMMARY=y | 1536 | CONFIG_JFFS2_SUMMARY=y |
| 1537 | # CONFIG_JFFS2_FS_XATTR is not set | ||
| 1278 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y | 1538 | CONFIG_JFFS2_COMPRESSION_OPTIONS=y |
| 1279 | CONFIG_JFFS2_ZLIB=y | 1539 | CONFIG_JFFS2_ZLIB=y |
| 1540 | # CONFIG_JFFS2_LZO is not set | ||
| 1280 | CONFIG_JFFS2_RTIME=y | 1541 | CONFIG_JFFS2_RTIME=y |
| 1281 | CONFIG_JFFS2_RUBIN=y | 1542 | CONFIG_JFFS2_RUBIN=y |
| 1282 | # CONFIG_JFFS2_CMODE_NONE is not set | 1543 | # CONFIG_JFFS2_CMODE_NONE is not set |
| 1283 | CONFIG_JFFS2_CMODE_PRIORITY=y | 1544 | CONFIG_JFFS2_CMODE_PRIORITY=y |
| 1284 | # CONFIG_JFFS2_CMODE_SIZE is not set | 1545 | # CONFIG_JFFS2_CMODE_SIZE is not set |
| 1546 | # CONFIG_JFFS2_CMODE_FAVOURLZO is not set | ||
| 1285 | CONFIG_CRAMFS=m | 1547 | CONFIG_CRAMFS=m |
| 1286 | # CONFIG_VXFS_FS is not set | 1548 | # CONFIG_VXFS_FS is not set |
| 1549 | # CONFIG_MINIX_FS is not set | ||
| 1550 | # CONFIG_OMFS_FS is not set | ||
| 1287 | # CONFIG_HPFS_FS is not set | 1551 | # CONFIG_HPFS_FS is not set |
| 1288 | # CONFIG_QNX4FS_FS is not set | 1552 | # CONFIG_QNX4FS_FS is not set |
| 1553 | # CONFIG_ROMFS_FS is not set | ||
| 1289 | # CONFIG_SYSV_FS is not set | 1554 | # CONFIG_SYSV_FS is not set |
| 1290 | # CONFIG_UFS_FS is not set | 1555 | # CONFIG_UFS_FS is not set |
| 1291 | 1556 | CONFIG_NETWORK_FILESYSTEMS=y | |
| 1292 | # | ||
| 1293 | # Network File Systems | ||
| 1294 | # | ||
| 1295 | CONFIG_NFS_FS=m | 1557 | CONFIG_NFS_FS=m |
| 1296 | CONFIG_NFS_V3=y | 1558 | CONFIG_NFS_V3=y |
| 1297 | # CONFIG_NFS_V3_ACL is not set | 1559 | # CONFIG_NFS_V3_ACL is not set |
| 1298 | CONFIG_NFS_V4=y | 1560 | CONFIG_NFS_V4=y |
| 1299 | # CONFIG_NFS_DIRECTIO is not set | ||
| 1300 | # CONFIG_NFSD is not set | 1561 | # CONFIG_NFSD is not set |
| 1301 | CONFIG_LOCKD=m | 1562 | CONFIG_LOCKD=m |
| 1302 | CONFIG_LOCKD_V4=y | 1563 | CONFIG_LOCKD_V4=y |
| 1303 | CONFIG_NFS_COMMON=y | 1564 | CONFIG_NFS_COMMON=y |
| 1304 | CONFIG_SUNRPC=m | 1565 | CONFIG_SUNRPC=m |
| 1305 | CONFIG_SUNRPC_GSS=m | 1566 | CONFIG_SUNRPC_GSS=m |
| 1567 | # CONFIG_SUNRPC_REGISTER_V4 is not set | ||
| 1306 | CONFIG_RPCSEC_GSS_KRB5=m | 1568 | CONFIG_RPCSEC_GSS_KRB5=m |
| 1307 | # CONFIG_RPCSEC_GSS_SPKM3 is not set | 1569 | # CONFIG_RPCSEC_GSS_SPKM3 is not set |
| 1308 | CONFIG_SMB_FS=m | 1570 | CONFIG_SMB_FS=m |
| @@ -1312,7 +1574,6 @@ CONFIG_SMB_NLS_REMOTE="cp437" | |||
| 1312 | # CONFIG_NCP_FS is not set | 1574 | # CONFIG_NCP_FS is not set |
| 1313 | # CONFIG_CODA_FS is not set | 1575 | # CONFIG_CODA_FS is not set |
| 1314 | # CONFIG_AFS_FS is not set | 1576 | # CONFIG_AFS_FS is not set |
| 1315 | # CONFIG_9P_FS is not set | ||
| 1316 | 1577 | ||
| 1317 | # | 1578 | # |
| 1318 | # Partition Types | 1579 | # Partition Types |
| @@ -1332,11 +1593,9 @@ CONFIG_MSDOS_PARTITION=y | |||
| 1332 | # CONFIG_SGI_PARTITION is not set | 1593 | # CONFIG_SGI_PARTITION is not set |
| 1333 | # CONFIG_ULTRIX_PARTITION is not set | 1594 | # CONFIG_ULTRIX_PARTITION is not set |
| 1334 | # CONFIG_SUN_PARTITION is not set | 1595 | # CONFIG_SUN_PARTITION is not set |
| 1596 | # CONFIG_KARMA_PARTITION is not set | ||
| 1335 | # CONFIG_EFI_PARTITION is not set | 1597 | # CONFIG_EFI_PARTITION is not set |
| 1336 | 1598 | # CONFIG_SYSV68_PARTITION is not set | |
| 1337 | # | ||
| 1338 | # Native Language Support | ||
| 1339 | # | ||
| 1340 | CONFIG_NLS=y | 1599 | CONFIG_NLS=y |
| 1341 | CONFIG_NLS_DEFAULT="cp437" | 1600 | CONFIG_NLS_DEFAULT="cp437" |
| 1342 | CONFIG_NLS_CODEPAGE_437=y | 1601 | CONFIG_NLS_CODEPAGE_437=y |
| @@ -1377,35 +1636,71 @@ CONFIG_NLS_ISO8859_1=y | |||
| 1377 | # CONFIG_NLS_KOI8_R is not set | 1636 | # CONFIG_NLS_KOI8_R is not set |
| 1378 | # CONFIG_NLS_KOI8_U is not set | 1637 | # CONFIG_NLS_KOI8_U is not set |
| 1379 | CONFIG_NLS_UTF8=y | 1638 | CONFIG_NLS_UTF8=y |
| 1380 | 1639 | # CONFIG_DLM is not set | |
| 1381 | # | ||
| 1382 | # Profiling support | ||
| 1383 | # | ||
| 1384 | CONFIG_PROFILING=y | ||
| 1385 | CONFIG_OPROFILE=m | ||
| 1386 | 1640 | ||
| 1387 | # | 1641 | # |
| 1388 | # Kernel hacking | 1642 | # Kernel hacking |
| 1389 | # | 1643 | # |
| 1390 | # CONFIG_PRINTK_TIME is not set | 1644 | # CONFIG_PRINTK_TIME is not set |
| 1391 | CONFIG_DEBUG_KERNEL=y | 1645 | CONFIG_ENABLE_WARN_DEPRECATED=y |
| 1646 | CONFIG_ENABLE_MUST_CHECK=y | ||
| 1647 | CONFIG_FRAME_WARN=1024 | ||
| 1392 | CONFIG_MAGIC_SYSRQ=y | 1648 | CONFIG_MAGIC_SYSRQ=y |
| 1393 | CONFIG_LOG_BUF_SHIFT=14 | 1649 | # CONFIG_UNUSED_SYMBOLS is not set |
| 1650 | # CONFIG_DEBUG_FS is not set | ||
| 1651 | # CONFIG_HEADERS_CHECK is not set | ||
| 1652 | CONFIG_DEBUG_KERNEL=y | ||
| 1653 | # CONFIG_DEBUG_SHIRQ is not set | ||
| 1394 | CONFIG_DETECT_SOFTLOCKUP=y | 1654 | CONFIG_DETECT_SOFTLOCKUP=y |
| 1655 | # CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set | ||
| 1656 | CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0 | ||
| 1657 | CONFIG_SCHED_DEBUG=y | ||
| 1395 | # CONFIG_SCHEDSTATS is not set | 1658 | # CONFIG_SCHEDSTATS is not set |
| 1396 | # CONFIG_DEBUG_SLAB is not set | 1659 | # CONFIG_TIMER_STATS is not set |
| 1660 | # CONFIG_DEBUG_OBJECTS is not set | ||
| 1661 | # CONFIG_SLUB_DEBUG_ON is not set | ||
| 1662 | # CONFIG_SLUB_STATS is not set | ||
| 1397 | # CONFIG_DEBUG_PREEMPT is not set | 1663 | # CONFIG_DEBUG_PREEMPT is not set |
| 1664 | # CONFIG_DEBUG_RT_MUTEXES is not set | ||
| 1665 | # CONFIG_RT_MUTEX_TESTER is not set | ||
| 1398 | # CONFIG_DEBUG_SPINLOCK is not set | 1666 | # CONFIG_DEBUG_SPINLOCK is not set |
| 1667 | # CONFIG_DEBUG_MUTEXES is not set | ||
| 1668 | # CONFIG_DEBUG_LOCK_ALLOC is not set | ||
| 1669 | # CONFIG_PROVE_LOCKING is not set | ||
| 1670 | # CONFIG_LOCK_STAT is not set | ||
| 1399 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set | 1671 | # CONFIG_DEBUG_SPINLOCK_SLEEP is not set |
| 1672 | # CONFIG_DEBUG_LOCKING_API_SELFTESTS is not set | ||
| 1400 | # CONFIG_DEBUG_KOBJECT is not set | 1673 | # CONFIG_DEBUG_KOBJECT is not set |
| 1401 | CONFIG_DEBUG_BUGVERBOSE=y | 1674 | CONFIG_DEBUG_BUGVERBOSE=y |
| 1402 | # CONFIG_DEBUG_INFO is not set | 1675 | # CONFIG_DEBUG_INFO is not set |
| 1403 | # CONFIG_DEBUG_FS is not set | ||
| 1404 | # CONFIG_DEBUG_VM is not set | 1676 | # CONFIG_DEBUG_VM is not set |
| 1677 | # CONFIG_DEBUG_WRITECOUNT is not set | ||
| 1678 | # CONFIG_DEBUG_MEMORY_INIT is not set | ||
| 1679 | # CONFIG_DEBUG_LIST is not set | ||
| 1680 | # CONFIG_DEBUG_SG is not set | ||
| 1405 | CONFIG_FRAME_POINTER=y | 1681 | CONFIG_FRAME_POINTER=y |
| 1682 | # CONFIG_BOOT_PRINTK_DELAY is not set | ||
| 1406 | # CONFIG_RCU_TORTURE_TEST is not set | 1683 | # CONFIG_RCU_TORTURE_TEST is not set |
| 1684 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | ||
| 1685 | # CONFIG_BACKTRACE_SELF_TEST is not set | ||
| 1686 | # CONFIG_DEBUG_BLOCK_EXT_DEVT is not set | ||
| 1687 | # CONFIG_FAULT_INJECTION is not set | ||
| 1688 | # CONFIG_LATENCYTOP is not set | ||
| 1689 | # CONFIG_SYSCTL_SYSCALL_CHECK is not set | ||
| 1690 | CONFIG_HAVE_FTRACE=y | ||
| 1691 | CONFIG_HAVE_DYNAMIC_FTRACE=y | ||
| 1692 | # CONFIG_FTRACE is not set | ||
| 1693 | # CONFIG_IRQSOFF_TRACER is not set | ||
| 1694 | # CONFIG_PREEMPT_TRACER is not set | ||
| 1695 | # CONFIG_SCHED_TRACER is not set | ||
| 1696 | # CONFIG_CONTEXT_SWITCH_TRACER is not set | ||
| 1697 | # CONFIG_DYNAMIC_PRINTK_DEBUG is not set | ||
| 1698 | # CONFIG_SAMPLES is not set | ||
| 1699 | CONFIG_HAVE_ARCH_KGDB=y | ||
| 1700 | # CONFIG_KGDB is not set | ||
| 1407 | # CONFIG_DEBUG_USER is not set | 1701 | # CONFIG_DEBUG_USER is not set |
| 1408 | CONFIG_DEBUG_ERRORS=y | 1702 | CONFIG_DEBUG_ERRORS=y |
| 1703 | # CONFIG_DEBUG_STACK_USAGE is not set | ||
| 1409 | CONFIG_DEBUG_LL=y | 1704 | CONFIG_DEBUG_LL=y |
| 1410 | # CONFIG_DEBUG_ICEDCC is not set | 1705 | # CONFIG_DEBUG_ICEDCC is not set |
| 1411 | 1706 | ||
| @@ -1414,46 +1709,113 @@ CONFIG_DEBUG_LL=y | |||
| 1414 | # | 1709 | # |
| 1415 | # CONFIG_KEYS is not set | 1710 | # CONFIG_KEYS is not set |
| 1416 | # CONFIG_SECURITY is not set | 1711 | # CONFIG_SECURITY is not set |
| 1712 | # CONFIG_SECURITYFS is not set | ||
| 1713 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
| 1714 | CONFIG_CRYPTO=y | ||
| 1417 | 1715 | ||
| 1418 | # | 1716 | # |
| 1419 | # Cryptographic options | 1717 | # Crypto core or helper |
| 1420 | # | 1718 | # |
| 1421 | CONFIG_CRYPTO=y | 1719 | # CONFIG_CRYPTO_FIPS is not set |
| 1422 | CONFIG_CRYPTO_HMAC=y | 1720 | CONFIG_CRYPTO_ALGAPI=y |
| 1721 | CONFIG_CRYPTO_AEAD=y | ||
| 1722 | CONFIG_CRYPTO_BLKCIPHER=y | ||
| 1723 | CONFIG_CRYPTO_HASH=y | ||
| 1724 | CONFIG_CRYPTO_RNG=y | ||
| 1725 | CONFIG_CRYPTO_MANAGER=y | ||
| 1726 | # CONFIG_CRYPTO_GF128MUL is not set | ||
| 1423 | CONFIG_CRYPTO_NULL=m | 1727 | CONFIG_CRYPTO_NULL=m |
| 1728 | # CONFIG_CRYPTO_CRYPTD is not set | ||
| 1729 | CONFIG_CRYPTO_AUTHENC=m | ||
| 1730 | CONFIG_CRYPTO_TEST=m | ||
| 1731 | |||
| 1732 | # | ||
| 1733 | # Authenticated Encryption with Associated Data | ||
| 1734 | # | ||
| 1735 | # CONFIG_CRYPTO_CCM is not set | ||
| 1736 | # CONFIG_CRYPTO_GCM is not set | ||
| 1737 | # CONFIG_CRYPTO_SEQIV is not set | ||
| 1738 | |||
| 1739 | # | ||
| 1740 | # Block modes | ||
| 1741 | # | ||
| 1742 | CONFIG_CRYPTO_CBC=m | ||
| 1743 | # CONFIG_CRYPTO_CTR is not set | ||
| 1744 | # CONFIG_CRYPTO_CTS is not set | ||
| 1745 | CONFIG_CRYPTO_ECB=m | ||
| 1746 | # CONFIG_CRYPTO_LRW is not set | ||
| 1747 | # CONFIG_CRYPTO_PCBC is not set | ||
| 1748 | # CONFIG_CRYPTO_XTS is not set | ||
| 1749 | |||
| 1750 | # | ||
| 1751 | # Hash modes | ||
| 1752 | # | ||
| 1753 | CONFIG_CRYPTO_HMAC=y | ||
| 1754 | # CONFIG_CRYPTO_XCBC is not set | ||
| 1755 | |||
| 1756 | # | ||
| 1757 | # Digest | ||
| 1758 | # | ||
| 1759 | CONFIG_CRYPTO_CRC32C=m | ||
| 1424 | CONFIG_CRYPTO_MD4=m | 1760 | CONFIG_CRYPTO_MD4=m |
| 1425 | CONFIG_CRYPTO_MD5=m | 1761 | CONFIG_CRYPTO_MD5=m |
| 1762 | CONFIG_CRYPTO_MICHAEL_MIC=m | ||
| 1763 | # CONFIG_CRYPTO_RMD128 is not set | ||
| 1764 | # CONFIG_CRYPTO_RMD160 is not set | ||
| 1765 | # CONFIG_CRYPTO_RMD256 is not set | ||
| 1766 | # CONFIG_CRYPTO_RMD320 is not set | ||
| 1426 | CONFIG_CRYPTO_SHA1=m | 1767 | CONFIG_CRYPTO_SHA1=m |
| 1427 | CONFIG_CRYPTO_SHA256=m | 1768 | CONFIG_CRYPTO_SHA256=m |
| 1428 | CONFIG_CRYPTO_SHA512=m | 1769 | CONFIG_CRYPTO_SHA512=m |
| 1429 | CONFIG_CRYPTO_WP512=m | ||
| 1430 | # CONFIG_CRYPTO_TGR192 is not set | 1770 | # CONFIG_CRYPTO_TGR192 is not set |
| 1431 | CONFIG_CRYPTO_DES=m | 1771 | CONFIG_CRYPTO_WP512=m |
| 1432 | CONFIG_CRYPTO_BLOWFISH=m | 1772 | |
| 1433 | CONFIG_CRYPTO_TWOFISH=m | 1773 | # |
| 1434 | CONFIG_CRYPTO_SERPENT=m | 1774 | # Ciphers |
| 1775 | # | ||
| 1435 | CONFIG_CRYPTO_AES=m | 1776 | CONFIG_CRYPTO_AES=m |
| 1777 | CONFIG_CRYPTO_ANUBIS=m | ||
| 1778 | CONFIG_CRYPTO_ARC4=m | ||
| 1779 | CONFIG_CRYPTO_BLOWFISH=m | ||
| 1780 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
| 1436 | CONFIG_CRYPTO_CAST5=m | 1781 | CONFIG_CRYPTO_CAST5=m |
| 1437 | CONFIG_CRYPTO_CAST6=m | 1782 | CONFIG_CRYPTO_CAST6=m |
| 1438 | CONFIG_CRYPTO_TEA=m | 1783 | CONFIG_CRYPTO_DES=m |
| 1439 | CONFIG_CRYPTO_ARC4=m | 1784 | # CONFIG_CRYPTO_FCRYPT is not set |
| 1440 | CONFIG_CRYPTO_KHAZAD=m | 1785 | CONFIG_CRYPTO_KHAZAD=m |
| 1441 | CONFIG_CRYPTO_ANUBIS=m | 1786 | # CONFIG_CRYPTO_SALSA20 is not set |
| 1787 | # CONFIG_CRYPTO_SEED is not set | ||
| 1788 | CONFIG_CRYPTO_SERPENT=m | ||
| 1789 | CONFIG_CRYPTO_TEA=m | ||
| 1790 | CONFIG_CRYPTO_TWOFISH=m | ||
| 1791 | CONFIG_CRYPTO_TWOFISH_COMMON=m | ||
| 1792 | |||
| 1793 | # | ||
| 1794 | # Compression | ||
| 1795 | # | ||
| 1442 | CONFIG_CRYPTO_DEFLATE=m | 1796 | CONFIG_CRYPTO_DEFLATE=m |
| 1443 | CONFIG_CRYPTO_MICHAEL_MIC=m | 1797 | # CONFIG_CRYPTO_LZO is not set |
| 1444 | CONFIG_CRYPTO_CRC32C=m | ||
| 1445 | CONFIG_CRYPTO_TEST=m | ||
| 1446 | 1798 | ||
| 1447 | # | 1799 | # |
| 1448 | # Hardware crypto devices | 1800 | # Random Number Generation |
| 1449 | # | 1801 | # |
| 1802 | # CONFIG_CRYPTO_ANSI_CPRNG is not set | ||
| 1803 | CONFIG_CRYPTO_HW=y | ||
| 1450 | 1804 | ||
| 1451 | # | 1805 | # |
| 1452 | # Library routines | 1806 | # Library routines |
| 1453 | # | 1807 | # |
| 1808 | CONFIG_BITREVERSE=y | ||
| 1454 | CONFIG_CRC_CCITT=y | 1809 | CONFIG_CRC_CCITT=y |
| 1455 | # CONFIG_CRC16 is not set | 1810 | # CONFIG_CRC16 is not set |
| 1811 | # CONFIG_CRC_T10DIF is not set | ||
| 1812 | # CONFIG_CRC_ITU_T is not set | ||
| 1456 | CONFIG_CRC32=y | 1813 | CONFIG_CRC32=y |
| 1814 | # CONFIG_CRC7 is not set | ||
| 1457 | CONFIG_LIBCRC32C=m | 1815 | CONFIG_LIBCRC32C=m |
| 1458 | CONFIG_ZLIB_INFLATE=y | 1816 | CONFIG_ZLIB_INFLATE=y |
| 1459 | CONFIG_ZLIB_DEFLATE=y | 1817 | CONFIG_ZLIB_DEFLATE=y |
| 1818 | CONFIG_PLIST=y | ||
| 1819 | CONFIG_HAS_IOMEM=y | ||
| 1820 | CONFIG_HAS_IOPORT=y | ||
| 1821 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/arm/include/asm/div64.h b/arch/arm/include/asm/div64.h index 5001390be958..d3f0a9eee9f6 100644 --- a/arch/arm/include/asm/div64.h +++ b/arch/arm/include/asm/div64.h | |||
| @@ -165,7 +165,7 @@ | |||
| 165 | __res = __m; \ | 165 | __res = __m; \ |
| 166 | asm ( "umlal %Q0, %R0, %Q1, %Q2\n\t" \ | 166 | asm ( "umlal %Q0, %R0, %Q1, %Q2\n\t" \ |
| 167 | "mov %Q0, #0" \ | 167 | "mov %Q0, #0" \ |
| 168 | : "+r" (__res) \ | 168 | : "+&r" (__res) \ |
| 169 | : "r" (__m), "r" (__n) \ | 169 | : "r" (__m), "r" (__n) \ |
| 170 | : "cc" ); \ | 170 | : "cc" ); \ |
| 171 | } else { \ | 171 | } else { \ |
| @@ -182,7 +182,7 @@ | |||
| 182 | "umlal %R0, %Q0, %Q1, %R2\n\t" \ | 182 | "umlal %R0, %Q0, %Q1, %R2\n\t" \ |
| 183 | "mov %R0, #0\n\t" \ | 183 | "mov %R0, #0\n\t" \ |
| 184 | "umlal %Q0, %R0, %R1, %R2" \ | 184 | "umlal %Q0, %R0, %R1, %R2" \ |
| 185 | : "+r" (__res) \ | 185 | : "+&r" (__res) \ |
| 186 | : "r" (__m), "r" (__n) \ | 186 | : "r" (__m), "r" (__n) \ |
| 187 | : "cc" ); \ | 187 | : "cc" ); \ |
| 188 | } else { \ | 188 | } else { \ |
| @@ -192,7 +192,7 @@ | |||
| 192 | "adds %Q0, %1, %Q0\n\t" \ | 192 | "adds %Q0, %1, %Q0\n\t" \ |
| 193 | "adc %R0, %R0, #0\n\t" \ | 193 | "adc %R0, %R0, #0\n\t" \ |
| 194 | "umlal %Q0, %R0, %R2, %R3" \ | 194 | "umlal %Q0, %R0, %R2, %R3" \ |
| 195 | : "+r" (__res), "+r" (__z) \ | 195 | : "+&r" (__res), "+&r" (__z) \ |
| 196 | : "r" (__m), "r" (__n) \ | 196 | : "r" (__m), "r" (__n) \ |
| 197 | : "cc" ); \ | 197 | : "cc" ); \ |
| 198 | } \ | 198 | } \ |
diff --git a/arch/arm/mach-at91/gpio.c b/arch/arm/mach-at91/gpio.c index 7e5ebb5bdd17..9b0447c3d59b 100644 --- a/arch/arm/mach-at91/gpio.c +++ b/arch/arm/mach-at91/gpio.c | |||
| @@ -404,6 +404,7 @@ static void gpio_irq_handler(unsigned irq, struct irq_desc *desc) | |||
| 404 | } | 404 | } |
| 405 | 405 | ||
| 406 | pin = bank->chipbase; | 406 | pin = bank->chipbase; |
| 407 | gpio = &irq_desc[pin]; | ||
| 407 | 408 | ||
| 408 | while (isr) { | 409 | while (isr) { |
| 409 | if (isr & 1) { | 410 | if (isr & 1) { |
diff --git a/arch/arm/mach-kirkwood/Makefile b/arch/arm/mach-kirkwood/Makefile index e14bf40bfb07..b96c55dad343 100644 --- a/arch/arm/mach-kirkwood/Makefile +++ b/arch/arm/mach-kirkwood/Makefile | |||
| @@ -2,4 +2,4 @@ obj-y += common.o addr-map.o irq.o pcie.o | |||
| 2 | 2 | ||
| 3 | obj-$(CONFIG_MACH_DB88F6281_BP) += db88f6281-bp-setup.o | 3 | obj-$(CONFIG_MACH_DB88F6281_BP) += db88f6281-bp-setup.o |
| 4 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6192-nas-setup.o | 4 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6192-nas-setup.o |
| 5 | obj-$(CONFIG_MACH_RD88F6192_NAS) += rd88f6281-setup.o | 5 | obj-$(CONFIG_MACH_RD88F6281) += rd88f6281-setup.o |
diff --git a/arch/arm/mach-msm/Kconfig b/arch/arm/mach-msm/Kconfig index 3553babbbf05..d140abca690a 100644 --- a/arch/arm/mach-msm/Kconfig +++ b/arch/arm/mach-msm/Kconfig | |||
| @@ -1,18 +1,13 @@ | |||
| 1 | if ARCH_MSM7X00A | 1 | if ARCH_MSM |
| 2 | 2 | ||
| 3 | comment "MSM7X00A Board Type" | 3 | comment "MSM Board Type" |
| 4 | depends on ARCH_MSM7X00A | 4 | depends on ARCH_MSM |
| 5 | 5 | ||
| 6 | config MACH_HALIBUT | 6 | config MACH_HALIBUT |
| 7 | depends on ARCH_MSM7X00A | 7 | depends on ARCH_MSM |
| 8 | default y | 8 | default y |
| 9 | bool "Halibut Board (QCT SURF7200A)" | 9 | bool "Halibut Board (QCT SURF7201A)" |
| 10 | help | 10 | help |
| 11 | Support for the Qualcomm SURF7200A eval board. | 11 | Support for the Qualcomm SURF7201A eval board. |
| 12 | |||
| 13 | config MSM7X00A_IDLE | ||
| 14 | depends on ARCH_MSM7X00A | ||
| 15 | default y | ||
| 16 | bool "Idle Support for MSM7X00A" | ||
| 17 | 12 | ||
| 18 | endif | 13 | endif |
diff --git a/arch/arm/mach-msm/Makefile b/arch/arm/mach-msm/Makefile index d12f23655850..1aa47001aa3b 100644 --- a/arch/arm/mach-msm/Makefile +++ b/arch/arm/mach-msm/Makefile | |||
| @@ -1,7 +1,8 @@ | |||
| 1 | obj-y += io.o idle.o irq.o timer.o dma.o | 1 | obj-y += io.o idle.o irq.o timer.o dma.o |
| 2 | 2 | obj-y += devices.o | |
| 3 | # Common code for board init | 3 | obj-y += proc_comm.o |
| 4 | obj-y += common.o | 4 | obj-y += vreg.o |
| 5 | obj-y += clock.o clock-7x01a.o | ||
| 5 | 6 | ||
| 6 | obj-$(CONFIG_MACH_HALIBUT) += board-halibut.o | 7 | obj-$(CONFIG_MACH_HALIBUT) += board-halibut.o |
| 7 | 8 | ||
diff --git a/arch/arm/mach-msm/board-halibut.c b/arch/arm/mach-msm/board-halibut.c index a24259133e07..c2a96e3965a6 100644 --- a/arch/arm/mach-msm/board-halibut.c +++ b/arch/arm/mach-msm/board-halibut.c | |||
| @@ -33,6 +33,8 @@ | |||
| 33 | #include <linux/mtd/nand.h> | 33 | #include <linux/mtd/nand.h> |
| 34 | #include <linux/mtd/partitions.h> | 34 | #include <linux/mtd/partitions.h> |
| 35 | 35 | ||
| 36 | #include "devices.h" | ||
| 37 | |||
| 36 | static struct resource smc91x_resources[] = { | 38 | static struct resource smc91x_resources[] = { |
| 37 | [0] = { | 39 | [0] = { |
| 38 | .start = 0x9C004300, | 40 | .start = 0x9C004300, |
| @@ -53,31 +55,12 @@ static struct platform_device smc91x_device = { | |||
| 53 | .resource = smc91x_resources, | 55 | .resource = smc91x_resources, |
| 54 | }; | 56 | }; |
| 55 | 57 | ||
| 56 | static void mddi0_panel_power(int on) | ||
| 57 | { | ||
| 58 | } | ||
| 59 | |||
| 60 | static struct msm_mddi_platform_data msm_mddi0_pdata = { | ||
| 61 | .panel_power = mddi0_panel_power, | ||
| 62 | .has_vsync_irq = 0, | ||
| 63 | }; | ||
| 64 | |||
| 65 | static struct platform_device msm_mddi0_device = { | ||
| 66 | .name = "msm_mddi", | ||
| 67 | .id = 0, | ||
| 68 | .dev = { | ||
| 69 | .platform_data = &msm_mddi0_pdata | ||
| 70 | }, | ||
| 71 | }; | ||
| 72 | |||
| 73 | static struct platform_device msm_serial0_device = { | ||
| 74 | .name = "msm_serial", | ||
| 75 | .id = 0, | ||
| 76 | }; | ||
| 77 | |||
| 78 | static struct platform_device *devices[] __initdata = { | 58 | static struct platform_device *devices[] __initdata = { |
| 79 | &msm_serial0_device, | 59 | &msm_device_uart3, |
| 80 | &msm_mddi0_device, | 60 | &msm_device_smd, |
| 61 | &msm_device_nand, | ||
| 62 | &msm_device_hsusb, | ||
| 63 | &msm_device_i2c, | ||
| 81 | &smc91x_device, | 64 | &smc91x_device, |
| 82 | }; | 65 | }; |
| 83 | 66 | ||
| @@ -91,20 +74,15 @@ static void __init halibut_init_irq(void) | |||
| 91 | static void __init halibut_init(void) | 74 | static void __init halibut_init(void) |
| 92 | { | 75 | { |
| 93 | platform_add_devices(devices, ARRAY_SIZE(devices)); | 76 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
| 94 | msm_add_devices(); | ||
| 95 | } | 77 | } |
| 96 | 78 | ||
| 97 | static void __init halibut_map_io(void) | 79 | static void __init halibut_map_io(void) |
| 98 | { | 80 | { |
| 99 | msm_map_common_io(); | 81 | msm_map_common_io(); |
| 82 | msm_clock_init(); | ||
| 100 | } | 83 | } |
| 101 | 84 | ||
| 102 | MACHINE_START(HALIBUT, "Halibut Board (QCT SURF7200A)") | 85 | MACHINE_START(HALIBUT, "Halibut Board (QCT SURF7200A)") |
| 103 | |||
| 104 | /* UART for LL DEBUG */ | ||
| 105 | .phys_io = MSM_UART1_PHYS, | ||
| 106 | .io_pg_offst = ((MSM_UART1_BASE) >> 18) & 0xfffc, | ||
| 107 | |||
| 108 | .boot_params = 0x10000100, | 86 | .boot_params = 0x10000100, |
| 109 | .map_io = halibut_map_io, | 87 | .map_io = halibut_map_io, |
| 110 | .init_irq = halibut_init_irq, | 88 | .init_irq = halibut_init_irq, |
diff --git a/arch/arm/mach-msm/clock-7x01a.c b/arch/arm/mach-msm/clock-7x01a.c new file mode 100644 index 000000000000..62230a3428ee --- /dev/null +++ b/arch/arm/mach-msm/clock-7x01a.c | |||
| @@ -0,0 +1,126 @@ | |||
| 1 | /* arch/arm/mach-msm/clock-7x01a.c | ||
| 2 | * | ||
| 3 | * Clock tables for MSM7X01A | ||
| 4 | * | ||
| 5 | * Copyright (C) 2007 Google, Inc. | ||
| 6 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
| 7 | * | ||
| 8 | * This software is licensed under the terms of the GNU General Public | ||
| 9 | * License version 2, as published by the Free Software Foundation, and | ||
| 10 | * may be copied, distributed, and modified under those terms. | ||
| 11 | * | ||
| 12 | * This program is distributed in the hope that it will be useful, | ||
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | * GNU General Public License for more details. | ||
| 16 | * | ||
| 17 | */ | ||
| 18 | |||
| 19 | #include <linux/kernel.h> | ||
| 20 | #include <linux/platform_device.h> | ||
| 21 | |||
| 22 | #include "clock.h" | ||
| 23 | #include "devices.h" | ||
| 24 | |||
| 25 | /* clock IDs used by the modem processor */ | ||
| 26 | |||
| 27 | #define ACPU_CLK 0 /* Applications processor clock */ | ||
| 28 | #define ADM_CLK 1 /* Applications data mover clock */ | ||
| 29 | #define ADSP_CLK 2 /* ADSP clock */ | ||
| 30 | #define EBI1_CLK 3 /* External bus interface 1 clock */ | ||
| 31 | #define EBI2_CLK 4 /* External bus interface 2 clock */ | ||
| 32 | #define ECODEC_CLK 5 /* External CODEC clock */ | ||
| 33 | #define EMDH_CLK 6 /* External MDDI host clock */ | ||
| 34 | #define GP_CLK 7 /* General purpose clock */ | ||
| 35 | #define GRP_CLK 8 /* Graphics clock */ | ||
| 36 | #define I2C_CLK 9 /* I2C clock */ | ||
| 37 | #define ICODEC_RX_CLK 10 /* Internal CODEX RX clock */ | ||
| 38 | #define ICODEC_TX_CLK 11 /* Internal CODEX TX clock */ | ||
| 39 | #define IMEM_CLK 12 /* Internal graphics memory clock */ | ||
| 40 | #define MDC_CLK 13 /* MDDI client clock */ | ||
| 41 | #define MDP_CLK 14 /* Mobile display processor clock */ | ||
| 42 | #define PBUS_CLK 15 /* Peripheral bus clock */ | ||
| 43 | #define PCM_CLK 16 /* PCM clock */ | ||
| 44 | #define PMDH_CLK 17 /* Primary MDDI host clock */ | ||
| 45 | #define SDAC_CLK 18 /* Stereo DAC clock */ | ||
| 46 | #define SDC1_CLK 19 /* Secure Digital Card clocks */ | ||
| 47 | #define SDC1_PCLK 20 | ||
| 48 | #define SDC2_CLK 21 | ||
| 49 | #define SDC2_PCLK 22 | ||
| 50 | #define SDC3_CLK 23 | ||
| 51 | #define SDC3_PCLK 24 | ||
| 52 | #define SDC4_CLK 25 | ||
| 53 | #define SDC4_PCLK 26 | ||
| 54 | #define TSIF_CLK 27 /* Transport Stream Interface clocks */ | ||
| 55 | #define TSIF_REF_CLK 28 | ||
| 56 | #define TV_DAC_CLK 29 /* TV clocks */ | ||
| 57 | #define TV_ENC_CLK 30 | ||
| 58 | #define UART1_CLK 31 /* UART clocks */ | ||
| 59 | #define UART2_CLK 32 | ||
| 60 | #define UART3_CLK 33 | ||
| 61 | #define UART1DM_CLK 34 | ||
| 62 | #define UART2DM_CLK 35 | ||
| 63 | #define USB_HS_CLK 36 /* High speed USB core clock */ | ||
| 64 | #define USB_HS_PCLK 37 /* High speed USB pbus clock */ | ||
| 65 | #define USB_OTG_CLK 38 /* Full speed USB clock */ | ||
| 66 | #define VDC_CLK 39 /* Video controller clock */ | ||
| 67 | #define VFE_CLK 40 /* Camera / Video Front End clock */ | ||
| 68 | #define VFE_MDC_CLK 41 /* VFE MDDI client clock */ | ||
| 69 | |||
| 70 | #define NR_CLKS 42 | ||
| 71 | |||
| 72 | #define CLOCK(clk_name, clk_id, clk_dev, clk_flags) { \ | ||
| 73 | .name = clk_name, \ | ||
| 74 | .id = clk_id, \ | ||
| 75 | .flags = clk_flags, \ | ||
| 76 | .dev = clk_dev, \ | ||
| 77 | } | ||
| 78 | |||
| 79 | #define OFF CLKFLAG_AUTO_OFF | ||
| 80 | #define MINMAX CLKFLAG_USE_MIN_MAX_TO_SET | ||
| 81 | |||
| 82 | struct clk msm_clocks[] = { | ||
| 83 | CLOCK("adm_clk", ADM_CLK, NULL, 0), | ||
| 84 | CLOCK("adsp_clk", ADSP_CLK, NULL, 0), | ||
| 85 | CLOCK("ebi1_clk", EBI1_CLK, NULL, 0), | ||
| 86 | CLOCK("ebi2_clk", EBI2_CLK, NULL, 0), | ||
| 87 | CLOCK("ecodec_clk", ECODEC_CLK, NULL, 0), | ||
| 88 | CLOCK("emdh_clk", EMDH_CLK, NULL, OFF), | ||
| 89 | CLOCK("gp_clk", GP_CLK, NULL, 0), | ||
| 90 | CLOCK("grp_clk", GRP_CLK, NULL, OFF), | ||
| 91 | CLOCK("i2c_clk", I2C_CLK, &msm_device_i2c.dev, 0), | ||
| 92 | CLOCK("icodec_rx_clk", ICODEC_RX_CLK, NULL, 0), | ||
| 93 | CLOCK("icodec_tx_clk", ICODEC_TX_CLK, NULL, 0), | ||
| 94 | CLOCK("imem_clk", IMEM_CLK, NULL, OFF), | ||
| 95 | CLOCK("mdc_clk", MDC_CLK, NULL, 0), | ||
| 96 | CLOCK("mdp_clk", MDP_CLK, NULL, OFF), | ||
| 97 | CLOCK("pbus_clk", PBUS_CLK, NULL, 0), | ||
| 98 | CLOCK("pcm_clk", PCM_CLK, NULL, 0), | ||
| 99 | CLOCK("pmdh_clk", PMDH_CLK, NULL, OFF | MINMAX), | ||
| 100 | CLOCK("sdac_clk", SDAC_CLK, NULL, OFF), | ||
| 101 | CLOCK("sdc_clk", SDC1_CLK, &msm_device_sdc1.dev, OFF), | ||
| 102 | CLOCK("sdc_pclk", SDC1_PCLK, &msm_device_sdc1.dev, OFF), | ||
| 103 | CLOCK("sdc_clk", SDC2_CLK, &msm_device_sdc2.dev, OFF), | ||
| 104 | CLOCK("sdc_pclk", SDC2_PCLK, &msm_device_sdc2.dev, OFF), | ||
| 105 | CLOCK("sdc_clk", SDC3_CLK, &msm_device_sdc3.dev, OFF), | ||
| 106 | CLOCK("sdc_pclk", SDC3_PCLK, &msm_device_sdc3.dev, OFF), | ||
| 107 | CLOCK("sdc_clk", SDC4_CLK, &msm_device_sdc4.dev, OFF), | ||
| 108 | CLOCK("sdc_pclk", SDC4_PCLK, &msm_device_sdc4.dev, OFF), | ||
| 109 | CLOCK("tsif_clk", TSIF_CLK, NULL, 0), | ||
| 110 | CLOCK("tsif_ref_clk", TSIF_REF_CLK, NULL, 0), | ||
| 111 | CLOCK("tv_dac_clk", TV_DAC_CLK, NULL, 0), | ||
| 112 | CLOCK("tv_enc_clk", TV_ENC_CLK, NULL, 0), | ||
| 113 | CLOCK("uart_clk", UART1_CLK, &msm_device_uart1.dev, OFF), | ||
| 114 | CLOCK("uart_clk", UART2_CLK, &msm_device_uart2.dev, 0), | ||
| 115 | CLOCK("uart_clk", UART3_CLK, &msm_device_uart3.dev, OFF), | ||
| 116 | CLOCK("uart1dm_clk", UART1DM_CLK, NULL, OFF), | ||
| 117 | CLOCK("uart2dm_clk", UART2DM_CLK, NULL, 0), | ||
| 118 | CLOCK("usb_hs_clk", USB_HS_CLK, &msm_device_hsusb.dev, OFF), | ||
| 119 | CLOCK("usb_hs_pclk", USB_HS_PCLK, &msm_device_hsusb.dev, OFF), | ||
| 120 | CLOCK("usb_otg_clk", USB_OTG_CLK, NULL, 0), | ||
| 121 | CLOCK("vdc_clk", VDC_CLK, NULL, OFF | MINMAX), | ||
| 122 | CLOCK("vfe_clk", VFE_CLK, NULL, OFF), | ||
| 123 | CLOCK("vfe_mdc_clk", VFE_MDC_CLK, NULL, OFF), | ||
| 124 | }; | ||
| 125 | |||
| 126 | unsigned msm_num_clocks = ARRAY_SIZE(msm_clocks); | ||
diff --git a/arch/arm/mach-msm/clock.c b/arch/arm/mach-msm/clock.c new file mode 100644 index 000000000000..3b1ce36f1032 --- /dev/null +++ b/arch/arm/mach-msm/clock.c | |||
| @@ -0,0 +1,218 @@ | |||
| 1 | /* arch/arm/mach-msm/clock.c | ||
| 2 | * | ||
| 3 | * Copyright (C) 2007 Google, Inc. | ||
| 4 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
| 5 | * | ||
| 6 | * This software is licensed under the terms of the GNU General Public | ||
| 7 | * License version 2, as published by the Free Software Foundation, and | ||
| 8 | * may be copied, distributed, and modified under those terms. | ||
| 9 | * | ||
| 10 | * This program is distributed in the hope that it will be useful, | ||
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 13 | * GNU General Public License for more details. | ||
| 14 | * | ||
| 15 | */ | ||
| 16 | |||
| 17 | #include <linux/version.h> | ||
| 18 | #include <linux/kernel.h> | ||
| 19 | #include <linux/init.h> | ||
| 20 | #include <linux/module.h> | ||
| 21 | #include <linux/list.h> | ||
| 22 | #include <linux/err.h> | ||
| 23 | #include <linux/clk.h> | ||
| 24 | #include <linux/spinlock.h> | ||
| 25 | |||
| 26 | #include "clock.h" | ||
| 27 | #include "proc_comm.h" | ||
| 28 | |||
| 29 | static DEFINE_MUTEX(clocks_mutex); | ||
| 30 | static DEFINE_SPINLOCK(clocks_lock); | ||
| 31 | static LIST_HEAD(clocks); | ||
| 32 | |||
| 33 | /* | ||
| 34 | * glue for the proc_comm interface | ||
| 35 | */ | ||
| 36 | static inline int pc_clk_enable(unsigned id) | ||
| 37 | { | ||
| 38 | return msm_proc_comm(PCOM_CLKCTL_RPC_ENABLE, &id, NULL); | ||
| 39 | } | ||
| 40 | |||
| 41 | static inline void pc_clk_disable(unsigned id) | ||
| 42 | { | ||
| 43 | msm_proc_comm(PCOM_CLKCTL_RPC_DISABLE, &id, NULL); | ||
| 44 | } | ||
| 45 | |||
| 46 | static inline int pc_clk_set_rate(unsigned id, unsigned rate) | ||
| 47 | { | ||
| 48 | return msm_proc_comm(PCOM_CLKCTL_RPC_SET_RATE, &id, &rate); | ||
| 49 | } | ||
| 50 | |||
| 51 | static inline int pc_clk_set_min_rate(unsigned id, unsigned rate) | ||
| 52 | { | ||
| 53 | return msm_proc_comm(PCOM_CLKCTL_RPC_MIN_RATE, &id, &rate); | ||
| 54 | } | ||
| 55 | |||
| 56 | static inline int pc_clk_set_max_rate(unsigned id, unsigned rate) | ||
| 57 | { | ||
| 58 | return msm_proc_comm(PCOM_CLKCTL_RPC_MAX_RATE, &id, &rate); | ||
| 59 | } | ||
| 60 | |||
| 61 | static inline int pc_clk_set_flags(unsigned id, unsigned flags) | ||
| 62 | { | ||
| 63 | return msm_proc_comm(PCOM_CLKCTL_RPC_SET_FLAGS, &id, &flags); | ||
| 64 | } | ||
| 65 | |||
| 66 | static inline unsigned pc_clk_get_rate(unsigned id) | ||
| 67 | { | ||
| 68 | if (msm_proc_comm(PCOM_CLKCTL_RPC_RATE, &id, NULL)) | ||
| 69 | return 0; | ||
| 70 | else | ||
| 71 | return id; | ||
| 72 | } | ||
| 73 | |||
| 74 | static inline unsigned pc_clk_is_enabled(unsigned id) | ||
| 75 | { | ||
| 76 | if (msm_proc_comm(PCOM_CLKCTL_RPC_ENABLED, &id, NULL)) | ||
| 77 | return 0; | ||
| 78 | else | ||
| 79 | return id; | ||
| 80 | } | ||
| 81 | |||
| 82 | static inline int pc_pll_request(unsigned id, unsigned on) | ||
| 83 | { | ||
| 84 | on = !!on; | ||
| 85 | return msm_proc_comm(PCOM_CLKCTL_RPC_PLL_REQUEST, &id, &on); | ||
| 86 | } | ||
| 87 | |||
| 88 | /* | ||
| 89 | * Standard clock functions defined in include/linux/clk.h | ||
| 90 | */ | ||
| 91 | struct clk *clk_get(struct device *dev, const char *id) | ||
| 92 | { | ||
| 93 | struct clk *clk; | ||
| 94 | |||
| 95 | mutex_lock(&clocks_mutex); | ||
| 96 | |||
| 97 | list_for_each_entry(clk, &clocks, list) | ||
| 98 | if (!strcmp(id, clk->name) && clk->dev == dev) | ||
| 99 | goto found_it; | ||
| 100 | |||
| 101 | list_for_each_entry(clk, &clocks, list) | ||
| 102 | if (!strcmp(id, clk->name) && clk->dev == NULL) | ||
| 103 | goto found_it; | ||
| 104 | |||
| 105 | clk = ERR_PTR(-ENOENT); | ||
| 106 | found_it: | ||
| 107 | mutex_unlock(&clocks_mutex); | ||
| 108 | return clk; | ||
| 109 | } | ||
| 110 | EXPORT_SYMBOL(clk_get); | ||
| 111 | |||
| 112 | void clk_put(struct clk *clk) | ||
| 113 | { | ||
| 114 | } | ||
| 115 | EXPORT_SYMBOL(clk_put); | ||
| 116 | |||
| 117 | int clk_enable(struct clk *clk) | ||
| 118 | { | ||
| 119 | unsigned long flags; | ||
| 120 | spin_lock_irqsave(&clocks_lock, flags); | ||
| 121 | clk->count++; | ||
| 122 | if (clk->count == 1) | ||
| 123 | pc_clk_enable(clk->id); | ||
| 124 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
| 125 | return 0; | ||
| 126 | } | ||
| 127 | EXPORT_SYMBOL(clk_enable); | ||
| 128 | |||
| 129 | void clk_disable(struct clk *clk) | ||
| 130 | { | ||
| 131 | unsigned long flags; | ||
| 132 | spin_lock_irqsave(&clocks_lock, flags); | ||
| 133 | BUG_ON(clk->count == 0); | ||
| 134 | clk->count--; | ||
| 135 | if (clk->count == 0) | ||
| 136 | pc_clk_disable(clk->id); | ||
| 137 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
| 138 | } | ||
| 139 | EXPORT_SYMBOL(clk_disable); | ||
| 140 | |||
| 141 | unsigned long clk_get_rate(struct clk *clk) | ||
| 142 | { | ||
| 143 | return pc_clk_get_rate(clk->id); | ||
| 144 | } | ||
| 145 | EXPORT_SYMBOL(clk_get_rate); | ||
| 146 | |||
| 147 | int clk_set_rate(struct clk *clk, unsigned long rate) | ||
| 148 | { | ||
| 149 | int ret; | ||
| 150 | if (clk->flags & CLKFLAG_USE_MIN_MAX_TO_SET) { | ||
| 151 | ret = pc_clk_set_max_rate(clk->id, rate); | ||
| 152 | if (ret) | ||
| 153 | return ret; | ||
| 154 | return pc_clk_set_min_rate(clk->id, rate); | ||
| 155 | } | ||
| 156 | return pc_clk_set_rate(clk->id, rate); | ||
| 157 | } | ||
| 158 | EXPORT_SYMBOL(clk_set_rate); | ||
| 159 | |||
| 160 | int clk_set_parent(struct clk *clk, struct clk *parent) | ||
| 161 | { | ||
| 162 | return -ENOSYS; | ||
| 163 | } | ||
| 164 | EXPORT_SYMBOL(clk_set_parent); | ||
| 165 | |||
| 166 | struct clk *clk_get_parent(struct clk *clk) | ||
| 167 | { | ||
| 168 | return ERR_PTR(-ENOSYS); | ||
| 169 | } | ||
| 170 | EXPORT_SYMBOL(clk_get_parent); | ||
| 171 | |||
| 172 | int clk_set_flags(struct clk *clk, unsigned long flags) | ||
| 173 | { | ||
| 174 | if (clk == NULL || IS_ERR(clk)) | ||
| 175 | return -EINVAL; | ||
| 176 | return pc_clk_set_flags(clk->id, flags); | ||
| 177 | } | ||
| 178 | EXPORT_SYMBOL(clk_set_flags); | ||
| 179 | |||
| 180 | |||
| 181 | void __init msm_clock_init(void) | ||
| 182 | { | ||
| 183 | unsigned n; | ||
| 184 | |||
| 185 | spin_lock_init(&clocks_lock); | ||
| 186 | mutex_lock(&clocks_mutex); | ||
| 187 | for (n = 0; n < msm_num_clocks; n++) | ||
| 188 | list_add_tail(&msm_clocks[n].list, &clocks); | ||
| 189 | mutex_unlock(&clocks_mutex); | ||
| 190 | } | ||
| 191 | |||
| 192 | /* The bootloader and/or AMSS may have left various clocks enabled. | ||
| 193 | * Disable any clocks that belong to us (CLKFLAG_AUTO_OFF) but have | ||
| 194 | * not been explicitly enabled by a clk_enable() call. | ||
| 195 | */ | ||
| 196 | static int __init clock_late_init(void) | ||
| 197 | { | ||
| 198 | unsigned long flags; | ||
| 199 | struct clk *clk; | ||
| 200 | unsigned count = 0; | ||
| 201 | |||
| 202 | mutex_lock(&clocks_mutex); | ||
| 203 | list_for_each_entry(clk, &clocks, list) { | ||
| 204 | if (clk->flags & CLKFLAG_AUTO_OFF) { | ||
| 205 | spin_lock_irqsave(&clocks_lock, flags); | ||
| 206 | if (!clk->count) { | ||
| 207 | count++; | ||
| 208 | pc_clk_disable(clk->id); | ||
| 209 | } | ||
| 210 | spin_unlock_irqrestore(&clocks_lock, flags); | ||
| 211 | } | ||
| 212 | } | ||
| 213 | mutex_unlock(&clocks_mutex); | ||
| 214 | pr_info("clock_late_init() disabled %d unused clocks\n", count); | ||
| 215 | return 0; | ||
| 216 | } | ||
| 217 | |||
| 218 | late_initcall(clock_late_init); | ||
diff --git a/arch/arm/mach-msm/clock.h b/arch/arm/mach-msm/clock.h new file mode 100644 index 000000000000..f875e1544e5f --- /dev/null +++ b/arch/arm/mach-msm/clock.h | |||
| @@ -0,0 +1,48 @@ | |||
| 1 | /* arch/arm/mach-msm/clock.h | ||
| 2 | * | ||
| 3 | * Copyright (C) 2007 Google, Inc. | ||
| 4 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
| 5 | * | ||
| 6 | * This software is licensed under the terms of the GNU General Public | ||
| 7 | * License version 2, as published by the Free Software Foundation, and | ||
| 8 | * may be copied, distributed, and modified under those terms. | ||
| 9 | * | ||
| 10 | * This program is distributed in the hope that it will be useful, | ||
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 13 | * GNU General Public License for more details. | ||
| 14 | * | ||
| 15 | */ | ||
| 16 | |||
| 17 | #ifndef __ARCH_ARM_MACH_MSM_CLOCK_H | ||
| 18 | #define __ARCH_ARM_MACH_MSM_CLOCK_H | ||
| 19 | |||
| 20 | #include <linux/list.h> | ||
| 21 | |||
| 22 | #define CLKFLAG_INVERT 0x00000001 | ||
| 23 | #define CLKFLAG_NOINVERT 0x00000002 | ||
| 24 | #define CLKFLAG_NONEST 0x00000004 | ||
| 25 | #define CLKFLAG_NORESET 0x00000008 | ||
| 26 | |||
| 27 | #define CLK_FIRST_AVAILABLE_FLAG 0x00000100 | ||
| 28 | #define CLKFLAG_USE_MIN_MAX_TO_SET 0x00000200 | ||
| 29 | #define CLKFLAG_AUTO_OFF 0x00000400 | ||
| 30 | |||
| 31 | struct clk { | ||
| 32 | uint32_t id; | ||
| 33 | uint32_t count; | ||
| 34 | uint32_t flags; | ||
| 35 | const char *name; | ||
| 36 | struct list_head list; | ||
| 37 | struct device *dev; | ||
| 38 | }; | ||
| 39 | |||
| 40 | #define A11S_CLK_CNTL_ADDR (MSM_CSR_BASE + 0x100) | ||
| 41 | #define A11S_CLK_SEL_ADDR (MSM_CSR_BASE + 0x104) | ||
| 42 | #define A11S_VDD_SVS_PLEVEL_ADDR (MSM_CSR_BASE + 0x124) | ||
| 43 | |||
| 44 | extern struct clk msm_clocks[]; | ||
| 45 | extern unsigned msm_num_clocks; | ||
| 46 | |||
| 47 | #endif | ||
| 48 | |||
diff --git a/arch/arm/mach-msm/common.c b/arch/arm/mach-msm/common.c deleted file mode 100644 index 604f8ade9587..000000000000 --- a/arch/arm/mach-msm/common.c +++ /dev/null | |||
| @@ -1,116 +0,0 @@ | |||
| 1 | /* linux/arch/arm/mach-msm/common.c | ||
| 2 | * | ||
| 3 | * Common setup code for MSM7K Boards | ||
| 4 | * | ||
| 5 | * Copyright (C) 2007 Google, Inc. | ||
| 6 | * Author: Brian Swetland <swetland@google.com> | ||
| 7 | * | ||
| 8 | * This software is licensed under the terms of the GNU General Public | ||
| 9 | * License version 2, as published by the Free Software Foundation, and | ||
| 10 | * may be copied, distributed, and modified under those terms. | ||
| 11 | * | ||
| 12 | * This program is distributed in the hope that it will be useful, | ||
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 15 | * GNU General Public License for more details. | ||
| 16 | * | ||
| 17 | */ | ||
| 18 | |||
| 19 | #include <linux/kernel.h> | ||
| 20 | #include <linux/init.h> | ||
| 21 | #include <linux/platform_device.h> | ||
| 22 | #include <linux/io.h> | ||
| 23 | |||
| 24 | #include <asm/mach/flash.h> | ||
| 25 | |||
| 26 | #include <asm/setup.h> | ||
| 27 | |||
| 28 | #include <linux/mtd/nand.h> | ||
| 29 | #include <linux/mtd/partitions.h> | ||
| 30 | |||
| 31 | #include <mach/msm_iomap.h> | ||
| 32 | |||
| 33 | #include <mach/board.h> | ||
| 34 | |||
| 35 | struct flash_platform_data msm_nand_data = { | ||
| 36 | .parts = 0, | ||
| 37 | .nr_parts = 0, | ||
| 38 | }; | ||
| 39 | |||
| 40 | static struct resource msm_nand_resources[] = { | ||
| 41 | [0] = { | ||
| 42 | .start = 7, | ||
| 43 | .end = 7, | ||
| 44 | .flags = IORESOURCE_DMA, | ||
| 45 | }, | ||
| 46 | }; | ||
| 47 | |||
| 48 | static struct platform_device msm_nand_device = { | ||
| 49 | .name = "msm_nand", | ||
| 50 | .id = -1, | ||
| 51 | .num_resources = ARRAY_SIZE(msm_nand_resources), | ||
| 52 | .resource = msm_nand_resources, | ||
| 53 | .dev = { | ||
| 54 | .platform_data = &msm_nand_data, | ||
| 55 | }, | ||
| 56 | }; | ||
| 57 | |||
| 58 | static struct platform_device msm_smd_device = { | ||
| 59 | .name = "msm_smd", | ||
| 60 | .id = -1, | ||
| 61 | }; | ||
| 62 | |||
| 63 | static struct resource msm_i2c_resources[] = { | ||
| 64 | { | ||
| 65 | .start = MSM_I2C_BASE, | ||
| 66 | .end = MSM_I2C_BASE + MSM_I2C_SIZE - 1, | ||
| 67 | .flags = IORESOURCE_MEM, | ||
| 68 | }, | ||
| 69 | { | ||
| 70 | .start = INT_PWB_I2C, | ||
| 71 | .end = INT_PWB_I2C, | ||
| 72 | .flags = IORESOURCE_IRQ, | ||
| 73 | }, | ||
| 74 | }; | ||
| 75 | |||
| 76 | static struct platform_device msm_i2c_device = { | ||
| 77 | .name = "msm_i2c", | ||
| 78 | .id = 0, | ||
| 79 | .num_resources = ARRAY_SIZE(msm_i2c_resources), | ||
| 80 | .resource = msm_i2c_resources, | ||
| 81 | }; | ||
| 82 | |||
| 83 | static struct resource usb_resources[] = { | ||
| 84 | { | ||
| 85 | .start = MSM_HSUSB_PHYS, | ||
| 86 | .end = MSM_HSUSB_PHYS + MSM_HSUSB_SIZE, | ||
| 87 | .flags = IORESOURCE_MEM, | ||
| 88 | }, | ||
| 89 | { | ||
| 90 | .start = INT_USB_HS, | ||
| 91 | .end = INT_USB_HS, | ||
| 92 | .flags = IORESOURCE_IRQ, | ||
| 93 | }, | ||
| 94 | }; | ||
| 95 | |||
| 96 | static struct platform_device msm_hsusb_device = { | ||
| 97 | .name = "msm_hsusb", | ||
| 98 | .id = -1, | ||
| 99 | .num_resources = ARRAY_SIZE(usb_resources), | ||
| 100 | .resource = usb_resources, | ||
| 101 | .dev = { | ||
| 102 | .coherent_dma_mask = 0xffffffff, | ||
| 103 | }, | ||
| 104 | }; | ||
| 105 | |||
| 106 | static struct platform_device *devices[] __initdata = { | ||
| 107 | &msm_nand_device, | ||
| 108 | &msm_smd_device, | ||
| 109 | &msm_i2c_device, | ||
| 110 | &msm_hsusb_device, | ||
| 111 | }; | ||
| 112 | |||
| 113 | void __init msm_add_devices(void) | ||
| 114 | { | ||
| 115 | platform_add_devices(devices, ARRAY_SIZE(devices)); | ||
| 116 | } | ||
diff --git a/arch/arm/mach-msm/devices.c b/arch/arm/mach-msm/devices.c new file mode 100644 index 000000000000..f2a74b92a97f --- /dev/null +++ b/arch/arm/mach-msm/devices.c | |||
| @@ -0,0 +1,267 @@ | |||
| 1 | /* linux/arch/arm/mach-msm/devices.c | ||
| 2 | * | ||
| 3 | * Copyright (C) 2008 Google, Inc. | ||
| 4 | * | ||
| 5 | * This software is licensed under the terms of the GNU General Public | ||
| 6 | * License version 2, as published by the Free Software Foundation, and | ||
| 7 | * may be copied, distributed, and modified under those terms. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | */ | ||
| 15 | |||
| 16 | #include <linux/kernel.h> | ||
| 17 | #include <linux/platform_device.h> | ||
| 18 | |||
| 19 | #include <mach/msm_iomap.h> | ||
| 20 | #include "devices.h" | ||
| 21 | |||
| 22 | #include <asm/mach/flash.h> | ||
| 23 | #include <linux/mtd/nand.h> | ||
| 24 | #include <linux/mtd/partitions.h> | ||
| 25 | |||
| 26 | static struct resource resources_uart1[] = { | ||
| 27 | { | ||
| 28 | .start = INT_UART1, | ||
| 29 | .end = INT_UART1, | ||
| 30 | .flags = IORESOURCE_IRQ, | ||
| 31 | }, | ||
| 32 | { | ||
| 33 | .start = MSM_UART1_PHYS, | ||
| 34 | .end = MSM_UART1_PHYS + MSM_UART1_SIZE - 1, | ||
| 35 | .flags = IORESOURCE_MEM, | ||
| 36 | }, | ||
| 37 | }; | ||
| 38 | |||
| 39 | static struct resource resources_uart2[] = { | ||
| 40 | { | ||
| 41 | .start = INT_UART2, | ||
| 42 | .end = INT_UART2, | ||
| 43 | .flags = IORESOURCE_IRQ, | ||
| 44 | }, | ||
| 45 | { | ||
| 46 | .start = MSM_UART2_PHYS, | ||
| 47 | .end = MSM_UART2_PHYS + MSM_UART2_SIZE - 1, | ||
| 48 | .flags = IORESOURCE_MEM, | ||
| 49 | }, | ||
| 50 | }; | ||
| 51 | |||
| 52 | static struct resource resources_uart3[] = { | ||
| 53 | { | ||
| 54 | .start = INT_UART3, | ||
| 55 | .end = INT_UART3, | ||
| 56 | .flags = IORESOURCE_IRQ, | ||
| 57 | }, | ||
| 58 | { | ||
| 59 | .start = MSM_UART3_PHYS, | ||
| 60 | .end = MSM_UART3_PHYS + MSM_UART3_SIZE - 1, | ||
| 61 | .flags = IORESOURCE_MEM, | ||
| 62 | }, | ||
| 63 | }; | ||
| 64 | |||
| 65 | struct platform_device msm_device_uart1 = { | ||
| 66 | .name = "msm_serial", | ||
| 67 | .id = 0, | ||
| 68 | .num_resources = ARRAY_SIZE(resources_uart1), | ||
| 69 | .resource = resources_uart1, | ||
| 70 | }; | ||
| 71 | |||
| 72 | struct platform_device msm_device_uart2 = { | ||
| 73 | .name = "msm_serial", | ||
| 74 | .id = 1, | ||
| 75 | .num_resources = ARRAY_SIZE(resources_uart2), | ||
| 76 | .resource = resources_uart2, | ||
| 77 | }; | ||
| 78 | |||
| 79 | struct platform_device msm_device_uart3 = { | ||
| 80 | .name = "msm_serial", | ||
| 81 | .id = 2, | ||
| 82 | .num_resources = ARRAY_SIZE(resources_uart3), | ||
| 83 | .resource = resources_uart3, | ||
| 84 | }; | ||
| 85 | |||
| 86 | static struct resource resources_i2c[] = { | ||
| 87 | { | ||
| 88 | .start = MSM_I2C_PHYS, | ||
| 89 | .end = MSM_I2C_PHYS + MSM_I2C_SIZE - 1, | ||
| 90 | .flags = IORESOURCE_MEM, | ||
| 91 | }, | ||
| 92 | { | ||
| 93 | .start = INT_PWB_I2C, | ||
| 94 | .end = INT_PWB_I2C, | ||
| 95 | .flags = IORESOURCE_IRQ, | ||
| 96 | }, | ||
| 97 | }; | ||
| 98 | |||
| 99 | struct platform_device msm_device_i2c = { | ||
| 100 | .name = "msm_i2c", | ||
| 101 | .id = 0, | ||
| 102 | .num_resources = ARRAY_SIZE(resources_i2c), | ||
| 103 | .resource = resources_i2c, | ||
| 104 | }; | ||
| 105 | |||
| 106 | static struct resource resources_hsusb[] = { | ||
| 107 | { | ||
| 108 | .start = MSM_HSUSB_PHYS, | ||
| 109 | .end = MSM_HSUSB_PHYS + MSM_HSUSB_SIZE, | ||
| 110 | .flags = IORESOURCE_MEM, | ||
| 111 | }, | ||
| 112 | { | ||
| 113 | .start = INT_USB_HS, | ||
| 114 | .end = INT_USB_HS, | ||
| 115 | .flags = IORESOURCE_IRQ, | ||
| 116 | }, | ||
| 117 | }; | ||
| 118 | |||
| 119 | struct platform_device msm_device_hsusb = { | ||
| 120 | .name = "msm_hsusb", | ||
| 121 | .id = -1, | ||
| 122 | .num_resources = ARRAY_SIZE(resources_hsusb), | ||
| 123 | .resource = resources_hsusb, | ||
| 124 | .dev = { | ||
| 125 | .coherent_dma_mask = 0xffffffff, | ||
| 126 | }, | ||
| 127 | }; | ||
| 128 | |||
| 129 | struct flash_platform_data msm_nand_data = { | ||
| 130 | .parts = NULL, | ||
| 131 | .nr_parts = 0, | ||
| 132 | }; | ||
| 133 | |||
| 134 | static struct resource resources_nand[] = { | ||
| 135 | [0] = { | ||
| 136 | .start = 7, | ||
| 137 | .end = 7, | ||
| 138 | .flags = IORESOURCE_DMA, | ||
| 139 | }, | ||
| 140 | }; | ||
| 141 | |||
| 142 | struct platform_device msm_device_nand = { | ||
| 143 | .name = "msm_nand", | ||
| 144 | .id = -1, | ||
| 145 | .num_resources = ARRAY_SIZE(resources_nand), | ||
| 146 | .resource = resources_nand, | ||
| 147 | .dev = { | ||
| 148 | .platform_data = &msm_nand_data, | ||
| 149 | }, | ||
| 150 | }; | ||
| 151 | |||
| 152 | struct platform_device msm_device_smd = { | ||
| 153 | .name = "msm_smd", | ||
| 154 | .id = -1, | ||
| 155 | }; | ||
| 156 | |||
| 157 | static struct resource resources_sdc1[] = { | ||
| 158 | { | ||
| 159 | .start = MSM_SDC1_PHYS, | ||
| 160 | .end = MSM_SDC1_PHYS + MSM_SDC1_SIZE - 1, | ||
| 161 | .flags = IORESOURCE_MEM, | ||
| 162 | }, | ||
| 163 | { | ||
| 164 | .start = INT_SDC1_0, | ||
| 165 | .end = INT_SDC1_1, | ||
| 166 | .flags = IORESOURCE_IRQ, | ||
| 167 | }, | ||
| 168 | { | ||
| 169 | .start = 8, | ||
| 170 | .end = 8, | ||
| 171 | .flags = IORESOURCE_DMA, | ||
| 172 | }, | ||
| 173 | }; | ||
| 174 | |||
| 175 | static struct resource resources_sdc2[] = { | ||
| 176 | { | ||
| 177 | .start = MSM_SDC2_PHYS, | ||
| 178 | .end = MSM_SDC2_PHYS + MSM_SDC2_SIZE - 1, | ||
| 179 | .flags = IORESOURCE_MEM, | ||
| 180 | }, | ||
| 181 | { | ||
| 182 | .start = INT_SDC2_0, | ||
| 183 | .end = INT_SDC2_1, | ||
| 184 | .flags = IORESOURCE_IRQ, | ||
| 185 | }, | ||
| 186 | { | ||
| 187 | .start = 8, | ||
| 188 | .end = 8, | ||
| 189 | .flags = IORESOURCE_DMA, | ||
| 190 | }, | ||
| 191 | }; | ||
| 192 | |||
| 193 | static struct resource resources_sdc3[] = { | ||
| 194 | { | ||
| 195 | .start = MSM_SDC3_PHYS, | ||
| 196 | .end = MSM_SDC3_PHYS + MSM_SDC3_SIZE - 1, | ||
| 197 | .flags = IORESOURCE_MEM, | ||
| 198 | }, | ||
| 199 | { | ||
| 200 | .start = INT_SDC3_0, | ||
| 201 | .end = INT_SDC3_1, | ||
| 202 | .flags = IORESOURCE_IRQ, | ||
| 203 | }, | ||
| 204 | { | ||
| 205 | .start = 8, | ||
| 206 | .end = 8, | ||
| 207 | .flags = IORESOURCE_DMA, | ||
| 208 | }, | ||
| 209 | }; | ||
| 210 | |||
| 211 | static struct resource resources_sdc4[] = { | ||
| 212 | { | ||
| 213 | .start = MSM_SDC4_PHYS, | ||
| 214 | .end = MSM_SDC4_PHYS + MSM_SDC4_SIZE - 1, | ||
| 215 | .flags = IORESOURCE_MEM, | ||
| 216 | }, | ||
| 217 | { | ||
| 218 | .start = INT_SDC4_0, | ||
| 219 | .end = INT_SDC4_1, | ||
| 220 | .flags = IORESOURCE_IRQ, | ||
| 221 | }, | ||
| 222 | { | ||
| 223 | .start = 8, | ||
| 224 | .end = 8, | ||
| 225 | .flags = IORESOURCE_DMA, | ||
| 226 | }, | ||
| 227 | }; | ||
| 228 | |||
| 229 | struct platform_device msm_device_sdc1 = { | ||
| 230 | .name = "msm_sdcc", | ||
| 231 | .id = 1, | ||
| 232 | .num_resources = ARRAY_SIZE(resources_sdc1), | ||
| 233 | .resource = resources_sdc1, | ||
| 234 | .dev = { | ||
| 235 | .coherent_dma_mask = 0xffffffff, | ||
| 236 | }, | ||
| 237 | }; | ||
| 238 | |||
| 239 | struct platform_device msm_device_sdc2 = { | ||
| 240 | .name = "msm_sdcc", | ||
| 241 | .id = 2, | ||
| 242 | .num_resources = ARRAY_SIZE(resources_sdc2), | ||
| 243 | .resource = resources_sdc2, | ||
| 244 | .dev = { | ||
| 245 | .coherent_dma_mask = 0xffffffff, | ||
| 246 | }, | ||
| 247 | }; | ||
| 248 | |||
| 249 | struct platform_device msm_device_sdc3 = { | ||
| 250 | .name = "msm_sdcc", | ||
| 251 | .id = 3, | ||
| 252 | .num_resources = ARRAY_SIZE(resources_sdc3), | ||
| 253 | .resource = resources_sdc3, | ||
| 254 | .dev = { | ||
| 255 | .coherent_dma_mask = 0xffffffff, | ||
| 256 | }, | ||
| 257 | }; | ||
| 258 | |||
| 259 | struct platform_device msm_device_sdc4 = { | ||
| 260 | .name = "msm_sdcc", | ||
| 261 | .id = 4, | ||
| 262 | .num_resources = ARRAY_SIZE(resources_sdc4), | ||
| 263 | .resource = resources_sdc4, | ||
| 264 | .dev = { | ||
| 265 | .coherent_dma_mask = 0xffffffff, | ||
| 266 | }, | ||
| 267 | }; | ||
diff --git a/arch/arm/mach-msm/devices.h b/arch/arm/mach-msm/devices.h new file mode 100644 index 000000000000..0744c4a27d6a --- /dev/null +++ b/arch/arm/mach-msm/devices.h | |||
| @@ -0,0 +1,36 @@ | |||
| 1 | /* linux/arch/arm/mach-msm/devices.h | ||
| 2 | * | ||
| 3 | * Copyright (C) 2008 Google, Inc. | ||
| 4 | * | ||
| 5 | * This software is licensed under the terms of the GNU General Public | ||
| 6 | * License version 2, as published by the Free Software Foundation, and | ||
| 7 | * may be copied, distributed, and modified under those terms. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | */ | ||
| 15 | |||
| 16 | #ifndef __ARCH_ARM_MACH_MSM_DEVICES_H | ||
| 17 | #define __ARCH_ARM_MACH_MSM_DEVICES_H | ||
| 18 | |||
| 19 | extern struct platform_device msm_device_uart1; | ||
| 20 | extern struct platform_device msm_device_uart2; | ||
| 21 | extern struct platform_device msm_device_uart3; | ||
| 22 | |||
| 23 | extern struct platform_device msm_device_sdc1; | ||
| 24 | extern struct platform_device msm_device_sdc2; | ||
| 25 | extern struct platform_device msm_device_sdc3; | ||
| 26 | extern struct platform_device msm_device_sdc4; | ||
| 27 | |||
| 28 | extern struct platform_device msm_device_hsusb; | ||
| 29 | |||
| 30 | extern struct platform_device msm_device_i2c; | ||
| 31 | |||
| 32 | extern struct platform_device msm_device_smd; | ||
| 33 | |||
| 34 | extern struct platform_device msm_device_nand; | ||
| 35 | |||
| 36 | #endif | ||
diff --git a/arch/arm/mach-msm/dma.c b/arch/arm/mach-msm/dma.c index 0c8f252637e1..f5420f9585c5 100644 --- a/arch/arm/mach-msm/dma.c +++ b/arch/arm/mach-msm/dma.c | |||
| @@ -26,7 +26,7 @@ enum { | |||
| 26 | }; | 26 | }; |
| 27 | 27 | ||
| 28 | static DEFINE_SPINLOCK(msm_dmov_lock); | 28 | static DEFINE_SPINLOCK(msm_dmov_lock); |
| 29 | static struct msm_dmov_cmd active_command; | 29 | static unsigned int channel_active; |
| 30 | static struct list_head ready_commands[MSM_DMOV_CHANNEL_COUNT]; | 30 | static struct list_head ready_commands[MSM_DMOV_CHANNEL_COUNT]; |
| 31 | static struct list_head active_commands[MSM_DMOV_CHANNEL_COUNT]; | 31 | static struct list_head active_commands[MSM_DMOV_CHANNEL_COUNT]; |
| 32 | unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; | 32 | unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; |
| @@ -43,6 +43,11 @@ unsigned int msm_dmov_print_mask = MSM_DMOV_PRINT_ERRORS; | |||
| 43 | #define PRINT_FLOW(format, args...) \ | 43 | #define PRINT_FLOW(format, args...) \ |
| 44 | MSM_DMOV_DPRINTF(MSM_DMOV_PRINT_FLOW, format, args); | 44 | MSM_DMOV_DPRINTF(MSM_DMOV_PRINT_FLOW, format, args); |
| 45 | 45 | ||
| 46 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd, int graceful) | ||
| 47 | { | ||
| 48 | writel((graceful << 31), DMOV_FLUSH0(id)); | ||
| 49 | } | ||
| 50 | |||
| 46 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) | 51 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) |
| 47 | { | 52 | { |
| 48 | unsigned long irq_flags; | 53 | unsigned long irq_flags; |
| @@ -60,6 +65,9 @@ void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd) | |||
| 60 | #endif | 65 | #endif |
| 61 | PRINT_IO("msm_dmov_enqueue_cmd(%d), start command, status %x\n", id, status); | 66 | PRINT_IO("msm_dmov_enqueue_cmd(%d), start command, status %x\n", id, status); |
| 62 | list_add_tail(&cmd->list, &active_commands[id]); | 67 | list_add_tail(&cmd->list, &active_commands[id]); |
| 68 | if (!channel_active) | ||
| 69 | enable_irq(INT_ADM_AARM); | ||
| 70 | channel_active |= 1U << id; | ||
| 63 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); | 71 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); |
| 64 | } else { | 72 | } else { |
| 65 | if (list_empty(&active_commands[id])) | 73 | if (list_empty(&active_commands[id])) |
| @@ -76,21 +84,19 @@ struct msm_dmov_exec_cmdptr_cmd { | |||
| 76 | struct completion complete; | 84 | struct completion complete; |
| 77 | unsigned id; | 85 | unsigned id; |
| 78 | unsigned int result; | 86 | unsigned int result; |
| 79 | unsigned int flush[6]; | 87 | struct msm_dmov_errdata err; |
| 80 | }; | 88 | }; |
| 81 | 89 | ||
| 82 | static void dmov_exec_cmdptr_complete_func(struct msm_dmov_cmd *_cmd, unsigned int result) | 90 | static void |
| 91 | dmov_exec_cmdptr_complete_func(struct msm_dmov_cmd *_cmd, | ||
| 92 | unsigned int result, | ||
| 93 | struct msm_dmov_errdata *err) | ||
| 83 | { | 94 | { |
| 84 | struct msm_dmov_exec_cmdptr_cmd *cmd = container_of(_cmd, struct msm_dmov_exec_cmdptr_cmd, dmov_cmd); | 95 | struct msm_dmov_exec_cmdptr_cmd *cmd = container_of(_cmd, struct msm_dmov_exec_cmdptr_cmd, dmov_cmd); |
| 85 | cmd->result = result; | 96 | cmd->result = result; |
| 86 | if (result != 0x80000002) { | 97 | if (result != 0x80000002 && err) |
| 87 | cmd->flush[0] = readl(DMOV_FLUSH0(cmd->id)); | 98 | memcpy(&cmd->err, err, sizeof(struct msm_dmov_errdata)); |
| 88 | cmd->flush[1] = readl(DMOV_FLUSH1(cmd->id)); | 99 | |
| 89 | cmd->flush[2] = readl(DMOV_FLUSH2(cmd->id)); | ||
| 90 | cmd->flush[3] = readl(DMOV_FLUSH3(cmd->id)); | ||
| 91 | cmd->flush[4] = readl(DMOV_FLUSH4(cmd->id)); | ||
| 92 | cmd->flush[5] = readl(DMOV_FLUSH5(cmd->id)); | ||
| 93 | } | ||
| 94 | complete(&cmd->complete); | 100 | complete(&cmd->complete); |
| 95 | } | 101 | } |
| 96 | 102 | ||
| @@ -111,7 +117,7 @@ int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr) | |||
| 111 | if (cmd.result != 0x80000002) { | 117 | if (cmd.result != 0x80000002) { |
| 112 | PRINT_ERROR("dmov_exec_cmdptr(%d): ERROR, result: %x\n", id, cmd.result); | 118 | PRINT_ERROR("dmov_exec_cmdptr(%d): ERROR, result: %x\n", id, cmd.result); |
| 113 | PRINT_ERROR("dmov_exec_cmdptr(%d): flush: %x %x %x %x\n", | 119 | PRINT_ERROR("dmov_exec_cmdptr(%d): flush: %x %x %x %x\n", |
| 114 | id, cmd.flush[0], cmd.flush[1], cmd.flush[2], cmd.flush[3]); | 120 | id, cmd.err.flush[0], cmd.err.flush[1], cmd.err.flush[2], cmd.err.flush[3]); |
| 115 | return -EIO; | 121 | return -EIO; |
| 116 | } | 122 | } |
| 117 | PRINT_FLOW("dmov_exec_cmdptr(%d, %x) done\n", id, cmdptr); | 123 | PRINT_FLOW("dmov_exec_cmdptr(%d, %x) done\n", id, cmdptr); |
| @@ -159,25 +165,40 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
| 159 | "for %p, result %x\n", id, cmd, ch_result); | 165 | "for %p, result %x\n", id, cmd, ch_result); |
| 160 | if (cmd) { | 166 | if (cmd) { |
| 161 | list_del(&cmd->list); | 167 | list_del(&cmd->list); |
| 162 | cmd->complete_func(cmd, ch_result); | 168 | cmd->complete_func(cmd, ch_result, NULL); |
| 163 | } | 169 | } |
| 164 | } | 170 | } |
| 165 | if (ch_result & DMOV_RSLT_FLUSH) { | 171 | if (ch_result & DMOV_RSLT_FLUSH) { |
| 166 | unsigned int flush0 = readl(DMOV_FLUSH0(id)); | 172 | struct msm_dmov_errdata errdata; |
| 173 | |||
| 174 | errdata.flush[0] = readl(DMOV_FLUSH0(id)); | ||
| 175 | errdata.flush[1] = readl(DMOV_FLUSH1(id)); | ||
| 176 | errdata.flush[2] = readl(DMOV_FLUSH2(id)); | ||
| 177 | errdata.flush[3] = readl(DMOV_FLUSH3(id)); | ||
| 178 | errdata.flush[4] = readl(DMOV_FLUSH4(id)); | ||
| 179 | errdata.flush[5] = readl(DMOV_FLUSH5(id)); | ||
| 167 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 180 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
| 168 | PRINT_FLOW("msm_datamover_irq_handler id %d, flush, result %x, flush0 %x\n", id, ch_result, flush0); | 181 | PRINT_FLOW("msm_datamover_irq_handler id %d, flush, result %x, flush0 %x\n", id, ch_result, errdata.flush[0]); |
| 169 | if (cmd) { | 182 | if (cmd) { |
| 170 | list_del(&cmd->list); | 183 | list_del(&cmd->list); |
| 171 | cmd->complete_func(cmd, ch_result); | 184 | cmd->complete_func(cmd, ch_result, &errdata); |
| 172 | } | 185 | } |
| 173 | } | 186 | } |
| 174 | if (ch_result & DMOV_RSLT_ERROR) { | 187 | if (ch_result & DMOV_RSLT_ERROR) { |
| 175 | unsigned int flush0 = readl(DMOV_FLUSH0(id)); | 188 | struct msm_dmov_errdata errdata; |
| 189 | |||
| 190 | errdata.flush[0] = readl(DMOV_FLUSH0(id)); | ||
| 191 | errdata.flush[1] = readl(DMOV_FLUSH1(id)); | ||
| 192 | errdata.flush[2] = readl(DMOV_FLUSH2(id)); | ||
| 193 | errdata.flush[3] = readl(DMOV_FLUSH3(id)); | ||
| 194 | errdata.flush[4] = readl(DMOV_FLUSH4(id)); | ||
| 195 | errdata.flush[5] = readl(DMOV_FLUSH5(id)); | ||
| 196 | |||
| 176 | PRINT_ERROR("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 197 | PRINT_ERROR("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
| 177 | PRINT_ERROR("msm_datamover_irq_handler id %d, error, result %x, flush0 %x\n", id, ch_result, flush0); | 198 | PRINT_ERROR("msm_datamover_irq_handler id %d, error, result %x, flush0 %x\n", id, ch_result, errdata.flush[0]); |
| 178 | if (cmd) { | 199 | if (cmd) { |
| 179 | list_del(&cmd->list); | 200 | list_del(&cmd->list); |
| 180 | cmd->complete_func(cmd, ch_result); | 201 | cmd->complete_func(cmd, ch_result, &errdata); |
| 181 | } | 202 | } |
| 182 | /* this does not seem to work, once we get an error */ | 203 | /* this does not seem to work, once we get an error */ |
| 183 | /* the datamover will no longer accept commands */ | 204 | /* the datamover will no longer accept commands */ |
| @@ -193,8 +214,14 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
| 193 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); | 214 | writel(cmd->cmdptr, DMOV_CMD_PTR(id)); |
| 194 | } | 215 | } |
| 195 | } while (ch_status & DMOV_STATUS_RSLT_VALID); | 216 | } while (ch_status & DMOV_STATUS_RSLT_VALID); |
| 217 | if (list_empty(&active_commands[id]) && list_empty(&ready_commands[id])) | ||
| 218 | channel_active &= ~(1U << id); | ||
| 196 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); | 219 | PRINT_FLOW("msm_datamover_irq_handler id %d, status %x\n", id, ch_status); |
| 197 | } | 220 | } |
| 221 | |||
| 222 | if (!channel_active) | ||
| 223 | disable_irq(INT_ADM_AARM); | ||
| 224 | |||
| 198 | spin_unlock_irqrestore(&msm_dmov_lock, irq_flags); | 225 | spin_unlock_irqrestore(&msm_dmov_lock, irq_flags); |
| 199 | return IRQ_HANDLED; | 226 | return IRQ_HANDLED; |
| 200 | } | 227 | } |
| @@ -202,12 +229,17 @@ static irqreturn_t msm_datamover_irq_handler(int irq, void *dev_id) | |||
| 202 | static int __init msm_init_datamover(void) | 229 | static int __init msm_init_datamover(void) |
| 203 | { | 230 | { |
| 204 | int i; | 231 | int i; |
| 232 | int ret; | ||
| 205 | for (i = 0; i < MSM_DMOV_CHANNEL_COUNT; i++) { | 233 | for (i = 0; i < MSM_DMOV_CHANNEL_COUNT; i++) { |
| 206 | INIT_LIST_HEAD(&ready_commands[i]); | 234 | INIT_LIST_HEAD(&ready_commands[i]); |
| 207 | INIT_LIST_HEAD(&active_commands[i]); | 235 | INIT_LIST_HEAD(&active_commands[i]); |
| 208 | writel(DMOV_CONFIG_IRQ_EN | DMOV_CONFIG_FORCE_TOP_PTR_RSLT | DMOV_CONFIG_FORCE_FLUSH_RSLT, DMOV_CONFIG(i)); | 236 | writel(DMOV_CONFIG_IRQ_EN | DMOV_CONFIG_FORCE_TOP_PTR_RSLT | DMOV_CONFIG_FORCE_FLUSH_RSLT, DMOV_CONFIG(i)); |
| 209 | } | 237 | } |
| 210 | return request_irq(INT_ADM_AARM, msm_datamover_irq_handler, 0, "msmdatamover", NULL); | 238 | ret = request_irq(INT_ADM_AARM, msm_datamover_irq_handler, 0, "msmdatamover", NULL); |
| 239 | if (ret) | ||
| 240 | return ret; | ||
| 241 | disable_irq(INT_ADM_AARM); | ||
| 242 | return 0; | ||
| 211 | } | 243 | } |
| 212 | 244 | ||
| 213 | arch_initcall(msm_init_datamover); | 245 | arch_initcall(msm_init_datamover); |
diff --git a/arch/arm/mach-msm/include/mach/board.h b/arch/arm/mach-msm/include/mach/board.h index a7639493c095..264d62e519f3 100644 --- a/arch/arm/mach-msm/include/mach/board.h +++ b/arch/arm/mach-msm/include/mach/board.h | |||
| @@ -33,5 +33,6 @@ void __init msm_add_devices(void); | |||
| 33 | void __init msm_map_common_io(void); | 33 | void __init msm_map_common_io(void); |
| 34 | void __init msm_init_irq(void); | 34 | void __init msm_init_irq(void); |
| 35 | void __init msm_init_gpio(void); | 35 | void __init msm_init_gpio(void); |
| 36 | void __init msm_clock_init(void); | ||
| 36 | 37 | ||
| 37 | #endif | 38 | #endif |
diff --git a/arch/arm/mach-msm/include/mach/debug-macro.S b/arch/arm/mach-msm/include/mach/debug-macro.S index 528eef4b605c..1db3c97dbc49 100644 --- a/arch/arm/mach-msm/include/mach/debug-macro.S +++ b/arch/arm/mach-msm/include/mach/debug-macro.S | |||
| @@ -22,18 +22,22 @@ | |||
| 22 | mrc p15, 0, \rx, c1, c0 | 22 | mrc p15, 0, \rx, c1, c0 |
| 23 | tst \rx, #1 | 23 | tst \rx, #1 |
| 24 | ldreq \rx, =MSM_UART1_PHYS | 24 | ldreq \rx, =MSM_UART1_PHYS |
| 25 | ldrne \rx, =MSM_UART1_BASE | 25 | movne \rx, #0 |
| 26 | .endm | 26 | .endm |
| 27 | 27 | ||
| 28 | .macro senduart,rd,rx | 28 | .macro senduart,rd,rx |
| 29 | str \rd, [\rx, #0x0C] | 29 | teq \rx, #0 |
| 30 | strne \rd, [\rx, #0x0C] | ||
| 30 | .endm | 31 | .endm |
| 31 | 32 | ||
| 32 | .macro waituart,rd,rx | 33 | .macro waituart,rd,rx |
| 33 | @ wait for TX_READY | 34 | @ wait for TX_READY |
| 35 | teq \rx, #0 | ||
| 36 | bne 2f | ||
| 34 | 1: ldr \rd, [\rx, #0x08] | 37 | 1: ldr \rd, [\rx, #0x08] |
| 35 | tst \rd, #0x04 | 38 | tst \rd, #0x04 |
| 36 | beq 1b | 39 | beq 1b |
| 40 | 2: | ||
| 37 | .endm | 41 | .endm |
| 38 | 42 | ||
| 39 | .macro busyuart,rd,rx | 43 | .macro busyuart,rd,rx |
diff --git a/arch/arm/mach-msm/include/mach/dma.h b/arch/arm/mach-msm/include/mach/dma.h index ad1c87f86d10..5ab5bdffab07 100644 --- a/arch/arm/mach-msm/include/mach/dma.h +++ b/arch/arm/mach-msm/include/mach/dma.h | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* arch/arm/mach-msm/include/mach/dma.h | 1 | /* linux/include/asm-arm/arch-msm/dma.h |
| 2 | * | 2 | * |
| 3 | * Copyright (C) 2007 Google, Inc. | 3 | * Copyright (C) 2007 Google, Inc. |
| 4 | * | 4 | * |
| @@ -18,17 +18,21 @@ | |||
| 18 | #include <linux/list.h> | 18 | #include <linux/list.h> |
| 19 | #include <mach/msm_iomap.h> | 19 | #include <mach/msm_iomap.h> |
| 20 | 20 | ||
| 21 | struct msm_dmov_errdata { | ||
| 22 | uint32_t flush[6]; | ||
| 23 | }; | ||
| 24 | |||
| 21 | struct msm_dmov_cmd { | 25 | struct msm_dmov_cmd { |
| 22 | struct list_head list; | 26 | struct list_head list; |
| 23 | unsigned int cmdptr; | 27 | unsigned int cmdptr; |
| 24 | void (*complete_func)(struct msm_dmov_cmd *cmd, unsigned int result); | 28 | void (*complete_func)(struct msm_dmov_cmd *cmd, |
| 25 | /* void (*user_result_func)(struct msm_dmov_cmd *cmd); */ | 29 | unsigned int result, |
| 30 | struct msm_dmov_errdata *err); | ||
| 26 | }; | 31 | }; |
| 27 | 32 | ||
| 28 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd); | 33 | void msm_dmov_enqueue_cmd(unsigned id, struct msm_dmov_cmd *cmd); |
| 29 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd); | 34 | void msm_dmov_stop_cmd(unsigned id, struct msm_dmov_cmd *cmd, int graceful); |
| 30 | int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr); | 35 | int msm_dmov_exec_cmd(unsigned id, unsigned int cmdptr); |
| 31 | /* int msm_dmov_exec_cmd_etc(unsigned id, unsigned int cmdptr, int timeout, int interruptible); */ | ||
| 32 | 36 | ||
| 33 | 37 | ||
| 34 | 38 | ||
| @@ -122,6 +126,16 @@ typedef struct { | |||
| 122 | unsigned _reserved; | 126 | unsigned _reserved; |
| 123 | } dmov_sg; | 127 | } dmov_sg; |
| 124 | 128 | ||
| 129 | /* Box mode */ | ||
| 130 | typedef struct { | ||
| 131 | uint32_t cmd; | ||
| 132 | uint32_t src_row_addr; | ||
| 133 | uint32_t dst_row_addr; | ||
| 134 | uint32_t src_dst_len; | ||
| 135 | uint32_t num_rows; | ||
| 136 | uint32_t row_offset; | ||
| 137 | } dmov_box; | ||
| 138 | |||
| 125 | /* bits for the cmd field of the above structures */ | 139 | /* bits for the cmd field of the above structures */ |
| 126 | 140 | ||
| 127 | #define CMD_LC (1 << 31) /* last command */ | 141 | #define CMD_LC (1 << 31) /* last command */ |
diff --git a/arch/arm/mach-msm/include/mach/msm_iomap.h b/arch/arm/mach-msm/include/mach/msm_iomap.h index e221f58ceea3..2f7b4c8620d9 100644 --- a/arch/arm/mach-msm/include/mach/msm_iomap.h +++ b/arch/arm/mach-msm/include/mach/msm_iomap.h | |||
| @@ -37,11 +37,17 @@ | |||
| 37 | * | 37 | * |
| 38 | */ | 38 | */ |
| 39 | 39 | ||
| 40 | #define MSM_VIC_BASE 0xE0000000 | 40 | #ifdef __ASSEMBLY__ |
| 41 | #define IOMEM(x) x | ||
| 42 | #else | ||
| 43 | #define IOMEM(x) ((void __force __iomem *)(x)) | ||
| 44 | #endif | ||
| 45 | |||
| 46 | #define MSM_VIC_BASE IOMEM(0xE0000000) | ||
| 41 | #define MSM_VIC_PHYS 0xC0000000 | 47 | #define MSM_VIC_PHYS 0xC0000000 |
| 42 | #define MSM_VIC_SIZE SZ_4K | 48 | #define MSM_VIC_SIZE SZ_4K |
| 43 | 49 | ||
| 44 | #define MSM_CSR_BASE 0xE0001000 | 50 | #define MSM_CSR_BASE IOMEM(0xE0001000) |
| 45 | #define MSM_CSR_PHYS 0xC0100000 | 51 | #define MSM_CSR_PHYS 0xC0100000 |
| 46 | #define MSM_CSR_SIZE SZ_4K | 52 | #define MSM_CSR_SIZE SZ_4K |
| 47 | 53 | ||
| @@ -49,56 +55,67 @@ | |||
| 49 | #define MSM_GPT_BASE MSM_CSR_BASE | 55 | #define MSM_GPT_BASE MSM_CSR_BASE |
| 50 | #define MSM_GPT_SIZE SZ_4K | 56 | #define MSM_GPT_SIZE SZ_4K |
| 51 | 57 | ||
| 52 | #define MSM_DMOV_BASE 0xE0002000 | 58 | #define MSM_DMOV_BASE IOMEM(0xE0002000) |
| 53 | #define MSM_DMOV_PHYS 0xA9700000 | 59 | #define MSM_DMOV_PHYS 0xA9700000 |
| 54 | #define MSM_DMOV_SIZE SZ_4K | 60 | #define MSM_DMOV_SIZE SZ_4K |
| 55 | 61 | ||
| 56 | #define MSM_UART1_BASE 0xE0003000 | 62 | #define MSM_GPIO1_BASE IOMEM(0xE0003000) |
| 63 | #define MSM_GPIO1_PHYS 0xA9200000 | ||
| 64 | #define MSM_GPIO1_SIZE SZ_4K | ||
| 65 | |||
| 66 | #define MSM_GPIO2_BASE IOMEM(0xE0004000) | ||
| 67 | #define MSM_GPIO2_PHYS 0xA9300000 | ||
| 68 | #define MSM_GPIO2_SIZE SZ_4K | ||
| 69 | |||
| 70 | #define MSM_CLK_CTL_BASE IOMEM(0xE0005000) | ||
| 71 | #define MSM_CLK_CTL_PHYS 0xA8600000 | ||
| 72 | #define MSM_CLK_CTL_SIZE SZ_4K | ||
| 73 | |||
| 74 | #define MSM_SHARED_RAM_BASE IOMEM(0xE0100000) | ||
| 75 | #define MSM_SHARED_RAM_PHYS 0x01F00000 | ||
| 76 | #define MSM_SHARED_RAM_SIZE SZ_1M | ||
| 77 | |||
| 57 | #define MSM_UART1_PHYS 0xA9A00000 | 78 | #define MSM_UART1_PHYS 0xA9A00000 |
| 58 | #define MSM_UART1_SIZE SZ_4K | 79 | #define MSM_UART1_SIZE SZ_4K |
| 59 | 80 | ||
| 60 | #define MSM_UART2_BASE 0xE0004000 | ||
| 61 | #define MSM_UART2_PHYS 0xA9B00000 | 81 | #define MSM_UART2_PHYS 0xA9B00000 |
| 62 | #define MSM_UART2_SIZE SZ_4K | 82 | #define MSM_UART2_SIZE SZ_4K |
| 63 | 83 | ||
| 64 | #define MSM_UART3_BASE 0xE0005000 | ||
| 65 | #define MSM_UART3_PHYS 0xA9C00000 | 84 | #define MSM_UART3_PHYS 0xA9C00000 |
| 66 | #define MSM_UART3_SIZE SZ_4K | 85 | #define MSM_UART3_SIZE SZ_4K |
| 67 | 86 | ||
| 68 | #define MSM_I2C_BASE 0xE0006000 | 87 | #define MSM_SDC1_PHYS 0xA0400000 |
| 69 | #define MSM_I2C_PHYS 0xA9900000 | 88 | #define MSM_SDC1_SIZE SZ_4K |
| 70 | #define MSM_I2C_SIZE SZ_4K | ||
| 71 | 89 | ||
| 72 | #define MSM_GPIO1_BASE 0xE0007000 | 90 | #define MSM_SDC2_PHYS 0xA0500000 |
| 73 | #define MSM_GPIO1_PHYS 0xA9200000 | 91 | #define MSM_SDC2_SIZE SZ_4K |
| 74 | #define MSM_GPIO1_SIZE SZ_4K | ||
| 75 | 92 | ||
| 76 | #define MSM_GPIO2_BASE 0xE0008000 | 93 | #define MSM_SDC3_PHYS 0xA0600000 |
| 77 | #define MSM_GPIO2_PHYS 0xA9300000 | 94 | #define MSM_SDC3_SIZE SZ_4K |
| 78 | #define MSM_GPIO2_SIZE SZ_4K | 95 | |
| 96 | #define MSM_SDC4_PHYS 0xA0700000 | ||
| 97 | #define MSM_SDC4_SIZE SZ_4K | ||
| 98 | |||
| 99 | #define MSM_I2C_PHYS 0xA9900000 | ||
| 100 | #define MSM_I2C_SIZE SZ_4K | ||
| 79 | 101 | ||
| 80 | #define MSM_HSUSB_BASE 0xE0009000 | ||
| 81 | #define MSM_HSUSB_PHYS 0xA0800000 | 102 | #define MSM_HSUSB_PHYS 0xA0800000 |
| 82 | #define MSM_HSUSB_SIZE SZ_4K | 103 | #define MSM_HSUSB_SIZE SZ_4K |
| 83 | 104 | ||
| 84 | #define MSM_CLK_CTL_BASE 0xE000A000 | ||
| 85 | #define MSM_CLK_CTL_PHYS 0xA8600000 | ||
| 86 | #define MSM_CLK_CTL_SIZE SZ_4K | ||
| 87 | |||
| 88 | #define MSM_PMDH_BASE 0xE000B000 | ||
| 89 | #define MSM_PMDH_PHYS 0xAA600000 | 105 | #define MSM_PMDH_PHYS 0xAA600000 |
| 90 | #define MSM_PMDH_SIZE SZ_4K | 106 | #define MSM_PMDH_SIZE SZ_4K |
| 91 | 107 | ||
| 92 | #define MSM_EMDH_BASE 0xE000C000 | ||
| 93 | #define MSM_EMDH_PHYS 0xAA700000 | 108 | #define MSM_EMDH_PHYS 0xAA700000 |
| 94 | #define MSM_EMDH_SIZE SZ_4K | 109 | #define MSM_EMDH_SIZE SZ_4K |
| 95 | 110 | ||
| 96 | #define MSM_MDP_BASE 0xE0010000 | ||
| 97 | #define MSM_MDP_PHYS 0xAA200000 | 111 | #define MSM_MDP_PHYS 0xAA200000 |
| 98 | #define MSM_MDP_SIZE 0x000F0000 | 112 | #define MSM_MDP_SIZE 0x000F0000 |
| 99 | 113 | ||
| 100 | #define MSM_SHARED_RAM_BASE 0xE0100000 | 114 | #define MSM_MDC_PHYS 0xAA500000 |
| 101 | #define MSM_SHARED_RAM_PHYS 0x01F00000 | 115 | #define MSM_MDC_SIZE SZ_1M |
| 102 | #define MSM_SHARED_RAM_SIZE SZ_1M | 116 | |
| 117 | #define MSM_AD5_PHYS 0xAC000000 | ||
| 118 | #define MSM_AD5_SIZE (SZ_1M*13) | ||
| 119 | |||
| 103 | 120 | ||
| 104 | #endif | 121 | #endif |
diff --git a/arch/arm/mach-msm/include/mach/vreg.h b/arch/arm/mach-msm/include/mach/vreg.h new file mode 100644 index 000000000000..9f9e25cb718e --- /dev/null +++ b/arch/arm/mach-msm/include/mach/vreg.h | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | /* linux/include/asm-arm/arch-msm/vreg.h | ||
| 2 | * | ||
| 3 | * Copyright (C) 2008 Google, Inc. | ||
| 4 | * Author: Brian Swetland <swetland@google.com> | ||
| 5 | * | ||
| 6 | * This software is licensed under the terms of the GNU General Public | ||
| 7 | * License version 2, as published by the Free Software Foundation, and | ||
| 8 | * may be copied, distributed, and modified under those terms. | ||
| 9 | * | ||
| 10 | * This program is distributed in the hope that it will be useful, | ||
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 13 | * GNU General Public License for more details. | ||
| 14 | * | ||
| 15 | */ | ||
| 16 | |||
| 17 | #ifndef __ARCH_ARM_MACH_MSM_VREG_H | ||
| 18 | #define __ARCH_ARM_MACH_MSM_VREG_H | ||
| 19 | |||
| 20 | struct vreg; | ||
| 21 | |||
| 22 | struct vreg *vreg_get(struct device *dev, const char *id); | ||
| 23 | void vreg_put(struct vreg *vreg); | ||
| 24 | |||
| 25 | int vreg_enable(struct vreg *vreg); | ||
| 26 | void vreg_disable(struct vreg *vreg); | ||
| 27 | int vreg_set_level(struct vreg *vreg, unsigned mv); | ||
| 28 | |||
| 29 | #endif | ||
diff --git a/arch/arm/mach-msm/io.c b/arch/arm/mach-msm/io.c index 7999e4ba8e20..6e7692ff6f2c 100644 --- a/arch/arm/mach-msm/io.c +++ b/arch/arm/mach-msm/io.c | |||
| @@ -28,7 +28,7 @@ | |||
| 28 | #include <mach/board.h> | 28 | #include <mach/board.h> |
| 29 | 29 | ||
| 30 | #define MSM_DEVICE(name) { \ | 30 | #define MSM_DEVICE(name) { \ |
| 31 | .virtual = MSM_##name##_BASE, \ | 31 | .virtual = (unsigned long) MSM_##name##_BASE, \ |
| 32 | .pfn = __phys_to_pfn(MSM_##name##_PHYS), \ | 32 | .pfn = __phys_to_pfn(MSM_##name##_PHYS), \ |
| 33 | .length = MSM_##name##_SIZE, \ | 33 | .length = MSM_##name##_SIZE, \ |
| 34 | .type = MT_DEVICE_NONSHARED, \ | 34 | .type = MT_DEVICE_NONSHARED, \ |
| @@ -39,19 +39,11 @@ static struct map_desc msm_io_desc[] __initdata = { | |||
| 39 | MSM_DEVICE(CSR), | 39 | MSM_DEVICE(CSR), |
| 40 | MSM_DEVICE(GPT), | 40 | MSM_DEVICE(GPT), |
| 41 | MSM_DEVICE(DMOV), | 41 | MSM_DEVICE(DMOV), |
| 42 | MSM_DEVICE(UART1), | ||
| 43 | MSM_DEVICE(UART2), | ||
| 44 | MSM_DEVICE(UART3), | ||
| 45 | MSM_DEVICE(I2C), | ||
| 46 | MSM_DEVICE(GPIO1), | 42 | MSM_DEVICE(GPIO1), |
| 47 | MSM_DEVICE(GPIO2), | 43 | MSM_DEVICE(GPIO2), |
| 48 | MSM_DEVICE(HSUSB), | ||
| 49 | MSM_DEVICE(CLK_CTL), | 44 | MSM_DEVICE(CLK_CTL), |
| 50 | MSM_DEVICE(PMDH), | ||
| 51 | MSM_DEVICE(EMDH), | ||
| 52 | MSM_DEVICE(MDP), | ||
| 53 | { | 45 | { |
| 54 | .virtual = MSM_SHARED_RAM_BASE, | 46 | .virtual = (unsigned long) MSM_SHARED_RAM_BASE, |
| 55 | .pfn = __phys_to_pfn(MSM_SHARED_RAM_PHYS), | 47 | .pfn = __phys_to_pfn(MSM_SHARED_RAM_PHYS), |
| 56 | .length = MSM_SHARED_RAM_SIZE, | 48 | .length = MSM_SHARED_RAM_SIZE, |
| 57 | .type = MT_DEVICE, | 49 | .type = MT_DEVICE, |
diff --git a/arch/arm/mach-msm/irq.c b/arch/arm/mach-msm/irq.c index 04b8d182ff8a..69ca0dd79bdf 100644 --- a/arch/arm/mach-msm/irq.c +++ b/arch/arm/mach-msm/irq.c | |||
| @@ -66,20 +66,20 @@ | |||
| 66 | 66 | ||
| 67 | static void msm_irq_ack(unsigned int irq) | 67 | static void msm_irq_ack(unsigned int irq) |
| 68 | { | 68 | { |
| 69 | unsigned reg = VIC_INT_CLEAR0 + ((irq & 32) ? 4 : 0); | 69 | void __iomem *reg = VIC_INT_CLEAR0 + ((irq & 32) ? 4 : 0); |
| 70 | irq = 1 << (irq & 31); | 70 | irq = 1 << (irq & 31); |
| 71 | writel(irq, reg); | 71 | writel(irq, reg); |
| 72 | } | 72 | } |
| 73 | 73 | ||
| 74 | static void msm_irq_mask(unsigned int irq) | 74 | static void msm_irq_mask(unsigned int irq) |
| 75 | { | 75 | { |
| 76 | unsigned reg = VIC_INT_ENCLEAR0 + ((irq & 32) ? 4 : 0); | 76 | void __iomem *reg = VIC_INT_ENCLEAR0 + ((irq & 32) ? 4 : 0); |
| 77 | writel(1 << (irq & 31), reg); | 77 | writel(1 << (irq & 31), reg); |
| 78 | } | 78 | } |
| 79 | 79 | ||
| 80 | static void msm_irq_unmask(unsigned int irq) | 80 | static void msm_irq_unmask(unsigned int irq) |
| 81 | { | 81 | { |
| 82 | unsigned reg = VIC_INT_ENSET0 + ((irq & 32) ? 4 : 0); | 82 | void __iomem *reg = VIC_INT_ENSET0 + ((irq & 32) ? 4 : 0); |
| 83 | writel(1 << (irq & 31), reg); | 83 | writel(1 << (irq & 31), reg); |
| 84 | } | 84 | } |
| 85 | 85 | ||
| @@ -90,8 +90,8 @@ static int msm_irq_set_wake(unsigned int irq, unsigned int on) | |||
| 90 | 90 | ||
| 91 | static int msm_irq_set_type(unsigned int irq, unsigned int flow_type) | 91 | static int msm_irq_set_type(unsigned int irq, unsigned int flow_type) |
| 92 | { | 92 | { |
| 93 | unsigned treg = VIC_INT_TYPE0 + ((irq & 32) ? 4 : 0); | 93 | void __iomem *treg = VIC_INT_TYPE0 + ((irq & 32) ? 4 : 0); |
| 94 | unsigned preg = VIC_INT_POLARITY0 + ((irq & 32) ? 4 : 0); | 94 | void __iomem *preg = VIC_INT_POLARITY0 + ((irq & 32) ? 4 : 0); |
| 95 | int b = 1 << (irq & 31); | 95 | int b = 1 << (irq & 31); |
| 96 | 96 | ||
| 97 | if (flow_type & (IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW)) | 97 | if (flow_type & (IRQF_TRIGGER_FALLING | IRQF_TRIGGER_LOW)) |
diff --git a/arch/arm/mach-msm/proc_comm.c b/arch/arm/mach-msm/proc_comm.c new file mode 100644 index 000000000000..915ee704ed3c --- /dev/null +++ b/arch/arm/mach-msm/proc_comm.c | |||
| @@ -0,0 +1,110 @@ | |||
| 1 | /* arch/arm/mach-msm/proc_comm.c | ||
| 2 | * | ||
| 3 | * Copyright (C) 2007-2008 Google, Inc. | ||
| 4 | * Author: Brian Swetland <swetland@google.com> | ||
| 5 | * | ||
| 6 | * This software is licensed under the terms of the GNU General Public | ||
| 7 | * License version 2, as published by the Free Software Foundation, and | ||
| 8 | * may be copied, distributed, and modified under those terms. | ||
| 9 | * | ||
| 10 | * This program is distributed in the hope that it will be useful, | ||
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 13 | * GNU General Public License for more details. | ||
| 14 | * | ||
| 15 | */ | ||
| 16 | |||
| 17 | #include <linux/delay.h> | ||
| 18 | #include <linux/errno.h> | ||
| 19 | #include <linux/io.h> | ||
| 20 | #include <linux/spinlock.h> | ||
| 21 | #include <mach/msm_iomap.h> | ||
| 22 | #include <mach/system.h> | ||
| 23 | |||
| 24 | #include "proc_comm.h" | ||
| 25 | |||
| 26 | #define MSM_A2M_INT(n) (MSM_CSR_BASE + 0x400 + (n) * 4) | ||
| 27 | |||
| 28 | static inline void notify_other_proc_comm(void) | ||
| 29 | { | ||
| 30 | writel(1, MSM_A2M_INT(6)); | ||
| 31 | } | ||
| 32 | |||
| 33 | #define APP_COMMAND 0x00 | ||
| 34 | #define APP_STATUS 0x04 | ||
| 35 | #define APP_DATA1 0x08 | ||
| 36 | #define APP_DATA2 0x0C | ||
| 37 | |||
| 38 | #define MDM_COMMAND 0x10 | ||
| 39 | #define MDM_STATUS 0x14 | ||
| 40 | #define MDM_DATA1 0x18 | ||
| 41 | #define MDM_DATA2 0x1C | ||
| 42 | |||
| 43 | static DEFINE_SPINLOCK(proc_comm_lock); | ||
| 44 | |||
| 45 | /* The higher level SMD support will install this to | ||
| 46 | * provide a way to check for and handle modem restart. | ||
| 47 | */ | ||
| 48 | int (*msm_check_for_modem_crash)(void); | ||
| 49 | |||
| 50 | /* Poll for a state change, checking for possible | ||
| 51 | * modem crashes along the way (so we don't wait | ||
| 52 | * forever while the ARM9 is blowing up). | ||
| 53 | * | ||
| 54 | * Return an error in the event of a modem crash and | ||
| 55 | * restart so the msm_proc_comm() routine can restart | ||
| 56 | * the operation from the beginning. | ||
| 57 | */ | ||
| 58 | static int proc_comm_wait_for(void __iomem *addr, unsigned value) | ||
| 59 | { | ||
| 60 | for (;;) { | ||
| 61 | if (readl(addr) == value) | ||
| 62 | return 0; | ||
| 63 | |||
| 64 | if (msm_check_for_modem_crash) | ||
| 65 | if (msm_check_for_modem_crash()) | ||
| 66 | return -EAGAIN; | ||
| 67 | } | ||
| 68 | } | ||
| 69 | |||
| 70 | int msm_proc_comm(unsigned cmd, unsigned *data1, unsigned *data2) | ||
| 71 | { | ||
| 72 | void __iomem *base = MSM_SHARED_RAM_BASE; | ||
| 73 | unsigned long flags; | ||
| 74 | int ret; | ||
| 75 | |||
| 76 | spin_lock_irqsave(&proc_comm_lock, flags); | ||
| 77 | |||
| 78 | for (;;) { | ||
| 79 | if (proc_comm_wait_for(base + MDM_STATUS, PCOM_READY)) | ||
| 80 | continue; | ||
| 81 | |||
| 82 | writel(cmd, base + APP_COMMAND); | ||
| 83 | writel(data1 ? *data1 : 0, base + APP_DATA1); | ||
| 84 | writel(data2 ? *data2 : 0, base + APP_DATA2); | ||
| 85 | |||
| 86 | notify_other_proc_comm(); | ||
| 87 | |||
| 88 | if (proc_comm_wait_for(base + APP_COMMAND, PCOM_CMD_DONE)) | ||
| 89 | continue; | ||
| 90 | |||
| 91 | if (readl(base + APP_STATUS) != PCOM_CMD_FAIL) { | ||
| 92 | if (data1) | ||
| 93 | *data1 = readl(base + APP_DATA1); | ||
| 94 | if (data2) | ||
| 95 | *data2 = readl(base + APP_DATA2); | ||
| 96 | ret = 0; | ||
| 97 | } else { | ||
| 98 | ret = -EIO; | ||
| 99 | } | ||
| 100 | break; | ||
| 101 | } | ||
| 102 | |||
| 103 | writel(PCOM_CMD_IDLE, base + APP_COMMAND); | ||
| 104 | |||
| 105 | spin_unlock_irqrestore(&proc_comm_lock, flags); | ||
| 106 | |||
| 107 | return ret; | ||
| 108 | } | ||
| 109 | |||
| 110 | |||
diff --git a/arch/arm/mach-msm/proc_comm.h b/arch/arm/mach-msm/proc_comm.h new file mode 100644 index 000000000000..834760f25692 --- /dev/null +++ b/arch/arm/mach-msm/proc_comm.h | |||
| @@ -0,0 +1,165 @@ | |||
| 1 | /* arch/arm/mach-msm/proc_comm.h | ||
| 2 | * | ||
| 3 | * Copyright (c) 2007 QUALCOMM Incorporated | ||
| 4 | * | ||
| 5 | * This software is licensed under the terms of the GNU General Public | ||
| 6 | * License version 2, as published by the Free Software Foundation, and | ||
| 7 | * may be copied, distributed, and modified under those terms. | ||
| 8 | * | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | */ | ||
| 15 | |||
| 16 | #ifndef _ARCH_ARM_MACH_MSM_PROC_COMM_H_ | ||
| 17 | #define _ARCH_ARM_MACH_MSM_PROC_COMM_H_ | ||
| 18 | |||
| 19 | enum { | ||
| 20 | PCOM_CMD_IDLE = 0x0, | ||
| 21 | PCOM_CMD_DONE, | ||
| 22 | PCOM_RESET_APPS, | ||
| 23 | PCOM_RESET_CHIP, | ||
| 24 | PCOM_CONFIG_NAND_MPU, | ||
| 25 | PCOM_CONFIG_USB_CLKS, | ||
| 26 | PCOM_GET_POWER_ON_STATUS, | ||
| 27 | PCOM_GET_WAKE_UP_STATUS, | ||
| 28 | PCOM_GET_BATT_LEVEL, | ||
| 29 | PCOM_CHG_IS_CHARGING, | ||
| 30 | PCOM_POWER_DOWN, | ||
| 31 | PCOM_USB_PIN_CONFIG, | ||
| 32 | PCOM_USB_PIN_SEL, | ||
| 33 | PCOM_SET_RTC_ALARM, | ||
| 34 | PCOM_NV_READ, | ||
| 35 | PCOM_NV_WRITE, | ||
| 36 | PCOM_GET_UUID_HIGH, | ||
| 37 | PCOM_GET_UUID_LOW, | ||
| 38 | PCOM_GET_HW_ENTROPY, | ||
| 39 | PCOM_RPC_GPIO_TLMM_CONFIG_REMOTE, | ||
| 40 | PCOM_CLKCTL_RPC_ENABLE, | ||
| 41 | PCOM_CLKCTL_RPC_DISABLE, | ||
| 42 | PCOM_CLKCTL_RPC_RESET, | ||
| 43 | PCOM_CLKCTL_RPC_SET_FLAGS, | ||
| 44 | PCOM_CLKCTL_RPC_SET_RATE, | ||
| 45 | PCOM_CLKCTL_RPC_MIN_RATE, | ||
| 46 | PCOM_CLKCTL_RPC_MAX_RATE, | ||
| 47 | PCOM_CLKCTL_RPC_RATE, | ||
| 48 | PCOM_CLKCTL_RPC_PLL_REQUEST, | ||
| 49 | PCOM_CLKCTL_RPC_ENABLED, | ||
| 50 | PCOM_VREG_SWITCH, | ||
| 51 | PCOM_VREG_SET_LEVEL, | ||
| 52 | PCOM_GPIO_TLMM_CONFIG_GROUP, | ||
| 53 | PCOM_GPIO_TLMM_UNCONFIG_GROUP, | ||
| 54 | PCOM_NV_WRITE_BYTES_4_7, | ||
| 55 | PCOM_CONFIG_DISP, | ||
| 56 | PCOM_GET_FTM_BOOT_COUNT, | ||
| 57 | PCOM_RPC_GPIO_TLMM_CONFIG_EX, | ||
| 58 | PCOM_PM_MPP_CONFIG, | ||
| 59 | PCOM_GPIO_IN, | ||
| 60 | PCOM_GPIO_OUT, | ||
| 61 | PCOM_RESET_MODEM, | ||
| 62 | PCOM_RESET_CHIP_IMM, | ||
| 63 | PCOM_PM_VID_EN, | ||
| 64 | PCOM_VREG_PULLDOWN, | ||
| 65 | PCOM_NUM_CMDS, | ||
| 66 | }; | ||
| 67 | |||
| 68 | enum { | ||
| 69 | PCOM_INVALID_STATUS = 0x0, | ||
| 70 | PCOM_READY, | ||
| 71 | PCOM_CMD_RUNNING, | ||
| 72 | PCOM_CMD_SUCCESS, | ||
| 73 | PCOM_CMD_FAIL, | ||
| 74 | }; | ||
| 75 | |||
| 76 | /* List of VREGs that support the Pull Down Resistor setting. */ | ||
| 77 | enum { | ||
| 78 | PM_VREG_PDOWN_MSMA_ID, | ||
| 79 | PM_VREG_PDOWN_MSMP_ID, | ||
| 80 | PM_VREG_PDOWN_MSME1_ID, /* Not supported in Panoramix */ | ||
| 81 | PM_VREG_PDOWN_MSMC1_ID, /* Not supported in PM6620 */ | ||
| 82 | PM_VREG_PDOWN_MSMC2_ID, /* Supported in PM7500 only */ | ||
| 83 | PM_VREG_PDOWN_GP3_ID, /* Supported in PM7500 only */ | ||
| 84 | PM_VREG_PDOWN_MSME2_ID, /* Supported in PM7500 and Panoramix only */ | ||
| 85 | PM_VREG_PDOWN_GP4_ID, /* Supported in PM7500 only */ | ||
| 86 | PM_VREG_PDOWN_GP1_ID, /* Supported in PM7500 only */ | ||
| 87 | PM_VREG_PDOWN_TCXO_ID, | ||
| 88 | PM_VREG_PDOWN_PA_ID, | ||
| 89 | PM_VREG_PDOWN_RFTX_ID, | ||
| 90 | PM_VREG_PDOWN_RFRX1_ID, | ||
| 91 | PM_VREG_PDOWN_RFRX2_ID, | ||
| 92 | PM_VREG_PDOWN_SYNT_ID, | ||
| 93 | PM_VREG_PDOWN_WLAN_ID, | ||
| 94 | PM_VREG_PDOWN_USB_ID, | ||
| 95 | PM_VREG_PDOWN_MMC_ID, | ||
| 96 | PM_VREG_PDOWN_RUIM_ID, | ||
| 97 | PM_VREG_PDOWN_MSMC0_ID, /* Supported in PM6610 only */ | ||
| 98 | PM_VREG_PDOWN_GP2_ID, /* Supported in PM7500 only */ | ||
| 99 | PM_VREG_PDOWN_GP5_ID, /* Supported in PM7500 only */ | ||
| 100 | PM_VREG_PDOWN_GP6_ID, /* Supported in PM7500 only */ | ||
| 101 | PM_VREG_PDOWN_RF_ID, | ||
| 102 | PM_VREG_PDOWN_RF_VCO_ID, | ||
| 103 | PM_VREG_PDOWN_MPLL_ID, | ||
| 104 | PM_VREG_PDOWN_S2_ID, | ||
| 105 | PM_VREG_PDOWN_S3_ID, | ||
| 106 | PM_VREG_PDOWN_RFUBM_ID, | ||
| 107 | |||
| 108 | /* new for HAN */ | ||
| 109 | PM_VREG_PDOWN_RF1_ID, | ||
| 110 | PM_VREG_PDOWN_RF2_ID, | ||
| 111 | PM_VREG_PDOWN_RFA_ID, | ||
| 112 | PM_VREG_PDOWN_CDC2_ID, | ||
| 113 | PM_VREG_PDOWN_RFTX2_ID, | ||
| 114 | PM_VREG_PDOWN_USIM_ID, | ||
| 115 | PM_VREG_PDOWN_USB2P6_ID, | ||
| 116 | PM_VREG_PDOWN_USB3P3_ID, | ||
| 117 | PM_VREG_PDOWN_INVALID_ID, | ||
| 118 | |||
| 119 | /* backward compatible enums only */ | ||
| 120 | PM_VREG_PDOWN_CAM_ID = PM_VREG_PDOWN_GP1_ID, | ||
| 121 | PM_VREG_PDOWN_MDDI_ID = PM_VREG_PDOWN_GP2_ID, | ||
| 122 | PM_VREG_PDOWN_RUIM2_ID = PM_VREG_PDOWN_GP3_ID, | ||
| 123 | PM_VREG_PDOWN_AUX_ID = PM_VREG_PDOWN_GP4_ID, | ||
| 124 | PM_VREG_PDOWN_AUX2_ID = PM_VREG_PDOWN_GP5_ID, | ||
| 125 | PM_VREG_PDOWN_BT_ID = PM_VREG_PDOWN_GP6_ID, | ||
| 126 | |||
| 127 | PM_VREG_PDOWN_MSME_ID = PM_VREG_PDOWN_MSME1_ID, | ||
| 128 | PM_VREG_PDOWN_MSMC_ID = PM_VREG_PDOWN_MSMC1_ID, | ||
| 129 | PM_VREG_PDOWN_RFA1_ID = PM_VREG_PDOWN_RFRX2_ID, | ||
| 130 | PM_VREG_PDOWN_RFA2_ID = PM_VREG_PDOWN_RFTX2_ID, | ||
| 131 | PM_VREG_PDOWN_XO_ID = PM_VREG_PDOWN_TCXO_ID | ||
| 132 | }; | ||
| 133 | |||
| 134 | /* gpio info for PCOM_RPC_GPIO_TLMM_CONFIG_EX */ | ||
| 135 | |||
| 136 | #define GPIO_ENABLE 0 | ||
| 137 | #define GPIO_DISABLE 1 | ||
| 138 | |||
| 139 | #define GPIO_INPUT 0 | ||
| 140 | #define GPIO_OUTPUT 1 | ||
| 141 | |||
| 142 | #define GPIO_NO_PULL 0 | ||
| 143 | #define GPIO_PULL_DOWN 1 | ||
| 144 | #define GPIO_KEEPER 2 | ||
| 145 | #define GPIO_PULL_UP 3 | ||
| 146 | |||
| 147 | #define GPIO_2MA 0 | ||
| 148 | #define GPIO_4MA 1 | ||
| 149 | #define GPIO_6MA 2 | ||
| 150 | #define GPIO_8MA 3 | ||
| 151 | #define GPIO_10MA 4 | ||
| 152 | #define GPIO_12MA 5 | ||
| 153 | #define GPIO_14MA 6 | ||
| 154 | #define GPIO_16MA 7 | ||
| 155 | |||
| 156 | #define PCOM_GPIO_CFG(gpio, func, dir, pull, drvstr) \ | ||
| 157 | ((((gpio) & 0x3FF) << 4) | \ | ||
| 158 | ((func) & 0xf) | \ | ||
| 159 | (((dir) & 0x1) << 14) | \ | ||
| 160 | (((pull) & 0x3) << 15) | \ | ||
| 161 | (((drvstr) & 0xF) << 17)) | ||
| 162 | |||
| 163 | int msm_proc_comm(unsigned cmd, unsigned *data1, unsigned *data2); | ||
| 164 | |||
| 165 | #endif | ||
diff --git a/arch/arm/mach-msm/timer.c b/arch/arm/mach-msm/timer.c index 2bffe9b7e9fe..345a14cb73c3 100644 --- a/arch/arm/mach-msm/timer.c +++ b/arch/arm/mach-msm/timer.c | |||
| @@ -45,7 +45,7 @@ struct msm_clock { | |||
| 45 | struct clock_event_device clockevent; | 45 | struct clock_event_device clockevent; |
| 46 | struct clocksource clocksource; | 46 | struct clocksource clocksource; |
| 47 | struct irqaction irq; | 47 | struct irqaction irq; |
| 48 | uint32_t regbase; | 48 | void __iomem *regbase; |
| 49 | uint32_t freq; | 49 | uint32_t freq; |
| 50 | uint32_t shift; | 50 | uint32_t shift; |
| 51 | }; | 51 | }; |
diff --git a/arch/arm/mach-msm/vreg.c b/arch/arm/mach-msm/vreg.c new file mode 100644 index 000000000000..fcb0b9f25684 --- /dev/null +++ b/arch/arm/mach-msm/vreg.c | |||
| @@ -0,0 +1,143 @@ | |||
| 1 | /* arch/arm/mach-msm/vreg.c | ||
| 2 | * | ||
| 3 | * Copyright (C) 2008 Google, Inc. | ||
| 4 | * Author: Brian Swetland <swetland@google.com> | ||
| 5 | * | ||
| 6 | * This software is licensed under the terms of the GNU General Public | ||
| 7 | * License version 2, as published by the Free Software Foundation, and | ||
| 8 | * may be copied, distributed, and modified under those terms. | ||
| 9 | * | ||
| 10 | * This program is distributed in the hope that it will be useful, | ||
| 11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 13 | * GNU General Public License for more details. | ||
| 14 | * | ||
| 15 | */ | ||
| 16 | |||
| 17 | #include <linux/kernel.h> | ||
| 18 | #include <linux/device.h> | ||
| 19 | #include <linux/init.h> | ||
| 20 | #include <linux/debugfs.h> | ||
| 21 | #include <mach/vreg.h> | ||
| 22 | |||
| 23 | #include "proc_comm.h" | ||
| 24 | |||
| 25 | struct vreg { | ||
| 26 | const char *name; | ||
| 27 | unsigned id; | ||
| 28 | }; | ||
| 29 | |||
| 30 | #define VREG(_name, _id) { .name = _name, .id = _id, } | ||
| 31 | |||
| 32 | static struct vreg vregs[] = { | ||
| 33 | VREG("msma", 0), | ||
| 34 | VREG("msmp", 1), | ||
| 35 | VREG("msme1", 2), | ||
| 36 | VREG("msmc1", 3), | ||
| 37 | VREG("msmc2", 4), | ||
| 38 | VREG("gp3", 5), | ||
| 39 | VREG("msme2", 6), | ||
| 40 | VREG("gp4", 7), | ||
| 41 | VREG("gp1", 8), | ||
| 42 | VREG("tcxo", 9), | ||
| 43 | VREG("pa", 10), | ||
| 44 | VREG("rftx", 11), | ||
| 45 | VREG("rfrx1", 12), | ||
| 46 | VREG("rfrx2", 13), | ||
| 47 | VREG("synt", 14), | ||
| 48 | VREG("wlan", 15), | ||
| 49 | VREG("usb", 16), | ||
| 50 | VREG("boost", 17), | ||
| 51 | VREG("mmc", 18), | ||
| 52 | VREG("ruim", 19), | ||
| 53 | VREG("msmc0", 20), | ||
| 54 | VREG("gp2", 21), | ||
| 55 | VREG("gp5", 22), | ||
| 56 | VREG("gp6", 23), | ||
| 57 | VREG("rf", 24), | ||
| 58 | VREG("rf_vco", 26), | ||
| 59 | VREG("mpll", 27), | ||
| 60 | VREG("s2", 28), | ||
| 61 | VREG("s3", 29), | ||
| 62 | VREG("rfubm", 30), | ||
| 63 | VREG("ncp", 31), | ||
| 64 | }; | ||
| 65 | |||
| 66 | struct vreg *vreg_get(struct device *dev, const char *id) | ||
| 67 | { | ||
| 68 | int n; | ||
| 69 | for (n = 0; n < ARRAY_SIZE(vregs); n++) { | ||
| 70 | if (!strcmp(vregs[n].name, id)) | ||
| 71 | return vregs + n; | ||
| 72 | } | ||
| 73 | return 0; | ||
| 74 | } | ||
| 75 | |||
| 76 | void vreg_put(struct vreg *vreg) | ||
| 77 | { | ||
| 78 | } | ||
| 79 | |||
| 80 | int vreg_enable(struct vreg *vreg) | ||
| 81 | { | ||
| 82 | unsigned id = vreg->id; | ||
| 83 | unsigned enable = 1; | ||
| 84 | return msm_proc_comm(PCOM_VREG_SWITCH, &id, &enable); | ||
| 85 | } | ||
| 86 | |||
| 87 | void vreg_disable(struct vreg *vreg) | ||
| 88 | { | ||
| 89 | unsigned id = vreg->id; | ||
| 90 | unsigned enable = 0; | ||
| 91 | msm_proc_comm(PCOM_VREG_SWITCH, &id, &enable); | ||
| 92 | } | ||
| 93 | |||
| 94 | int vreg_set_level(struct vreg *vreg, unsigned mv) | ||
| 95 | { | ||
| 96 | unsigned id = vreg->id; | ||
| 97 | return msm_proc_comm(PCOM_VREG_SET_LEVEL, &id, &mv); | ||
| 98 | } | ||
| 99 | |||
| 100 | #if defined(CONFIG_DEBUG_FS) | ||
| 101 | |||
| 102 | static int vreg_debug_set(void *data, u64 val) | ||
| 103 | { | ||
| 104 | struct vreg *vreg = data; | ||
| 105 | switch (val) { | ||
| 106 | case 0: | ||
| 107 | vreg_disable(vreg); | ||
| 108 | break; | ||
| 109 | case 1: | ||
| 110 | vreg_enable(vreg); | ||
| 111 | break; | ||
| 112 | default: | ||
| 113 | vreg_set_level(vreg, val); | ||
| 114 | break; | ||
| 115 | } | ||
| 116 | return 0; | ||
| 117 | } | ||
| 118 | |||
| 119 | static int vreg_debug_get(void *data, u64 *val) | ||
| 120 | { | ||
| 121 | return -ENOSYS; | ||
| 122 | } | ||
| 123 | |||
| 124 | DEFINE_SIMPLE_ATTRIBUTE(vreg_fops, vreg_debug_get, vreg_debug_set, "%llu\n"); | ||
| 125 | |||
| 126 | static int __init vreg_debug_init(void) | ||
| 127 | { | ||
| 128 | struct dentry *dent; | ||
| 129 | int n; | ||
| 130 | |||
| 131 | dent = debugfs_create_dir("vreg", 0); | ||
| 132 | if (IS_ERR(dent)) | ||
| 133 | return 0; | ||
| 134 | |||
| 135 | for (n = 0; n < ARRAY_SIZE(vregs); n++) | ||
| 136 | (void) debugfs_create_file(vregs[n].name, 0644, | ||
| 137 | dent, vregs + n, &vreg_fops); | ||
| 138 | |||
| 139 | return 0; | ||
| 140 | } | ||
| 141 | |||
| 142 | device_initcall(vreg_debug_init); | ||
| 143 | #endif | ||
diff --git a/arch/arm/mach-pxa/Kconfig b/arch/arm/mach-pxa/Kconfig index f781873431f3..a062235e83a8 100644 --- a/arch/arm/mach-pxa/Kconfig +++ b/arch/arm/mach-pxa/Kconfig | |||
| @@ -71,6 +71,14 @@ config PXA_SHARPSL | |||
| 71 | SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) | 71 | SL-C3000 (Spitz), SL-C3100 (Borzoi) or SL-C6000x (Tosa) |
| 72 | handheld computer. | 72 | handheld computer. |
| 73 | 73 | ||
| 74 | config CORGI_SSP_DEPRECATED | ||
| 75 | bool | ||
| 76 | select PXA_SSP | ||
| 77 | help | ||
| 78 | This option will include corgi_ssp.c and corgi_lcd.c | ||
| 79 | that corgi_ts.c and other legacy drivers (corgi_bl.c | ||
| 80 | and sharpsl_pm.c) may depend on. | ||
| 81 | |||
| 74 | config MACH_POODLE | 82 | config MACH_POODLE |
| 75 | bool "Enable Sharp SL-5600 (Poodle) Support" | 83 | bool "Enable Sharp SL-5600 (Poodle) Support" |
| 76 | depends on PXA_SHARPSL | 84 | depends on PXA_SHARPSL |
diff --git a/arch/arm/mach-pxa/Makefile b/arch/arm/mach-pxa/Makefile index d31c9979cfa3..d64c68b232e3 100644 --- a/arch/arm/mach-pxa/Makefile +++ b/arch/arm/mach-pxa/Makefile | |||
| @@ -37,6 +37,7 @@ obj-$(CONFIG_MACH_TRIZEPS4) += trizeps4.o | |||
| 37 | obj-$(CONFIG_MACH_COLIBRI) += colibri.o | 37 | obj-$(CONFIG_MACH_COLIBRI) += colibri.o |
| 38 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o sharpsl_pm.o corgi_pm.o | 38 | obj-$(CONFIG_PXA_SHARP_C7xx) += corgi.o sharpsl_pm.o corgi_pm.o |
| 39 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o sharpsl_pm.o spitz_pm.o | 39 | obj-$(CONFIG_PXA_SHARP_Cxx00) += spitz.o sharpsl_pm.o spitz_pm.o |
| 40 | obj-$(CONFIG_CORGI_SSP_DEPRECATED) += corgi_ssp.o corgi_lcd.o | ||
| 40 | obj-$(CONFIG_MACH_POODLE) += poodle.o | 41 | obj-$(CONFIG_MACH_POODLE) += poodle.o |
| 41 | obj-$(CONFIG_MACH_PCM027) += pcm027.o | 42 | obj-$(CONFIG_MACH_PCM027) += pcm027.o |
| 42 | obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o | 43 | obj-$(CONFIG_MACH_PCM990_BASEBOARD) += pcm990-baseboard.o |
diff --git a/arch/arm/mach-pxa/corgi_lcd.c b/arch/arm/mach-pxa/corgi_lcd.c new file mode 100644 index 000000000000..411607bc1fc2 --- /dev/null +++ b/arch/arm/mach-pxa/corgi_lcd.c | |||
| @@ -0,0 +1,289 @@ | |||
| 1 | /* | ||
| 2 | * linux/arch/arm/mach-pxa/corgi_lcd.c | ||
| 3 | * | ||
| 4 | * Corgi/Spitz LCD Specific Code | ||
| 5 | * | ||
| 6 | * Copyright (C) 2005 Richard Purdie | ||
| 7 | * | ||
| 8 | * Connectivity: | ||
| 9 | * Corgi - LCD to ATI Imageon w100 (Wallaby) | ||
| 10 | * Spitz - LCD to PXA Framebuffer | ||
| 11 | * | ||
| 12 | * This program is free software; you can redistribute it and/or modify | ||
| 13 | * it under the terms of the GNU General Public License version 2 as | ||
| 14 | * published by the Free Software Foundation. | ||
| 15 | * | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <linux/delay.h> | ||
| 19 | #include <linux/kernel.h> | ||
| 20 | #include <linux/platform_device.h> | ||
| 21 | #include <linux/module.h> | ||
| 22 | #include <linux/string.h> | ||
| 23 | #include <mach/corgi.h> | ||
| 24 | #include <mach/hardware.h> | ||
| 25 | #include <mach/pxa-regs.h> | ||
| 26 | #include <mach/sharpsl.h> | ||
| 27 | #include <mach/spitz.h> | ||
| 28 | #include <asm/hardware/scoop.h> | ||
| 29 | #include <asm/mach/sharpsl_param.h> | ||
| 30 | #include "generic.h" | ||
| 31 | |||
| 32 | /* Register Addresses */ | ||
| 33 | #define RESCTL_ADRS 0x00 | ||
| 34 | #define PHACTRL_ADRS 0x01 | ||
| 35 | #define DUTYCTRL_ADRS 0x02 | ||
| 36 | #define POWERREG0_ADRS 0x03 | ||
| 37 | #define POWERREG1_ADRS 0x04 | ||
| 38 | #define GPOR3_ADRS 0x05 | ||
| 39 | #define PICTRL_ADRS 0x06 | ||
| 40 | #define POLCTRL_ADRS 0x07 | ||
| 41 | |||
| 42 | /* Register Bit Definitions */ | ||
| 43 | #define RESCTL_QVGA 0x01 | ||
| 44 | #define RESCTL_VGA 0x00 | ||
| 45 | |||
| 46 | #define POWER1_VW_ON 0x01 /* VW Supply FET ON */ | ||
| 47 | #define POWER1_GVSS_ON 0x02 /* GVSS(-8V) Power Supply ON */ | ||
| 48 | #define POWER1_VDD_ON 0x04 /* VDD(8V),SVSS(-4V) Power Supply ON */ | ||
| 49 | |||
| 50 | #define POWER1_VW_OFF 0x00 /* VW Supply FET OFF */ | ||
| 51 | #define POWER1_GVSS_OFF 0x00 /* GVSS(-8V) Power Supply OFF */ | ||
| 52 | #define POWER1_VDD_OFF 0x00 /* VDD(8V),SVSS(-4V) Power Supply OFF */ | ||
| 53 | |||
| 54 | #define POWER0_COM_DCLK 0x01 /* COM Voltage DC Bias DAC Serial Data Clock */ | ||
| 55 | #define POWER0_COM_DOUT 0x02 /* COM Voltage DC Bias DAC Serial Data Out */ | ||
| 56 | #define POWER0_DAC_ON 0x04 /* DAC Power Supply ON */ | ||
| 57 | #define POWER0_COM_ON 0x08 /* COM Power Supply ON */ | ||
| 58 | #define POWER0_VCC5_ON 0x10 /* VCC5 Power Supply ON */ | ||
| 59 | |||
| 60 | #define POWER0_DAC_OFF 0x00 /* DAC Power Supply OFF */ | ||
| 61 | #define POWER0_COM_OFF 0x00 /* COM Power Supply OFF */ | ||
| 62 | #define POWER0_VCC5_OFF 0x00 /* VCC5 Power Supply OFF */ | ||
| 63 | |||
| 64 | #define PICTRL_INIT_STATE 0x01 | ||
| 65 | #define PICTRL_INIOFF 0x02 | ||
| 66 | #define PICTRL_POWER_DOWN 0x04 | ||
| 67 | #define PICTRL_COM_SIGNAL_OFF 0x08 | ||
| 68 | #define PICTRL_DAC_SIGNAL_OFF 0x10 | ||
| 69 | |||
| 70 | #define POLCTRL_SYNC_POL_FALL 0x01 | ||
| 71 | #define POLCTRL_EN_POL_FALL 0x02 | ||
| 72 | #define POLCTRL_DATA_POL_FALL 0x04 | ||
| 73 | #define POLCTRL_SYNC_ACT_H 0x08 | ||
| 74 | #define POLCTRL_EN_ACT_L 0x10 | ||
| 75 | |||
| 76 | #define POLCTRL_SYNC_POL_RISE 0x00 | ||
| 77 | #define POLCTRL_EN_POL_RISE 0x00 | ||
| 78 | #define POLCTRL_DATA_POL_RISE 0x00 | ||
| 79 | #define POLCTRL_SYNC_ACT_L 0x00 | ||
| 80 | #define POLCTRL_EN_ACT_H 0x00 | ||
| 81 | |||
| 82 | #define PHACTRL_PHASE_MANUAL 0x01 | ||
| 83 | #define DEFAULT_PHAD_QVGA (9) | ||
| 84 | #define DEFAULT_COMADJ (125) | ||
| 85 | |||
| 86 | /* | ||
| 87 | * This is only a psuedo I2C interface. We can't use the standard kernel | ||
| 88 | * routines as the interface is write only. We just assume the data is acked... | ||
| 89 | */ | ||
| 90 | static void lcdtg_ssp_i2c_send(u8 data) | ||
| 91 | { | ||
| 92 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, data); | ||
| 93 | udelay(10); | ||
| 94 | } | ||
| 95 | |||
| 96 | static void lcdtg_i2c_send_bit(u8 data) | ||
| 97 | { | ||
| 98 | lcdtg_ssp_i2c_send(data); | ||
| 99 | lcdtg_ssp_i2c_send(data | POWER0_COM_DCLK); | ||
| 100 | lcdtg_ssp_i2c_send(data); | ||
| 101 | } | ||
| 102 | |||
| 103 | static void lcdtg_i2c_send_start(u8 base) | ||
| 104 | { | ||
| 105 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK | POWER0_COM_DOUT); | ||
| 106 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK); | ||
| 107 | lcdtg_ssp_i2c_send(base); | ||
| 108 | } | ||
| 109 | |||
| 110 | static void lcdtg_i2c_send_stop(u8 base) | ||
| 111 | { | ||
| 112 | lcdtg_ssp_i2c_send(base); | ||
| 113 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK); | ||
| 114 | lcdtg_ssp_i2c_send(base | POWER0_COM_DCLK | POWER0_COM_DOUT); | ||
| 115 | } | ||
| 116 | |||
| 117 | static void lcdtg_i2c_send_byte(u8 base, u8 data) | ||
| 118 | { | ||
| 119 | int i; | ||
| 120 | for (i = 0; i < 8; i++) { | ||
| 121 | if (data & 0x80) | ||
| 122 | lcdtg_i2c_send_bit(base | POWER0_COM_DOUT); | ||
| 123 | else | ||
| 124 | lcdtg_i2c_send_bit(base); | ||
| 125 | data <<= 1; | ||
| 126 | } | ||
| 127 | } | ||
| 128 | |||
| 129 | static void lcdtg_i2c_wait_ack(u8 base) | ||
| 130 | { | ||
| 131 | lcdtg_i2c_send_bit(base); | ||
| 132 | } | ||
| 133 | |||
| 134 | static void lcdtg_set_common_voltage(u8 base_data, u8 data) | ||
| 135 | { | ||
| 136 | /* Set Common Voltage to M62332FP via I2C */ | ||
| 137 | lcdtg_i2c_send_start(base_data); | ||
| 138 | lcdtg_i2c_send_byte(base_data, 0x9c); | ||
| 139 | lcdtg_i2c_wait_ack(base_data); | ||
| 140 | lcdtg_i2c_send_byte(base_data, 0x00); | ||
| 141 | lcdtg_i2c_wait_ack(base_data); | ||
| 142 | lcdtg_i2c_send_byte(base_data, data); | ||
| 143 | lcdtg_i2c_wait_ack(base_data); | ||
| 144 | lcdtg_i2c_send_stop(base_data); | ||
| 145 | } | ||
| 146 | |||
| 147 | /* Set Phase Adjust */ | ||
| 148 | static void lcdtg_set_phadadj(int mode) | ||
| 149 | { | ||
| 150 | int adj; | ||
| 151 | switch(mode) { | ||
| 152 | case 480: | ||
| 153 | case 640: | ||
| 154 | /* Setting for VGA */ | ||
| 155 | adj = sharpsl_param.phadadj; | ||
| 156 | if (adj < 0) { | ||
| 157 | adj = PHACTRL_PHASE_MANUAL; | ||
| 158 | } else { | ||
| 159 | adj = ((adj & 0x0f) << 1) | PHACTRL_PHASE_MANUAL; | ||
| 160 | } | ||
| 161 | break; | ||
| 162 | case 240: | ||
| 163 | case 320: | ||
| 164 | default: | ||
| 165 | /* Setting for QVGA */ | ||
| 166 | adj = (DEFAULT_PHAD_QVGA << 1) | PHACTRL_PHASE_MANUAL; | ||
| 167 | break; | ||
| 168 | } | ||
| 169 | |||
| 170 | corgi_ssp_lcdtg_send(PHACTRL_ADRS, adj); | ||
| 171 | } | ||
| 172 | |||
| 173 | static int lcd_inited; | ||
| 174 | |||
| 175 | void corgi_lcdtg_hw_init(int mode) | ||
| 176 | { | ||
| 177 | if (!lcd_inited) { | ||
| 178 | int comadj; | ||
| 179 | |||
| 180 | /* Initialize Internal Logic & Port */ | ||
| 181 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_POWER_DOWN | PICTRL_INIOFF | PICTRL_INIT_STATE | ||
| 182 | | PICTRL_COM_SIGNAL_OFF | PICTRL_DAC_SIGNAL_OFF); | ||
| 183 | |||
| 184 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_OFF | ||
| 185 | | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
| 186 | |||
| 187 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_OFF); | ||
| 188 | |||
| 189 | /* VDD(+8V), SVSS(-4V) ON */ | ||
| 190 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_ON); | ||
| 191 | mdelay(3); | ||
| 192 | |||
| 193 | /* DAC ON */ | ||
| 194 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | ||
| 195 | | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
| 196 | |||
| 197 | /* INIB = H, INI = L */ | ||
| 198 | /* PICTL[0] = H , PICTL[1] = PICTL[2] = PICTL[4] = L */ | ||
| 199 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIT_STATE | PICTRL_COM_SIGNAL_OFF); | ||
| 200 | |||
| 201 | /* Set Common Voltage */ | ||
| 202 | comadj = sharpsl_param.comadj; | ||
| 203 | if (comadj < 0) | ||
| 204 | comadj = DEFAULT_COMADJ; | ||
| 205 | lcdtg_set_common_voltage((POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_OFF), comadj); | ||
| 206 | |||
| 207 | /* VCC5 ON, DAC ON */ | ||
| 208 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | | ||
| 209 | POWER0_COM_OFF | POWER0_VCC5_ON); | ||
| 210 | |||
| 211 | /* GVSS(-8V) ON, VDD ON */ | ||
| 212 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
| 213 | mdelay(2); | ||
| 214 | |||
| 215 | /* COM SIGNAL ON (PICTL[3] = L) */ | ||
| 216 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIT_STATE); | ||
| 217 | |||
| 218 | /* COM ON, DAC ON, VCC5_ON */ | ||
| 219 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_COM_DCLK | POWER0_COM_DOUT | POWER0_DAC_ON | ||
| 220 | | POWER0_COM_ON | POWER0_VCC5_ON); | ||
| 221 | |||
| 222 | /* VW ON, GVSS ON, VDD ON */ | ||
| 223 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_ON | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
| 224 | |||
| 225 | /* Signals output enable */ | ||
| 226 | corgi_ssp_lcdtg_send(PICTRL_ADRS, 0); | ||
| 227 | |||
| 228 | /* Set Phase Adjust */ | ||
| 229 | lcdtg_set_phadadj(mode); | ||
| 230 | |||
| 231 | /* Initialize for Input Signals from ATI */ | ||
| 232 | corgi_ssp_lcdtg_send(POLCTRL_ADRS, POLCTRL_SYNC_POL_RISE | POLCTRL_EN_POL_RISE | ||
| 233 | | POLCTRL_DATA_POL_RISE | POLCTRL_SYNC_ACT_L | POLCTRL_EN_ACT_H); | ||
| 234 | udelay(1000); | ||
| 235 | |||
| 236 | lcd_inited=1; | ||
| 237 | } else { | ||
| 238 | lcdtg_set_phadadj(mode); | ||
| 239 | } | ||
| 240 | |||
| 241 | switch(mode) { | ||
| 242 | case 480: | ||
| 243 | case 640: | ||
| 244 | /* Set Lcd Resolution (VGA) */ | ||
| 245 | corgi_ssp_lcdtg_send(RESCTL_ADRS, RESCTL_VGA); | ||
| 246 | break; | ||
| 247 | case 240: | ||
| 248 | case 320: | ||
| 249 | default: | ||
| 250 | /* Set Lcd Resolution (QVGA) */ | ||
| 251 | corgi_ssp_lcdtg_send(RESCTL_ADRS, RESCTL_QVGA); | ||
| 252 | break; | ||
| 253 | } | ||
| 254 | } | ||
| 255 | |||
| 256 | void corgi_lcdtg_suspend(void) | ||
| 257 | { | ||
| 258 | /* 60Hz x 2 frame = 16.7msec x 2 = 33.4 msec */ | ||
| 259 | mdelay(34); | ||
| 260 | |||
| 261 | /* (1)VW OFF */ | ||
| 262 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_ON | POWER1_VDD_ON); | ||
| 263 | |||
| 264 | /* (2)COM OFF */ | ||
| 265 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_COM_SIGNAL_OFF); | ||
| 266 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_ON); | ||
| 267 | |||
| 268 | /* (3)Set Common Voltage Bias 0V */ | ||
| 269 | lcdtg_set_common_voltage(POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_ON, 0); | ||
| 270 | |||
| 271 | /* (4)GVSS OFF */ | ||
| 272 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_ON); | ||
| 273 | |||
| 274 | /* (5)VCC5 OFF */ | ||
| 275 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_ON | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
| 276 | |||
| 277 | /* (6)Set PDWN, INIOFF, DACOFF */ | ||
| 278 | corgi_ssp_lcdtg_send(PICTRL_ADRS, PICTRL_INIOFF | PICTRL_DAC_SIGNAL_OFF | | ||
| 279 | PICTRL_POWER_DOWN | PICTRL_COM_SIGNAL_OFF); | ||
| 280 | |||
| 281 | /* (7)DAC OFF */ | ||
| 282 | corgi_ssp_lcdtg_send(POWERREG0_ADRS, POWER0_DAC_OFF | POWER0_COM_OFF | POWER0_VCC5_OFF); | ||
| 283 | |||
| 284 | /* (8)VDD OFF */ | ||
| 285 | corgi_ssp_lcdtg_send(POWERREG1_ADRS, POWER1_VW_OFF | POWER1_GVSS_OFF | POWER1_VDD_OFF); | ||
| 286 | |||
| 287 | lcd_inited = 0; | ||
| 288 | } | ||
| 289 | |||
diff --git a/arch/arm/mach-pxa/corgi_ssp.c b/arch/arm/mach-pxa/corgi_ssp.c new file mode 100644 index 000000000000..8e2f2215c4ba --- /dev/null +++ b/arch/arm/mach-pxa/corgi_ssp.c | |||
| @@ -0,0 +1,276 @@ | |||
| 1 | /* | ||
| 2 | * SSP control code for Sharp Corgi devices | ||
| 3 | * | ||
| 4 | * Copyright (c) 2004-2005 Richard Purdie | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | * | ||
| 10 | */ | ||
| 11 | |||
| 12 | #include <linux/module.h> | ||
| 13 | #include <linux/init.h> | ||
| 14 | #include <linux/kernel.h> | ||
| 15 | #include <linux/sched.h> | ||
| 16 | #include <linux/slab.h> | ||
| 17 | #include <linux/delay.h> | ||
| 18 | #include <linux/platform_device.h> | ||
| 19 | #include <mach/hardware.h> | ||
| 20 | #include <asm/mach-types.h> | ||
| 21 | |||
| 22 | #include <mach/ssp.h> | ||
| 23 | #include <mach/pxa-regs.h> | ||
| 24 | #include <mach/pxa2xx-gpio.h> | ||
| 25 | #include <mach/regs-ssp.h> | ||
| 26 | #include "sharpsl.h" | ||
| 27 | |||
| 28 | static DEFINE_SPINLOCK(corgi_ssp_lock); | ||
| 29 | static struct ssp_dev corgi_ssp_dev; | ||
| 30 | static struct ssp_state corgi_ssp_state; | ||
| 31 | static struct corgissp_machinfo *ssp_machinfo; | ||
| 32 | |||
| 33 | /* | ||
| 34 | * There are three devices connected to the SSP interface: | ||
| 35 | * 1. A touchscreen controller (TI ADS7846 compatible) | ||
| 36 | * 2. An LCD controller (with some Backlight functionality) | ||
| 37 | * 3. A battery monitoring IC (Maxim MAX1111) | ||
| 38 | * | ||
| 39 | * Each device uses a different speed/mode of communication. | ||
| 40 | * | ||
| 41 | * The touchscreen is very sensitive and the most frequently used | ||
| 42 | * so the port is left configured for this. | ||
| 43 | * | ||
| 44 | * Devices are selected using Chip Selects on GPIOs. | ||
| 45 | */ | ||
| 46 | |||
| 47 | /* | ||
| 48 | * ADS7846 Routines | ||
| 49 | */ | ||
| 50 | unsigned long corgi_ssp_ads7846_putget(ulong data) | ||
| 51 | { | ||
| 52 | unsigned long flag; | ||
| 53 | u32 ret = 0; | ||
| 54 | |||
| 55 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
| 56 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 57 | GPCR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
| 58 | |||
| 59 | ssp_write_word(&corgi_ssp_dev,data); | ||
| 60 | ssp_read_word(&corgi_ssp_dev, &ret); | ||
| 61 | |||
| 62 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 63 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
| 64 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
| 65 | |||
| 66 | return ret; | ||
| 67 | } | ||
| 68 | |||
| 69 | /* | ||
| 70 | * NOTE: These functions should always be called in interrupt context | ||
| 71 | * and use the _lock and _unlock functions. They are very time sensitive. | ||
| 72 | */ | ||
| 73 | void corgi_ssp_ads7846_lock(void) | ||
| 74 | { | ||
| 75 | spin_lock(&corgi_ssp_lock); | ||
| 76 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 77 | GPCR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
| 78 | } | ||
| 79 | |||
| 80 | void corgi_ssp_ads7846_unlock(void) | ||
| 81 | { | ||
| 82 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 83 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); | ||
| 84 | spin_unlock(&corgi_ssp_lock); | ||
| 85 | } | ||
| 86 | |||
| 87 | void corgi_ssp_ads7846_put(ulong data) | ||
| 88 | { | ||
| 89 | ssp_write_word(&corgi_ssp_dev,data); | ||
| 90 | } | ||
| 91 | |||
| 92 | unsigned long corgi_ssp_ads7846_get(void) | ||
| 93 | { | ||
| 94 | u32 ret = 0; | ||
| 95 | ssp_read_word(&corgi_ssp_dev, &ret); | ||
| 96 | return ret; | ||
| 97 | } | ||
| 98 | |||
| 99 | EXPORT_SYMBOL(corgi_ssp_ads7846_putget); | ||
| 100 | EXPORT_SYMBOL(corgi_ssp_ads7846_lock); | ||
| 101 | EXPORT_SYMBOL(corgi_ssp_ads7846_unlock); | ||
| 102 | EXPORT_SYMBOL(corgi_ssp_ads7846_put); | ||
| 103 | EXPORT_SYMBOL(corgi_ssp_ads7846_get); | ||
| 104 | |||
| 105 | |||
| 106 | /* | ||
| 107 | * LCD/Backlight Routines | ||
| 108 | */ | ||
| 109 | unsigned long corgi_ssp_dac_put(ulong data) | ||
| 110 | { | ||
| 111 | unsigned long flag, sscr1 = SSCR1_SPH; | ||
| 112 | u32 tmp; | ||
| 113 | |||
| 114 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
| 115 | |||
| 116 | if (machine_is_spitz() || machine_is_akita() || machine_is_borzoi()) | ||
| 117 | sscr1 = 0; | ||
| 118 | |||
| 119 | ssp_disable(&corgi_ssp_dev); | ||
| 120 | ssp_config(&corgi_ssp_dev, (SSCR0_Motorola | (SSCR0_DSS & 0x07 )), sscr1, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_lcdcon)); | ||
| 121 | ssp_enable(&corgi_ssp_dev); | ||
| 122 | |||
| 123 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
| 124 | GPCR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); | ||
| 125 | ssp_write_word(&corgi_ssp_dev,data); | ||
| 126 | /* Read null data back from device to prevent SSP overflow */ | ||
| 127 | ssp_read_word(&corgi_ssp_dev, &tmp); | ||
| 128 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
| 129 | GPSR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); | ||
| 130 | |||
| 131 | ssp_disable(&corgi_ssp_dev); | ||
| 132 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
| 133 | ssp_enable(&corgi_ssp_dev); | ||
| 134 | |||
| 135 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
| 136 | |||
| 137 | return 0; | ||
| 138 | } | ||
| 139 | |||
| 140 | void corgi_ssp_lcdtg_send(u8 adrs, u8 data) | ||
| 141 | { | ||
| 142 | corgi_ssp_dac_put(((adrs & 0x07) << 5) | (data & 0x1f)); | ||
| 143 | } | ||
| 144 | |||
| 145 | void corgi_ssp_blduty_set(int duty) | ||
| 146 | { | ||
| 147 | corgi_ssp_lcdtg_send(0x02,duty); | ||
| 148 | } | ||
| 149 | |||
| 150 | EXPORT_SYMBOL(corgi_ssp_lcdtg_send); | ||
| 151 | EXPORT_SYMBOL(corgi_ssp_blduty_set); | ||
| 152 | |||
| 153 | /* | ||
| 154 | * Max1111 Routines | ||
| 155 | */ | ||
| 156 | int corgi_ssp_max1111_get(ulong data) | ||
| 157 | { | ||
| 158 | unsigned long flag; | ||
| 159 | long voltage = 0, voltage1 = 0, voltage2 = 0; | ||
| 160 | |||
| 161 | spin_lock_irqsave(&corgi_ssp_lock, flag); | ||
| 162 | if (ssp_machinfo->cs_max1111 >= 0) | ||
| 163 | GPCR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); | ||
| 164 | ssp_disable(&corgi_ssp_dev); | ||
| 165 | ssp_config(&corgi_ssp_dev, (SSCR0_Motorola | (SSCR0_DSS & 0x07 )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_max1111)); | ||
| 166 | ssp_enable(&corgi_ssp_dev); | ||
| 167 | |||
| 168 | udelay(1); | ||
| 169 | |||
| 170 | /* TB1/RB1 */ | ||
| 171 | ssp_write_word(&corgi_ssp_dev,data); | ||
| 172 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage1); /* null read */ | ||
| 173 | |||
| 174 | /* TB12/RB2 */ | ||
| 175 | ssp_write_word(&corgi_ssp_dev,0); | ||
| 176 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage1); | ||
| 177 | |||
| 178 | /* TB13/RB3*/ | ||
| 179 | ssp_write_word(&corgi_ssp_dev,0); | ||
| 180 | ssp_read_word(&corgi_ssp_dev, (u32*)&voltage2); | ||
| 181 | |||
| 182 | ssp_disable(&corgi_ssp_dev); | ||
| 183 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
| 184 | ssp_enable(&corgi_ssp_dev); | ||
| 185 | if (ssp_machinfo->cs_max1111 >= 0) | ||
| 186 | GPSR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); | ||
| 187 | spin_unlock_irqrestore(&corgi_ssp_lock, flag); | ||
| 188 | |||
| 189 | if (voltage1 & 0xc0 || voltage2 & 0x3f) | ||
| 190 | voltage = -1; | ||
| 191 | else | ||
| 192 | voltage = ((voltage1 << 2) & 0xfc) | ((voltage2 >> 6) & 0x03); | ||
| 193 | |||
| 194 | return voltage; | ||
| 195 | } | ||
| 196 | |||
| 197 | EXPORT_SYMBOL(corgi_ssp_max1111_get); | ||
| 198 | |||
| 199 | /* | ||
| 200 | * Support Routines | ||
| 201 | */ | ||
| 202 | |||
| 203 | void __init corgi_ssp_set_machinfo(struct corgissp_machinfo *machinfo) | ||
| 204 | { | ||
| 205 | ssp_machinfo = machinfo; | ||
| 206 | } | ||
| 207 | |||
| 208 | static int __init corgi_ssp_probe(struct platform_device *dev) | ||
| 209 | { | ||
| 210 | int ret; | ||
| 211 | |||
| 212 | /* Chip Select - Disable All */ | ||
| 213 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
| 214 | pxa_gpio_mode(ssp_machinfo->cs_lcdcon | GPIO_OUT | GPIO_DFLT_HIGH); | ||
| 215 | if (ssp_machinfo->cs_max1111 >= 0) | ||
| 216 | pxa_gpio_mode(ssp_machinfo->cs_max1111 | GPIO_OUT | GPIO_DFLT_HIGH); | ||
| 217 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 218 | pxa_gpio_mode(ssp_machinfo->cs_ads7846 | GPIO_OUT | GPIO_DFLT_HIGH); | ||
| 219 | |||
| 220 | ret = ssp_init(&corgi_ssp_dev, ssp_machinfo->port, 0); | ||
| 221 | |||
| 222 | if (ret) | ||
| 223 | printk(KERN_ERR "Unable to register SSP handler!\n"); | ||
| 224 | else { | ||
| 225 | ssp_disable(&corgi_ssp_dev); | ||
| 226 | ssp_config(&corgi_ssp_dev, (SSCR0_National | (SSCR0_DSS & 0x0b )), 0, 0, SSCR0_SerClkDiv(ssp_machinfo->clk_ads7846)); | ||
| 227 | ssp_enable(&corgi_ssp_dev); | ||
| 228 | } | ||
| 229 | |||
| 230 | return ret; | ||
| 231 | } | ||
| 232 | |||
| 233 | static int corgi_ssp_remove(struct platform_device *dev) | ||
| 234 | { | ||
| 235 | ssp_exit(&corgi_ssp_dev); | ||
| 236 | return 0; | ||
| 237 | } | ||
| 238 | |||
| 239 | static int corgi_ssp_suspend(struct platform_device *dev, pm_message_t state) | ||
| 240 | { | ||
| 241 | ssp_flush(&corgi_ssp_dev); | ||
| 242 | ssp_save_state(&corgi_ssp_dev,&corgi_ssp_state); | ||
| 243 | |||
| 244 | return 0; | ||
| 245 | } | ||
| 246 | |||
| 247 | static int corgi_ssp_resume(struct platform_device *dev) | ||
| 248 | { | ||
| 249 | if (ssp_machinfo->cs_lcdcon >= 0) | ||
| 250 | GPSR(ssp_machinfo->cs_lcdcon) = GPIO_bit(ssp_machinfo->cs_lcdcon); /* High - Disable LCD Control/Timing Gen */ | ||
| 251 | if (ssp_machinfo->cs_max1111 >= 0) | ||
| 252 | GPSR(ssp_machinfo->cs_max1111) = GPIO_bit(ssp_machinfo->cs_max1111); /* High - Disable MAX1111*/ | ||
| 253 | if (ssp_machinfo->cs_ads7846 >= 0) | ||
| 254 | GPSR(ssp_machinfo->cs_ads7846) = GPIO_bit(ssp_machinfo->cs_ads7846); /* High - Disable ADS7846*/ | ||
| 255 | ssp_restore_state(&corgi_ssp_dev,&corgi_ssp_state); | ||
| 256 | ssp_enable(&corgi_ssp_dev); | ||
| 257 | |||
| 258 | return 0; | ||
| 259 | } | ||
| 260 | |||
| 261 | static struct platform_driver corgissp_driver = { | ||
| 262 | .probe = corgi_ssp_probe, | ||
| 263 | .remove = corgi_ssp_remove, | ||
| 264 | .suspend = corgi_ssp_suspend, | ||
| 265 | .resume = corgi_ssp_resume, | ||
| 266 | .driver = { | ||
| 267 | .name = "corgi-ssp", | ||
| 268 | }, | ||
| 269 | }; | ||
| 270 | |||
| 271 | int __init corgi_ssp_init(void) | ||
| 272 | { | ||
| 273 | return platform_driver_register(&corgissp_driver); | ||
| 274 | } | ||
| 275 | |||
| 276 | arch_initcall(corgi_ssp_init); | ||
diff --git a/arch/arm/mach-pxa/include/mach/corgi.h b/arch/arm/mach-pxa/include/mach/corgi.h index 585970ef08ce..7239281788de 100644 --- a/arch/arm/mach-pxa/include/mach/corgi.h +++ b/arch/arm/mach-pxa/include/mach/corgi.h | |||
| @@ -113,6 +113,7 @@ | |||
| 113 | * Shared data structures | 113 | * Shared data structures |
| 114 | */ | 114 | */ |
| 115 | extern struct platform_device corgiscoop_device; | 115 | extern struct platform_device corgiscoop_device; |
| 116 | extern struct platform_device corgissp_device; | ||
| 116 | 117 | ||
| 117 | #endif /* __ASM_ARCH_CORGI_H */ | 118 | #endif /* __ASM_ARCH_CORGI_H */ |
| 118 | 119 | ||
diff --git a/arch/arm/mach-pxa/include/mach/spitz.h b/arch/arm/mach-pxa/include/mach/spitz.h index e8488dfb7e91..fa1998caa78e 100644 --- a/arch/arm/mach-pxa/include/mach/spitz.h +++ b/arch/arm/mach-pxa/include/mach/spitz.h | |||
| @@ -187,4 +187,5 @@ | |||
| 187 | */ | 187 | */ |
| 188 | extern struct platform_device spitzscoop_device; | 188 | extern struct platform_device spitzscoop_device; |
| 189 | extern struct platform_device spitzscoop2_device; | 189 | extern struct platform_device spitzscoop2_device; |
| 190 | extern struct platform_device spitzssp_device; | ||
| 190 | extern struct sharpsl_charger_machinfo spitz_pm_machinfo; | 191 | extern struct sharpsl_charger_machinfo spitz_pm_machinfo; |
diff --git a/arch/arm/mach-pxa/include/mach/tosa.h b/arch/arm/mach-pxa/include/mach/tosa.h index 8bce6d8615b9..4df2d38507dc 100644 --- a/arch/arm/mach-pxa/include/mach/tosa.h +++ b/arch/arm/mach-pxa/include/mach/tosa.h | |||
| @@ -193,4 +193,7 @@ | |||
| 193 | #define TOSA_KEY_MAIL KEY_MAIL | 193 | #define TOSA_KEY_MAIL KEY_MAIL |
| 194 | #endif | 194 | #endif |
| 195 | 195 | ||
| 196 | struct spi_device; | ||
| 197 | extern int tosa_bl_enable(struct spi_device *spi, int enable); | ||
| 198 | |||
| 196 | #endif /* _ASM_ARCH_TOSA_H_ */ | 199 | #endif /* _ASM_ARCH_TOSA_H_ */ |
diff --git a/arch/arm/mach-pxa/sharpsl_pm.c b/arch/arm/mach-pxa/sharpsl_pm.c index 15c2f1a8623b..f0845c1b001c 100644 --- a/arch/arm/mach-pxa/sharpsl_pm.c +++ b/arch/arm/mach-pxa/sharpsl_pm.c | |||
| @@ -116,20 +116,33 @@ struct battery_thresh spitz_battery_levels_noac[] = { | |||
| 116 | { 0, 0}, | 116 | { 0, 0}, |
| 117 | }; | 117 | }; |
| 118 | 118 | ||
| 119 | /* MAX1111 Commands */ | ||
| 120 | #define MAXCTRL_PD0 1u << 0 | ||
| 121 | #define MAXCTRL_PD1 1u << 1 | ||
| 122 | #define MAXCTRL_SGL 1u << 2 | ||
| 123 | #define MAXCTRL_UNI 1u << 3 | ||
| 124 | #define MAXCTRL_SEL_SH 4 | ||
| 125 | #define MAXCTRL_STR 1u << 7 | ||
| 126 | |||
| 119 | /* | 127 | /* |
| 120 | * Read MAX1111 ADC | 128 | * Read MAX1111 ADC |
| 121 | */ | 129 | */ |
| 122 | extern int max1111_read_channel(int); | ||
| 123 | |||
| 124 | int sharpsl_pm_pxa_read_max1111(int channel) | 130 | int sharpsl_pm_pxa_read_max1111(int channel) |
| 125 | { | 131 | { |
| 126 | if (machine_is_tosa()) // Ugly, better move this function into another module | 132 | if (machine_is_tosa()) // Ugly, better move this function into another module |
| 127 | return 0; | 133 | return 0; |
| 128 | 134 | ||
| 135 | #ifdef CONFIG_CORGI_SSP_DEPRECATED | ||
| 136 | return corgi_ssp_max1111_get((channel << MAXCTRL_SEL_SH) | MAXCTRL_PD0 | MAXCTRL_PD1 | ||
| 137 | | MAXCTRL_SGL | MAXCTRL_UNI | MAXCTRL_STR); | ||
| 138 | #else | ||
| 139 | extern int max1111_read_channel(int); | ||
| 140 | |||
| 129 | /* max1111 accepts channels from 0-3, however, | 141 | /* max1111 accepts channels from 0-3, however, |
| 130 | * it is encoded from 0-7 here in the code. | 142 | * it is encoded from 0-7 here in the code. |
| 131 | */ | 143 | */ |
| 132 | return max1111_read_channel(channel >> 1); | 144 | return max1111_read_channel(channel >> 1); |
| 145 | #endif | ||
| 133 | } | 146 | } |
| 134 | 147 | ||
| 135 | void sharpsl_pm_pxa_init(void) | 148 | void sharpsl_pm_pxa_init(void) |
diff --git a/arch/arm/mach-pxa/tosa.c b/arch/arm/mach-pxa/tosa.c index a6c4694359ca..224897a67d15 100644 --- a/arch/arm/mach-pxa/tosa.c +++ b/arch/arm/mach-pxa/tosa.c | |||
| @@ -31,6 +31,7 @@ | |||
| 31 | #include <linux/gpio.h> | 31 | #include <linux/gpio.h> |
| 32 | #include <linux/pda_power.h> | 32 | #include <linux/pda_power.h> |
| 33 | #include <linux/rfkill.h> | 33 | #include <linux/rfkill.h> |
| 34 | #include <linux/spi/spi.h> | ||
| 34 | 35 | ||
| 35 | #include <asm/setup.h> | 36 | #include <asm/setup.h> |
| 36 | #include <asm/mach-types.h> | 37 | #include <asm/mach-types.h> |
| @@ -42,6 +43,7 @@ | |||
| 42 | #include <mach/mmc.h> | 43 | #include <mach/mmc.h> |
| 43 | #include <mach/udc.h> | 44 | #include <mach/udc.h> |
| 44 | #include <mach/tosa_bt.h> | 45 | #include <mach/tosa_bt.h> |
| 46 | #include <mach/pxa2xx_spi.h> | ||
| 45 | 47 | ||
| 46 | #include <asm/mach/arch.h> | 48 | #include <asm/mach/arch.h> |
| 47 | #include <mach/tosa.h> | 49 | #include <mach/tosa.h> |
| @@ -612,7 +614,7 @@ static int tosa_tc6393xb_enable(struct platform_device *dev) | |||
| 612 | rc = gpio_request(TOSA_GPIO_TC6393XB_SUSPEND, "tc6393xb #suspend"); | 614 | rc = gpio_request(TOSA_GPIO_TC6393XB_SUSPEND, "tc6393xb #suspend"); |
| 613 | if (rc) | 615 | if (rc) |
| 614 | goto err_req_suspend; | 616 | goto err_req_suspend; |
| 615 | rc = gpio_request(TOSA_GPIO_TC6393XB_L3V_ON, "l3v"); | 617 | rc = gpio_request(TOSA_GPIO_TC6393XB_L3V_ON, "tc6393xb l3v"); |
| 616 | if (rc) | 618 | if (rc) |
| 617 | goto err_req_l3v; | 619 | goto err_req_l3v; |
| 618 | rc = gpio_direction_output(TOSA_GPIO_TC6393XB_L3V_ON, 0); | 620 | rc = gpio_direction_output(TOSA_GPIO_TC6393XB_L3V_ON, 0); |
| @@ -772,6 +774,20 @@ static struct platform_device tosa_bt_device = { | |||
| 772 | .dev.platform_data = &tosa_bt_data, | 774 | .dev.platform_data = &tosa_bt_data, |
| 773 | }; | 775 | }; |
| 774 | 776 | ||
| 777 | static struct pxa2xx_spi_master pxa_ssp_master_info = { | ||
| 778 | .num_chipselect = 1, | ||
| 779 | }; | ||
| 780 | |||
| 781 | static struct spi_board_info spi_board_info[] __initdata = { | ||
| 782 | { | ||
| 783 | .modalias = "tosa-lcd", | ||
| 784 | // .platform_data | ||
| 785 | .max_speed_hz = 28750, | ||
| 786 | .bus_num = 2, | ||
| 787 | .chip_select = 0, | ||
| 788 | .mode = SPI_MODE_0, | ||
| 789 | }, | ||
| 790 | }; | ||
| 775 | 791 | ||
| 776 | static struct platform_device *devices[] __initdata = { | 792 | static struct platform_device *devices[] __initdata = { |
| 777 | &tosascoop_device, | 793 | &tosascoop_device, |
| @@ -826,6 +842,9 @@ static void __init tosa_init(void) | |||
| 826 | pxa_set_i2c_info(NULL); | 842 | pxa_set_i2c_info(NULL); |
| 827 | platform_scoop_config = &tosa_pcmcia_config; | 843 | platform_scoop_config = &tosa_pcmcia_config; |
| 828 | 844 | ||
| 845 | pxa2xx_set_spi_info(2, &pxa_ssp_master_info); | ||
| 846 | spi_register_board_info(spi_board_info, ARRAY_SIZE(spi_board_info)); | ||
| 847 | |||
| 829 | clk_add_alias("CLK_CK3P6MI", &tc6393xb_device.dev, "GPIO11_CLK", NULL); | 848 | clk_add_alias("CLK_CK3P6MI", &tc6393xb_device.dev, "GPIO11_CLK", NULL); |
| 830 | 849 | ||
| 831 | platform_add_devices(devices, ARRAY_SIZE(devices)); | 850 | platform_add_devices(devices, ARRAY_SIZE(devices)); |
diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index d1193884d76d..ab5f7a21350b 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig | |||
| @@ -400,9 +400,9 @@ config CPU_FEROCEON_OLD_ID | |||
| 400 | # ARMv6 | 400 | # ARMv6 |
| 401 | config CPU_V6 | 401 | config CPU_V6 |
| 402 | bool "Support ARM V6 processor" | 402 | bool "Support ARM V6 processor" |
| 403 | depends on ARCH_INTEGRATOR || MACH_REALVIEW_EB || ARCH_OMAP2 || ARCH_MX3 || ARCH_MSM7X00A || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 | 403 | depends on ARCH_INTEGRATOR || MACH_REALVIEW_EB || ARCH_OMAP2 || ARCH_MX3 || ARCH_MSM || MACH_REALVIEW_PB11MP || MACH_REALVIEW_PB1176 |
| 404 | default y if ARCH_MX3 | 404 | default y if ARCH_MX3 |
| 405 | default y if ARCH_MSM7X00A | 405 | default y if ARCH_MSM |
| 406 | select CPU_32v6 | 406 | select CPU_32v6 |
| 407 | select CPU_ABRT_EV6 | 407 | select CPU_ABRT_EV6 |
| 408 | select CPU_PABRT_NOIFAR | 408 | select CPU_PABRT_NOIFAR |
diff --git a/arch/arm/mm/proc-v7.S b/arch/arm/mm/proc-v7.S index 34e424041927..07f82db70945 100644 --- a/arch/arm/mm/proc-v7.S +++ b/arch/arm/mm/proc-v7.S | |||
| @@ -180,8 +180,8 @@ __v7_setup: | |||
| 180 | mov r10, #0x1f @ domains 0, 1 = manager | 180 | mov r10, #0x1f @ domains 0, 1 = manager |
| 181 | mcr p15, 0, r10, c3, c0, 0 @ load domain access register | 181 | mcr p15, 0, r10, c3, c0, 0 @ load domain access register |
| 182 | #endif | 182 | #endif |
| 183 | ldr r5, =0x40e040e0 | 183 | ldr r5, =0xff0aa1a8 |
| 184 | ldr r6, =0xff0aa1a8 | 184 | ldr r6, =0x40e040e0 |
| 185 | mcr p15, 0, r5, c10, c2, 0 @ write PRRR | 185 | mcr p15, 0, r5, c10, c2, 0 @ write PRRR |
| 186 | mcr p15, 0, r6, c10, c2, 1 @ write NMRR | 186 | mcr p15, 0, r6, c10, c2, 1 @ write NMRR |
| 187 | adr r5, v7_crval | 187 | adr r5, v7_crval |
diff --git a/arch/ia64/kvm/kvm-ia64.c b/arch/ia64/kvm/kvm-ia64.c index c0699f0e35a9..a312c9e9b9ef 100644 --- a/arch/ia64/kvm/kvm-ia64.c +++ b/arch/ia64/kvm/kvm-ia64.c | |||
| @@ -1114,7 +1114,7 @@ static void kvm_migrate_hlt_timer(struct kvm_vcpu *vcpu) | |||
| 1114 | struct hrtimer *p_ht = &vcpu->arch.hlt_timer; | 1114 | struct hrtimer *p_ht = &vcpu->arch.hlt_timer; |
| 1115 | 1115 | ||
| 1116 | if (hrtimer_cancel(p_ht)) | 1116 | if (hrtimer_cancel(p_ht)) |
| 1117 | hrtimer_start(p_ht, p_ht->expires, HRTIMER_MODE_ABS); | 1117 | hrtimer_start_expires(p_ht, HRTIMER_MODE_ABS); |
| 1118 | } | 1118 | } |
| 1119 | 1119 | ||
| 1120 | static enum hrtimer_restart hlt_timer_fn(struct hrtimer *data) | 1120 | static enum hrtimer_restart hlt_timer_fn(struct hrtimer *data) |
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c index 0a3f9e8ebde0..ab9862c3a136 100644 --- a/arch/m68k/amiga/config.c +++ b/arch/m68k/amiga/config.c | |||
| @@ -15,6 +15,7 @@ | |||
| 15 | #include <linux/types.h> | 15 | #include <linux/types.h> |
| 16 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
| 17 | #include <linux/mm.h> | 17 | #include <linux/mm.h> |
| 18 | #include <linux/seq_file.h> | ||
| 18 | #include <linux/tty.h> | 19 | #include <linux/tty.h> |
| 19 | #include <linux/console.h> | 20 | #include <linux/console.h> |
| 20 | #include <linux/rtc.h> | 21 | #include <linux/rtc.h> |
| @@ -93,7 +94,7 @@ static char amiga_model_name[13] = "Amiga "; | |||
| 93 | 94 | ||
| 94 | static void amiga_sched_init(irq_handler_t handler); | 95 | static void amiga_sched_init(irq_handler_t handler); |
| 95 | static void amiga_get_model(char *model); | 96 | static void amiga_get_model(char *model); |
| 96 | static int amiga_get_hardware_list(char *buffer); | 97 | static void amiga_get_hardware_list(struct seq_file *m); |
| 97 | /* amiga specific timer functions */ | 98 | /* amiga specific timer functions */ |
| 98 | static unsigned long amiga_gettimeoffset(void); | 99 | static unsigned long amiga_gettimeoffset(void); |
| 99 | static int a3000_hwclk(int, struct rtc_time *); | 100 | static int a3000_hwclk(int, struct rtc_time *); |
| @@ -911,13 +912,11 @@ static void amiga_get_model(char *model) | |||
| 911 | } | 912 | } |
| 912 | 913 | ||
| 913 | 914 | ||
| 914 | static int amiga_get_hardware_list(char *buffer) | 915 | static void amiga_get_hardware_list(struct seq_file *m) |
| 915 | { | 916 | { |
| 916 | int len = 0; | ||
| 917 | |||
| 918 | if (AMIGAHW_PRESENT(CHIP_RAM)) | 917 | if (AMIGAHW_PRESENT(CHIP_RAM)) |
| 919 | len += sprintf(buffer+len, "Chip RAM:\t%ldK\n", amiga_chip_size>>10); | 918 | seq_printf(m, "Chip RAM:\t%ldK\n", amiga_chip_size>>10); |
| 920 | len += sprintf(buffer+len, "PS Freq:\t%dHz\nEClock Freq:\t%ldHz\n", | 919 | seq_printf(m, "PS Freq:\t%dHz\nEClock Freq:\t%ldHz\n", |
| 921 | amiga_psfreq, amiga_eclock); | 920 | amiga_psfreq, amiga_eclock); |
| 922 | if (AMIGAHW_PRESENT(AMI_VIDEO)) { | 921 | if (AMIGAHW_PRESENT(AMI_VIDEO)) { |
| 923 | char *type; | 922 | char *type; |
| @@ -935,14 +934,14 @@ static int amiga_get_hardware_list(char *buffer) | |||
| 935 | type = "Old or Unknown"; | 934 | type = "Old or Unknown"; |
| 936 | break; | 935 | break; |
| 937 | } | 936 | } |
| 938 | len += sprintf(buffer+len, "Graphics:\t%s\n", type); | 937 | seq_printf(m, "Graphics:\t%s\n", type); |
| 939 | } | 938 | } |
| 940 | 939 | ||
| 941 | #define AMIGAHW_ANNOUNCE(name, str) \ | 940 | #define AMIGAHW_ANNOUNCE(name, str) \ |
| 942 | if (AMIGAHW_PRESENT(name)) \ | 941 | if (AMIGAHW_PRESENT(name)) \ |
| 943 | len += sprintf (buffer+len, "\t%s\n", str) | 942 | seq_printf (m, "\t%s\n", str) |
| 944 | 943 | ||
| 945 | len += sprintf (buffer + len, "Detected hardware:\n"); | 944 | seq_printf (m, "Detected hardware:\n"); |
| 946 | 945 | ||
| 947 | AMIGAHW_ANNOUNCE(AMI_VIDEO, "Amiga Video"); | 946 | AMIGAHW_ANNOUNCE(AMI_VIDEO, "Amiga Video"); |
| 948 | AMIGAHW_ANNOUNCE(AMI_BLITTER, "Blitter"); | 947 | AMIGAHW_ANNOUNCE(AMI_BLITTER, "Blitter"); |
| @@ -975,15 +974,13 @@ static int amiga_get_hardware_list(char *buffer) | |||
| 975 | AMIGAHW_ANNOUNCE(PCMCIA, "PCMCIA Slot"); | 974 | AMIGAHW_ANNOUNCE(PCMCIA, "PCMCIA Slot"); |
| 976 | #ifdef CONFIG_ZORRO | 975 | #ifdef CONFIG_ZORRO |
| 977 | if (AMIGAHW_PRESENT(ZORRO)) | 976 | if (AMIGAHW_PRESENT(ZORRO)) |
| 978 | len += sprintf(buffer+len, "\tZorro II%s AutoConfig: %d Expansion " | 977 | seq_printf(m, "\tZorro II%s AutoConfig: %d Expansion " |
| 979 | "Device%s\n", | 978 | "Device%s\n", |
| 980 | AMIGAHW_PRESENT(ZORRO3) ? "I" : "", | 979 | AMIGAHW_PRESENT(ZORRO3) ? "I" : "", |
| 981 | zorro_num_autocon, zorro_num_autocon == 1 ? "" : "s"); | 980 | zorro_num_autocon, zorro_num_autocon == 1 ? "" : "s"); |
| 982 | #endif /* CONFIG_ZORRO */ | 981 | #endif /* CONFIG_ZORRO */ |
| 983 | 982 | ||
| 984 | #undef AMIGAHW_ANNOUNCE | 983 | #undef AMIGAHW_ANNOUNCE |
| 985 | |||
| 986 | return len; | ||
| 987 | } | 984 | } |
| 988 | 985 | ||
| 989 | /* | 986 | /* |
diff --git a/arch/m68k/atari/config.c b/arch/m68k/atari/config.c index af031855f796..49c28cdbea5c 100644 --- a/arch/m68k/atari/config.c +++ b/arch/m68k/atari/config.c | |||
| @@ -26,6 +26,7 @@ | |||
| 26 | 26 | ||
| 27 | #include <linux/types.h> | 27 | #include <linux/types.h> |
| 28 | #include <linux/mm.h> | 28 | #include <linux/mm.h> |
| 29 | #include <linux/seq_file.h> | ||
| 29 | #include <linux/console.h> | 30 | #include <linux/console.h> |
| 30 | #include <linux/init.h> | 31 | #include <linux/init.h> |
| 31 | #include <linux/delay.h> | 32 | #include <linux/delay.h> |
| @@ -63,7 +64,7 @@ int atari_rtc_year_offset; | |||
| 63 | /* local function prototypes */ | 64 | /* local function prototypes */ |
| 64 | static void atari_reset(void); | 65 | static void atari_reset(void); |
| 65 | static void atari_get_model(char *model); | 66 | static void atari_get_model(char *model); |
| 66 | static int atari_get_hardware_list(char *buffer); | 67 | static void atari_get_hardware_list(struct seq_file *m); |
| 67 | 68 | ||
| 68 | /* atari specific irq functions */ | 69 | /* atari specific irq functions */ |
| 69 | extern void atari_init_IRQ (void); | 70 | extern void atari_init_IRQ (void); |
| @@ -611,21 +612,21 @@ static void atari_get_model(char *model) | |||
| 611 | } | 612 | } |
| 612 | 613 | ||
| 613 | 614 | ||
| 614 | static int atari_get_hardware_list(char *buffer) | 615 | static void atari_get_hardware_list(struct seq_file *m) |
| 615 | { | 616 | { |
| 616 | int len = 0, i; | 617 | int i; |
| 617 | 618 | ||
| 618 | for (i = 0; i < m68k_num_memory; i++) | 619 | for (i = 0; i < m68k_num_memory; i++) |
| 619 | len += sprintf(buffer+len, "\t%3ld MB at 0x%08lx (%s)\n", | 620 | seq_printf(m, "\t%3ld MB at 0x%08lx (%s)\n", |
| 620 | m68k_memory[i].size >> 20, m68k_memory[i].addr, | 621 | m68k_memory[i].size >> 20, m68k_memory[i].addr, |
| 621 | (m68k_memory[i].addr & 0xff000000 ? | 622 | (m68k_memory[i].addr & 0xff000000 ? |
| 622 | "alternate RAM" : "ST-RAM")); | 623 | "alternate RAM" : "ST-RAM")); |
| 623 | 624 | ||
| 624 | #define ATARIHW_ANNOUNCE(name, str) \ | 625 | #define ATARIHW_ANNOUNCE(name, str) \ |
| 625 | if (ATARIHW_PRESENT(name)) \ | 626 | if (ATARIHW_PRESENT(name)) \ |
| 626 | len += sprintf(buffer + len, "\t%s\n", str) | 627 | seq_printf(m, "\t%s\n", str) |
| 627 | 628 | ||
| 628 | len += sprintf(buffer + len, "Detected hardware:\n"); | 629 | seq_printf(m, "Detected hardware:\n"); |
| 629 | ATARIHW_ANNOUNCE(STND_SHIFTER, "ST Shifter"); | 630 | ATARIHW_ANNOUNCE(STND_SHIFTER, "ST Shifter"); |
| 630 | ATARIHW_ANNOUNCE(EXTD_SHIFTER, "STe Shifter"); | 631 | ATARIHW_ANNOUNCE(EXTD_SHIFTER, "STe Shifter"); |
| 631 | ATARIHW_ANNOUNCE(TT_SHIFTER, "TT Shifter"); | 632 | ATARIHW_ANNOUNCE(TT_SHIFTER, "TT Shifter"); |
| @@ -654,6 +655,4 @@ static int atari_get_hardware_list(char *buffer) | |||
| 654 | ATARIHW_ANNOUNCE(BLITTER, "Blitter"); | 655 | ATARIHW_ANNOUNCE(BLITTER, "Blitter"); |
| 655 | ATARIHW_ANNOUNCE(VME, "VME Bus"); | 656 | ATARIHW_ANNOUNCE(VME, "VME Bus"); |
| 656 | ATARIHW_ANNOUNCE(DSP56K, "DSP56001 processor"); | 657 | ATARIHW_ANNOUNCE(DSP56K, "DSP56001 processor"); |
| 657 | |||
| 658 | return len; | ||
| 659 | } | 658 | } |
diff --git a/arch/m68k/atari/stram.c b/arch/m68k/atari/stram.c index 04c69ffbea71..6ec3b7f33779 100644 --- a/arch/m68k/atari/stram.c +++ b/arch/m68k/atari/stram.c | |||
| @@ -42,6 +42,7 @@ | |||
| 42 | /* abbrev for the && above... */ | 42 | /* abbrev for the && above... */ |
| 43 | #define DO_PROC | 43 | #define DO_PROC |
| 44 | #include <linux/proc_fs.h> | 44 | #include <linux/proc_fs.h> |
| 45 | #include <linux/seq_file.h> | ||
| 45 | #endif | 46 | #endif |
| 46 | 47 | ||
| 47 | /* | 48 | /* |
| @@ -323,19 +324,16 @@ static int remove_region( BLOCK *block ) | |||
| 323 | 324 | ||
| 324 | #ifdef DO_PROC | 325 | #ifdef DO_PROC |
| 325 | 326 | ||
| 326 | #define PRINT_PROC(fmt,args...) len += sprintf( buf+len, fmt, ##args ) | 327 | #define PRINT_PROC(fmt,args...) seq_printf( m, fmt, ##args ) |
| 327 | 328 | ||
| 328 | int get_stram_list( char *buf ) | 329 | static int stram_proc_show(struct seq_file *m, void *v) |
| 329 | { | 330 | { |
| 330 | int len = 0; | ||
| 331 | BLOCK *p; | 331 | BLOCK *p; |
| 332 | 332 | ||
| 333 | PRINT_PROC("Total ST-RAM: %8u kB\n", | 333 | PRINT_PROC("Total ST-RAM: %8u kB\n", |
| 334 | (stram_end - stram_start) >> 10); | 334 | (stram_end - stram_start) >> 10); |
| 335 | PRINT_PROC( "Allocated regions:\n" ); | 335 | PRINT_PROC( "Allocated regions:\n" ); |
| 336 | for( p = alloc_list; p; p = p->next ) { | 336 | for( p = alloc_list; p; p = p->next ) { |
| 337 | if (len + 50 >= PAGE_SIZE) | ||
| 338 | break; | ||
| 339 | PRINT_PROC("0x%08lx-0x%08lx: %s (", | 337 | PRINT_PROC("0x%08lx-0x%08lx: %s (", |
| 340 | virt_to_phys(p->start), | 338 | virt_to_phys(p->start), |
| 341 | virt_to_phys(p->start+p->size-1), | 339 | virt_to_phys(p->start+p->size-1), |
| @@ -346,9 +344,27 @@ int get_stram_list( char *buf ) | |||
| 346 | PRINT_PROC( "??)\n" ); | 344 | PRINT_PROC( "??)\n" ); |
| 347 | } | 345 | } |
| 348 | 346 | ||
| 349 | return( len ); | 347 | return 0; |
| 348 | } | ||
| 349 | |||
| 350 | static int stram_proc_open(struct inode *inode, struct file *file) | ||
| 351 | { | ||
| 352 | return single_open(file, stram_proc_show, NULL); | ||
| 350 | } | 353 | } |
| 351 | 354 | ||
| 355 | static const struct file_operations stram_proc_fops = { | ||
| 356 | .open = stram_proc_open, | ||
| 357 | .read = seq_read, | ||
| 358 | .llseek = seq_lseek, | ||
| 359 | .release = single_release, | ||
| 360 | }; | ||
| 361 | |||
| 362 | static int __init proc_stram_init(void) | ||
| 363 | { | ||
| 364 | proc_create("stram", 0, NULL, &stram_proc_fops); | ||
| 365 | return 0; | ||
| 366 | } | ||
| 367 | module_init(proc_stram_init); | ||
| 352 | #endif | 368 | #endif |
| 353 | 369 | ||
| 354 | 370 | ||
diff --git a/arch/m68k/bvme6000/config.c b/arch/m68k/bvme6000/config.c index 65c9204ab9ac..c072595928c0 100644 --- a/arch/m68k/bvme6000/config.c +++ b/arch/m68k/bvme6000/config.c | |||
| @@ -38,7 +38,6 @@ | |||
| 38 | #include <asm/bvme6000hw.h> | 38 | #include <asm/bvme6000hw.h> |
| 39 | 39 | ||
| 40 | static void bvme6000_get_model(char *model); | 40 | static void bvme6000_get_model(char *model); |
| 41 | static int bvme6000_get_hardware_list(char *buffer); | ||
| 42 | extern void bvme6000_sched_init(irq_handler_t handler); | 41 | extern void bvme6000_sched_init(irq_handler_t handler); |
| 43 | extern unsigned long bvme6000_gettimeoffset (void); | 42 | extern unsigned long bvme6000_gettimeoffset (void); |
| 44 | extern int bvme6000_hwclk (int, struct rtc_time *); | 43 | extern int bvme6000_hwclk (int, struct rtc_time *); |
| @@ -82,15 +81,6 @@ static void bvme6000_get_model(char *model) | |||
| 82 | sprintf(model, "BVME%d000", m68k_cputype == CPU_68060 ? 6 : 4); | 81 | sprintf(model, "BVME%d000", m68k_cputype == CPU_68060 ? 6 : 4); |
| 83 | } | 82 | } |
| 84 | 83 | ||
| 85 | |||
| 86 | /* No hardware options on BVME6000? */ | ||
| 87 | |||
| 88 | static int bvme6000_get_hardware_list(char *buffer) | ||
| 89 | { | ||
| 90 | *buffer = '\0'; | ||
| 91 | return 0; | ||
| 92 | } | ||
| 93 | |||
| 94 | /* | 84 | /* |
| 95 | * This function is called during kernel startup to initialize | 85 | * This function is called during kernel startup to initialize |
| 96 | * the bvme6000 IRQ handling routines. | 86 | * the bvme6000 IRQ handling routines. |
| @@ -127,7 +117,6 @@ void __init config_bvme6000(void) | |||
| 127 | mach_set_clock_mmss = bvme6000_set_clock_mmss; | 117 | mach_set_clock_mmss = bvme6000_set_clock_mmss; |
| 128 | mach_reset = bvme6000_reset; | 118 | mach_reset = bvme6000_reset; |
| 129 | mach_get_model = bvme6000_get_model; | 119 | mach_get_model = bvme6000_get_model; |
| 130 | mach_get_hardware_list = bvme6000_get_hardware_list; | ||
| 131 | 120 | ||
| 132 | printk ("Board is %sconfigured as a System Controller\n", | 121 | printk ("Board is %sconfigured as a System Controller\n", |
| 133 | *config_reg_ptr & BVME_CONFIG_SW1 ? "" : "not "); | 122 | *config_reg_ptr & BVME_CONFIG_SW1 ? "" : "not "); |
diff --git a/arch/m68k/kernel/setup.c b/arch/m68k/kernel/setup.c index ea1e44da19b9..4d97bd2bd573 100644 --- a/arch/m68k/kernel/setup.c +++ b/arch/m68k/kernel/setup.c | |||
| @@ -20,6 +20,7 @@ | |||
| 20 | #include <linux/string.h> | 20 | #include <linux/string.h> |
| 21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
| 22 | #include <linux/bootmem.h> | 22 | #include <linux/bootmem.h> |
| 23 | #include <linux/proc_fs.h> | ||
| 23 | #include <linux/seq_file.h> | 24 | #include <linux/seq_file.h> |
| 24 | #include <linux/module.h> | 25 | #include <linux/module.h> |
| 25 | #include <linux/initrd.h> | 26 | #include <linux/initrd.h> |
| @@ -80,7 +81,7 @@ void (*mach_sched_init) (irq_handler_t handler) __initdata = NULL; | |||
| 80 | /* machine dependent irq functions */ | 81 | /* machine dependent irq functions */ |
| 81 | void (*mach_init_IRQ) (void) __initdata = NULL; | 82 | void (*mach_init_IRQ) (void) __initdata = NULL; |
| 82 | void (*mach_get_model) (char *model); | 83 | void (*mach_get_model) (char *model); |
| 83 | int (*mach_get_hardware_list) (char *buffer); | 84 | void (*mach_get_hardware_list) (struct seq_file *m); |
| 84 | /* machine dependent timer functions */ | 85 | /* machine dependent timer functions */ |
| 85 | unsigned long (*mach_gettimeoffset) (void); | 86 | unsigned long (*mach_gettimeoffset) (void); |
| 86 | int (*mach_hwclk) (int, struct rtc_time*); | 87 | int (*mach_hwclk) (int, struct rtc_time*); |
| @@ -467,9 +468,9 @@ const struct seq_operations cpuinfo_op = { | |||
| 467 | .show = show_cpuinfo, | 468 | .show = show_cpuinfo, |
| 468 | }; | 469 | }; |
| 469 | 470 | ||
| 470 | int get_hardware_list(char *buffer) | 471 | #ifdef CONFIG_PROC_HARDWARE |
| 472 | static int hardware_proc_show(struct seq_file *m, void *v) | ||
| 471 | { | 473 | { |
| 472 | int len = 0; | ||
| 473 | char model[80]; | 474 | char model[80]; |
| 474 | unsigned long mem; | 475 | unsigned long mem; |
| 475 | int i; | 476 | int i; |
| @@ -479,17 +480,37 @@ int get_hardware_list(char *buffer) | |||
| 479 | else | 480 | else |
| 480 | strcpy(model, "Unknown m68k"); | 481 | strcpy(model, "Unknown m68k"); |
| 481 | 482 | ||
| 482 | len += sprintf(buffer + len, "Model:\t\t%s\n", model); | 483 | seq_printf(m, "Model:\t\t%s\n", model); |
| 483 | for (mem = 0, i = 0; i < m68k_num_memory; i++) | 484 | for (mem = 0, i = 0; i < m68k_num_memory; i++) |
| 484 | mem += m68k_memory[i].size; | 485 | mem += m68k_memory[i].size; |
| 485 | len += sprintf(buffer + len, "System Memory:\t%ldK\n", mem >> 10); | 486 | seq_printf(m, "System Memory:\t%ldK\n", mem >> 10); |
| 486 | 487 | ||
| 487 | if (mach_get_hardware_list) | 488 | if (mach_get_hardware_list) |
| 488 | len += mach_get_hardware_list(buffer + len); | 489 | mach_get_hardware_list(m); |
| 489 | 490 | ||
| 490 | return len; | 491 | return 0; |
| 492 | } | ||
| 493 | |||
| 494 | static int hardware_proc_open(struct inode *inode, struct file *file) | ||
| 495 | { | ||
| 496 | return single_open(file, hardware_proc_show, NULL); | ||
| 491 | } | 497 | } |
| 492 | 498 | ||
| 499 | static const struct file_operations hardware_proc_fops = { | ||
| 500 | .open = hardware_proc_open, | ||
| 501 | .read = seq_read, | ||
| 502 | .llseek = seq_lseek, | ||
| 503 | .release = single_release, | ||
| 504 | }; | ||
| 505 | |||
| 506 | static int __init proc_hardware_init(void) | ||
| 507 | { | ||
| 508 | proc_create("hardware", 0, NULL, &hardware_proc_fops); | ||
| 509 | return 0; | ||
| 510 | } | ||
| 511 | module_init(proc_hardware_init); | ||
| 512 | #endif | ||
| 513 | |||
| 493 | void check_bugs(void) | 514 | void check_bugs(void) |
| 494 | { | 515 | { |
| 495 | #ifndef CONFIG_M68KFPU_EMU | 516 | #ifndef CONFIG_M68KFPU_EMU |
diff --git a/arch/m68k/mvme147/config.c b/arch/m68k/mvme147/config.c index 92fe50714112..43cdf476ffab 100644 --- a/arch/m68k/mvme147/config.c +++ b/arch/m68k/mvme147/config.c | |||
| @@ -37,7 +37,6 @@ | |||
| 37 | 37 | ||
| 38 | 38 | ||
| 39 | static void mvme147_get_model(char *model); | 39 | static void mvme147_get_model(char *model); |
| 40 | static int mvme147_get_hardware_list(char *buffer); | ||
| 41 | extern void mvme147_sched_init(irq_handler_t handler); | 40 | extern void mvme147_sched_init(irq_handler_t handler); |
| 42 | extern unsigned long mvme147_gettimeoffset (void); | 41 | extern unsigned long mvme147_gettimeoffset (void); |
| 43 | extern int mvme147_hwclk (int, struct rtc_time *); | 42 | extern int mvme147_hwclk (int, struct rtc_time *); |
| @@ -76,14 +75,6 @@ static void mvme147_get_model(char *model) | |||
| 76 | sprintf(model, "Motorola MVME147"); | 75 | sprintf(model, "Motorola MVME147"); |
| 77 | } | 76 | } |
| 78 | 77 | ||
| 79 | |||
| 80 | static int mvme147_get_hardware_list(char *buffer) | ||
| 81 | { | ||
| 82 | *buffer = '\0'; | ||
| 83 | |||
| 84 | return 0; | ||
| 85 | } | ||
| 86 | |||
| 87 | /* | 78 | /* |
| 88 | * This function is called during kernel startup to initialize | 79 | * This function is called during kernel startup to initialize |
| 89 | * the mvme147 IRQ handling routines. | 80 | * the mvme147 IRQ handling routines. |
| @@ -104,7 +95,6 @@ void __init config_mvme147(void) | |||
| 104 | mach_set_clock_mmss = mvme147_set_clock_mmss; | 95 | mach_set_clock_mmss = mvme147_set_clock_mmss; |
| 105 | mach_reset = mvme147_reset; | 96 | mach_reset = mvme147_reset; |
| 106 | mach_get_model = mvme147_get_model; | 97 | mach_get_model = mvme147_get_model; |
| 107 | mach_get_hardware_list = mvme147_get_hardware_list; | ||
| 108 | 98 | ||
| 109 | /* Board type is only set by newer versions of vmelilo/tftplilo */ | 99 | /* Board type is only set by newer versions of vmelilo/tftplilo */ |
| 110 | if (!vme_brdtype) | 100 | if (!vme_brdtype) |
diff --git a/arch/m68k/mvme16x/config.c b/arch/m68k/mvme16x/config.c index 24cbc3030454..1521826fc3c7 100644 --- a/arch/m68k/mvme16x/config.c +++ b/arch/m68k/mvme16x/config.c | |||
| @@ -17,6 +17,7 @@ | |||
| 17 | #include <linux/types.h> | 17 | #include <linux/types.h> |
| 18 | #include <linux/kernel.h> | 18 | #include <linux/kernel.h> |
| 19 | #include <linux/mm.h> | 19 | #include <linux/mm.h> |
| 20 | #include <linux/seq_file.h> | ||
| 20 | #include <linux/tty.h> | 21 | #include <linux/tty.h> |
| 21 | #include <linux/console.h> | 22 | #include <linux/console.h> |
| 22 | #include <linux/linkage.h> | 23 | #include <linux/linkage.h> |
| @@ -42,7 +43,6 @@ extern t_bdid mvme_bdid; | |||
| 42 | static MK48T08ptr_t volatile rtc = (MK48T08ptr_t)MVME_RTC_BASE; | 43 | static MK48T08ptr_t volatile rtc = (MK48T08ptr_t)MVME_RTC_BASE; |
| 43 | 44 | ||
| 44 | static void mvme16x_get_model(char *model); | 45 | static void mvme16x_get_model(char *model); |
| 45 | static int mvme16x_get_hardware_list(char *buffer); | ||
| 46 | extern void mvme16x_sched_init(irq_handler_t handler); | 46 | extern void mvme16x_sched_init(irq_handler_t handler); |
| 47 | extern unsigned long mvme16x_gettimeoffset (void); | 47 | extern unsigned long mvme16x_gettimeoffset (void); |
| 48 | extern int mvme16x_hwclk (int, struct rtc_time *); | 48 | extern int mvme16x_hwclk (int, struct rtc_time *); |
| @@ -93,26 +93,21 @@ static void mvme16x_get_model(char *model) | |||
| 93 | } | 93 | } |
| 94 | 94 | ||
| 95 | 95 | ||
| 96 | static int mvme16x_get_hardware_list(char *buffer) | 96 | static void mvme16x_get_hardware_list(struct seq_file *m) |
| 97 | { | 97 | { |
| 98 | p_bdid p = &mvme_bdid; | 98 | p_bdid p = &mvme_bdid; |
| 99 | int len = 0; | ||
| 100 | 99 | ||
| 101 | if (p->brdno == 0x0162 || p->brdno == 0x0172) | 100 | if (p->brdno == 0x0162 || p->brdno == 0x0172) |
| 102 | { | 101 | { |
| 103 | unsigned char rev = *(unsigned char *)MVME162_VERSION_REG; | 102 | unsigned char rev = *(unsigned char *)MVME162_VERSION_REG; |
| 104 | 103 | ||
| 105 | len += sprintf (buffer+len, "VMEchip2 %spresent\n", | 104 | seq_printf (m, "VMEchip2 %spresent\n", |
| 106 | rev & MVME16x_CONFIG_NO_VMECHIP2 ? "NOT " : ""); | 105 | rev & MVME16x_CONFIG_NO_VMECHIP2 ? "NOT " : ""); |
| 107 | len += sprintf (buffer+len, "SCSI interface %spresent\n", | 106 | seq_printf (m, "SCSI interface %spresent\n", |
| 108 | rev & MVME16x_CONFIG_NO_SCSICHIP ? "NOT " : ""); | 107 | rev & MVME16x_CONFIG_NO_SCSICHIP ? "NOT " : ""); |
| 109 | len += sprintf (buffer+len, "Ethernet i/f %spresent\n", | 108 | seq_printf (m, "Ethernet i/f %spresent\n", |
| 110 | rev & MVME16x_CONFIG_NO_ETHERNET ? "NOT " : ""); | 109 | rev & MVME16x_CONFIG_NO_ETHERNET ? "NOT " : ""); |
| 111 | } | 110 | } |
| 112 | else | ||
| 113 | *buffer = '\0'; | ||
| 114 | |||
| 115 | return (len); | ||
| 116 | } | 111 | } |
| 117 | 112 | ||
| 118 | /* | 113 | /* |
diff --git a/arch/m68k/q40/config.c b/arch/m68k/q40/config.c index 9c7eefa3f98a..7110546e3c00 100644 --- a/arch/m68k/q40/config.c +++ b/arch/m68k/q40/config.c | |||
| @@ -39,7 +39,6 @@ | |||
| 39 | extern irqreturn_t q40_process_int(int level, struct pt_regs *regs); | 39 | extern irqreturn_t q40_process_int(int level, struct pt_regs *regs); |
| 40 | extern void q40_init_IRQ(void); | 40 | extern void q40_init_IRQ(void); |
| 41 | static void q40_get_model(char *model); | 41 | static void q40_get_model(char *model); |
| 42 | static int q40_get_hardware_list(char *buffer); | ||
| 43 | extern void q40_sched_init(irq_handler_t handler); | 42 | extern void q40_sched_init(irq_handler_t handler); |
| 44 | 43 | ||
| 45 | static unsigned long q40_gettimeoffset(void); | 44 | static unsigned long q40_gettimeoffset(void); |
| @@ -153,14 +152,6 @@ static void q40_get_model(char *model) | |||
| 153 | sprintf(model, "Q40"); | 152 | sprintf(model, "Q40"); |
| 154 | } | 153 | } |
| 155 | 154 | ||
| 156 | /* No hardware options on Q40? */ | ||
| 157 | |||
| 158 | static int q40_get_hardware_list(char *buffer) | ||
| 159 | { | ||
| 160 | *buffer = '\0'; | ||
| 161 | return 0; | ||
| 162 | } | ||
| 163 | |||
| 164 | static unsigned int serports[] = | 155 | static unsigned int serports[] = |
| 165 | { | 156 | { |
| 166 | 0x3f8,0x2f8,0x3e8,0x2e8,0 | 157 | 0x3f8,0x2f8,0x3e8,0x2e8,0 |
| @@ -191,7 +182,6 @@ void __init config_q40(void) | |||
| 191 | 182 | ||
| 192 | mach_reset = q40_reset; | 183 | mach_reset = q40_reset; |
| 193 | mach_get_model = q40_get_model; | 184 | mach_get_model = q40_get_model; |
| 194 | mach_get_hardware_list = q40_get_hardware_list; | ||
| 195 | 185 | ||
| 196 | #if defined(CONFIG_INPUT_M68K_BEEP) || defined(CONFIG_INPUT_M68K_BEEP_MODULE) | 186 | #if defined(CONFIG_INPUT_M68K_BEEP) || defined(CONFIG_INPUT_M68K_BEEP_MODULE) |
| 197 | mach_beep = q40_mksound; | 187 | mach_beep = q40_mksound; |
diff --git a/arch/m68k/sun3/config.c b/arch/m68k/sun3/config.c index 732087d0735c..8dfaa201342e 100644 --- a/arch/m68k/sun3/config.c +++ b/arch/m68k/sun3/config.c | |||
| @@ -11,6 +11,7 @@ | |||
| 11 | #include <linux/types.h> | 11 | #include <linux/types.h> |
| 12 | #include <linux/kernel.h> | 12 | #include <linux/kernel.h> |
| 13 | #include <linux/mm.h> | 13 | #include <linux/mm.h> |
| 14 | #include <linux/seq_file.h> | ||
| 14 | #include <linux/tty.h> | 15 | #include <linux/tty.h> |
| 15 | #include <linux/console.h> | 16 | #include <linux/console.h> |
| 16 | #include <linux/init.h> | 17 | #include <linux/init.h> |
| @@ -46,16 +47,9 @@ extern volatile unsigned char* sun3_intreg; | |||
| 46 | extern unsigned long availmem; | 47 | extern unsigned long availmem; |
| 47 | unsigned long num_pages; | 48 | unsigned long num_pages; |
| 48 | 49 | ||
| 49 | static int sun3_get_hardware_list(char *buffer) | 50 | static void sun3_get_hardware_list(struct seq_file *m) |
| 50 | { | 51 | { |
| 51 | 52 | seq_printf(m, "PROM Revision:\t%s\n", romvec->pv_monid); | |
| 52 | int len = 0; | ||
| 53 | |||
| 54 | len += sprintf(buffer + len, "PROM Revision:\t%s\n", | ||
| 55 | romvec->pv_monid); | ||
| 56 | |||
| 57 | return len; | ||
| 58 | |||
| 59 | } | 53 | } |
| 60 | 54 | ||
| 61 | void __init sun3_init(void) | 55 | void __init sun3_init(void) |
diff --git a/arch/m68k/sun3x/config.c b/arch/m68k/sun3x/config.c index 987891783a47..2b1ca2db070f 100644 --- a/arch/m68k/sun3x/config.c +++ b/arch/m68k/sun3x/config.c | |||
| @@ -8,6 +8,7 @@ | |||
| 8 | 8 | ||
| 9 | #include <linux/types.h> | 9 | #include <linux/types.h> |
| 10 | #include <linux/mm.h> | 10 | #include <linux/mm.h> |
| 11 | #include <linux/seq_file.h> | ||
| 11 | #include <linux/console.h> | 12 | #include <linux/console.h> |
| 12 | #include <linux/init.h> | 13 | #include <linux/init.h> |
| 13 | 14 | ||
| @@ -31,16 +32,9 @@ void sun3_leds(unsigned int i) | |||
| 31 | 32 | ||
| 32 | } | 33 | } |
| 33 | 34 | ||
| 34 | static int sun3x_get_hardware_list(char *buffer) | 35 | static void sun3x_get_hardware_list(struct seq_file *m) |
| 35 | { | 36 | { |
| 36 | 37 | seq_printf(m, "PROM Revision:\t%s\n", romvec->pv_monid); | |
| 37 | int len = 0; | ||
| 38 | |||
| 39 | len += sprintf(buffer + len, "PROM Revision:\t%s\n", | ||
| 40 | romvec->pv_monid); | ||
| 41 | |||
| 42 | return len; | ||
| 43 | |||
| 44 | } | 38 | } |
| 45 | 39 | ||
| 46 | /* | 40 | /* |
diff --git a/arch/mips/include/asm/txx9/tx4938.h b/arch/mips/include/asm/txx9/tx4938.h index 989e7751135a..0b068154054c 100644 --- a/arch/mips/include/asm/txx9/tx4938.h +++ b/arch/mips/include/asm/txx9/tx4938.h | |||
| @@ -292,4 +292,17 @@ void tx4938_setup_pcierr_irq(void); | |||
| 292 | void tx4938_irq_init(void); | 292 | void tx4938_irq_init(void); |
| 293 | void tx4938_mtd_init(int ch); | 293 | void tx4938_mtd_init(int ch); |
| 294 | 294 | ||
| 295 | struct tx4938ide_platform_info { | ||
| 296 | /* | ||
| 297 | * I/O port shift, for platforms with ports that are | ||
| 298 | * constantly spaced and need larger than the 1-byte | ||
| 299 | * spacing used by ata_std_ports(). | ||
| 300 | */ | ||
| 301 | unsigned int ioport_shift; | ||
| 302 | unsigned int gbus_clock; /* 0 means no PIO mode tuning. */ | ||
| 303 | unsigned int ebus_ch; | ||
| 304 | }; | ||
| 305 | |||
| 306 | void tx4938_ata_init(unsigned int irq, unsigned int shift, int tune); | ||
| 307 | |||
| 295 | #endif | 308 | #endif |
diff --git a/arch/mips/txx9/generic/setup_tx4938.c b/arch/mips/txx9/generic/setup_tx4938.c index af724e53ef91..25819ff1c350 100644 --- a/arch/mips/txx9/generic/setup_tx4938.c +++ b/arch/mips/txx9/generic/setup_tx4938.c | |||
| @@ -16,6 +16,7 @@ | |||
| 16 | #include <linux/param.h> | 16 | #include <linux/param.h> |
| 17 | #include <linux/ptrace.h> | 17 | #include <linux/ptrace.h> |
| 18 | #include <linux/mtd/physmap.h> | 18 | #include <linux/mtd/physmap.h> |
| 19 | #include <linux/platform_device.h> | ||
| 19 | #include <asm/reboot.h> | 20 | #include <asm/reboot.h> |
| 20 | #include <asm/traps.h> | 21 | #include <asm/traps.h> |
| 21 | #include <asm/txx9irq.h> | 22 | #include <asm/txx9irq.h> |
| @@ -335,6 +336,52 @@ void __init tx4938_mtd_init(int ch) | |||
| 335 | txx9_physmap_flash_init(ch, start, size, &pdata); | 336 | txx9_physmap_flash_init(ch, start, size, &pdata); |
| 336 | } | 337 | } |
| 337 | 338 | ||
| 339 | void __init tx4938_ata_init(unsigned int irq, unsigned int shift, int tune) | ||
| 340 | { | ||
| 341 | struct platform_device *pdev; | ||
| 342 | struct resource res[] = { | ||
| 343 | { | ||
| 344 | /* .start and .end are filled in later */ | ||
| 345 | .flags = IORESOURCE_MEM, | ||
| 346 | }, { | ||
| 347 | .start = irq, | ||
| 348 | .flags = IORESOURCE_IRQ, | ||
| 349 | }, | ||
| 350 | }; | ||
| 351 | struct tx4938ide_platform_info pdata = { | ||
| 352 | .ioport_shift = shift, | ||
| 353 | /* | ||
| 354 | * The IDE driver should not change bus timings if other ISA | ||
| 355 | * devices existed. | ||
| 356 | */ | ||
| 357 | .gbus_clock = tune ? txx9_gbus_clock : 0, | ||
| 358 | }; | ||
| 359 | u64 ebccr; | ||
| 360 | int i; | ||
| 361 | |||
| 362 | if ((__raw_readq(&tx4938_ccfgptr->pcfg) & | ||
| 363 | (TX4938_PCFG_ATA_SEL | TX4938_PCFG_NDF_SEL)) | ||
| 364 | != TX4938_PCFG_ATA_SEL) | ||
| 365 | return; | ||
| 366 | for (i = 0; i < 8; i++) { | ||
| 367 | /* check EBCCRn.ISA, EBCCRn.BSZ, EBCCRn.ME */ | ||
| 368 | ebccr = __raw_readq(&tx4938_ebuscptr->cr[i]); | ||
| 369 | if ((ebccr & 0x00f00008) == 0x00e00008) | ||
| 370 | break; | ||
| 371 | } | ||
| 372 | if (i == 8) | ||
| 373 | return; | ||
| 374 | pdata.ebus_ch = i; | ||
| 375 | res[0].start = ((ebccr >> 48) << 20) + 0x10000; | ||
| 376 | res[0].end = res[0].start + 0x20000 - 1; | ||
| 377 | pdev = platform_device_alloc("tx4938ide", -1); | ||
| 378 | if (!pdev || | ||
| 379 | platform_device_add_resources(pdev, res, ARRAY_SIZE(res)) || | ||
| 380 | platform_device_add_data(pdev, &pdata, sizeof(pdata)) || | ||
| 381 | platform_device_add(pdev)) | ||
| 382 | platform_device_put(pdev); | ||
| 383 | } | ||
| 384 | |||
| 338 | static void __init tx4938_stop_unused_modules(void) | 385 | static void __init tx4938_stop_unused_modules(void) |
| 339 | { | 386 | { |
| 340 | __u64 pcfg, rst = 0, ckd = 0; | 387 | __u64 pcfg, rst = 0, ckd = 0; |
diff --git a/arch/mips/txx9/rbtx4938/setup.c b/arch/mips/txx9/rbtx4938/setup.c index e077cc4d3a59..547ff2920bf0 100644 --- a/arch/mips/txx9/rbtx4938/setup.c +++ b/arch/mips/txx9/rbtx4938/setup.c | |||
| @@ -352,6 +352,7 @@ static void __init rbtx4938_device_init(void) | |||
| 352 | rbtx4938_ne_init(); | 352 | rbtx4938_ne_init(); |
| 353 | tx4938_wdt_init(); | 353 | tx4938_wdt_init(); |
| 354 | rbtx4938_mtd_init(); | 354 | rbtx4938_mtd_init(); |
| 355 | tx4938_ata_init(RBTX4938_IRQ_IOC_ATA, 0, 1); | ||
| 355 | txx9_iocled_init(RBTX4938_LED_ADDR - IO_BASE, -1, 8, 1, "green", NULL); | 356 | txx9_iocled_init(RBTX4938_LED_ADDR - IO_BASE, -1, 8, 1, "green", NULL); |
| 356 | } | 357 | } |
| 357 | 358 | ||
diff --git a/arch/powerpc/oprofile/cell/spu_profiler.c b/arch/powerpc/oprofile/cell/spu_profiler.c index 6edaebd5099a..dd499c3e9da7 100644 --- a/arch/powerpc/oprofile/cell/spu_profiler.c +++ b/arch/powerpc/oprofile/cell/spu_profiler.c | |||
| @@ -195,7 +195,7 @@ int start_spu_profiling(unsigned int cycles_reset) | |||
| 195 | pr_debug("timer resolution: %lu\n", TICK_NSEC); | 195 | pr_debug("timer resolution: %lu\n", TICK_NSEC); |
| 196 | kt = ktime_set(0, profiling_interval); | 196 | kt = ktime_set(0, profiling_interval); |
| 197 | hrtimer_init(&timer, CLOCK_MONOTONIC, HRTIMER_MODE_REL); | 197 | hrtimer_init(&timer, CLOCK_MONOTONIC, HRTIMER_MODE_REL); |
| 198 | timer.expires = kt; | 198 | hrtimer_set_expires(&timer, kt); |
| 199 | timer.function = profile_spus; | 199 | timer.function = profile_spus; |
| 200 | 200 | ||
| 201 | /* Allocate arrays for collecting SPU PC samples */ | 201 | /* Allocate arrays for collecting SPU PC samples */ |
diff --git a/arch/sparc/kernel/apc.c b/arch/sparc/kernel/apc.c index 4dd1ba752ce6..9c115823c4b5 100644 --- a/arch/sparc/kernel/apc.c +++ b/arch/sparc/kernel/apc.c | |||
| @@ -31,7 +31,7 @@ | |||
| 31 | #define APC_DEVNAME "apc" | 31 | #define APC_DEVNAME "apc" |
| 32 | 32 | ||
| 33 | static u8 __iomem *regs; | 33 | static u8 __iomem *regs; |
| 34 | static int apc_no_idle __initdata = 0; | 34 | static int apc_no_idle __devinitdata = 0; |
| 35 | 35 | ||
| 36 | #define apc_readb(offs) (sbus_readb(regs+offs)) | 36 | #define apc_readb(offs) (sbus_readb(regs+offs)) |
| 37 | #define apc_writeb(val, offs) (sbus_writeb(val, regs+offs)) | 37 | #define apc_writeb(val, offs) (sbus_writeb(val, regs+offs)) |
diff --git a/arch/sparc/kernel/head.S b/arch/sparc/kernel/head.S index 2d325fd84579..2fe2c117e772 100644 --- a/arch/sparc/kernel/head.S +++ b/arch/sparc/kernel/head.S | |||
| @@ -465,6 +465,7 @@ gokernel: | |||
| 465 | mov %o7, %g4 ! Save %o7 | 465 | mov %o7, %g4 ! Save %o7 |
| 466 | 466 | ||
| 467 | /* Jump to it, and pray... */ | 467 | /* Jump to it, and pray... */ |
| 468 | __INIT | ||
| 468 | current_pc: | 469 | current_pc: |
| 469 | call 1f | 470 | call 1f |
| 470 | nop | 471 | nop |
diff --git a/arch/sparc64/kernel/trampoline.S b/arch/sparc64/kernel/trampoline.S index 704a3afcfd06..83abd5ae88a4 100644 --- a/arch/sparc64/kernel/trampoline.S +++ b/arch/sparc64/kernel/trampoline.S | |||
| @@ -328,6 +328,12 @@ after_lock_tlb: | |||
| 328 | 328 | ||
| 329 | wrpr %g0, 0, %wstate | 329 | wrpr %g0, 0, %wstate |
| 330 | 330 | ||
| 331 | sethi %hi(prom_entry_lock), %g2 | ||
| 332 | 1: ldstub [%g2 + %lo(prom_entry_lock)], %g1 | ||
| 333 | membar #StoreLoad | #StoreStore | ||
| 334 | brnz,pn %g1, 1b | ||
| 335 | nop | ||
| 336 | |||
| 331 | /* As a hack, put &init_thread_union into %g6. | 337 | /* As a hack, put &init_thread_union into %g6. |
| 332 | * prom_world() loads from here to restore the %asi | 338 | * prom_world() loads from here to restore the %asi |
| 333 | * register. | 339 | * register. |
| @@ -337,7 +343,7 @@ after_lock_tlb: | |||
| 337 | 343 | ||
| 338 | sethi %hi(is_sun4v), %o0 | 344 | sethi %hi(is_sun4v), %o0 |
| 339 | lduw [%o0 + %lo(is_sun4v)], %o0 | 345 | lduw [%o0 + %lo(is_sun4v)], %o0 |
| 340 | brz,pt %o0, 1f | 346 | brz,pt %o0, 2f |
| 341 | nop | 347 | nop |
| 342 | 348 | ||
| 343 | TRAP_LOAD_TRAP_BLOCK(%g2, %g3) | 349 | TRAP_LOAD_TRAP_BLOCK(%g2, %g3) |
| @@ -369,10 +375,10 @@ after_lock_tlb: | |||
| 369 | call %o1 | 375 | call %o1 |
| 370 | add %sp, (2047 + 128), %o0 | 376 | add %sp, (2047 + 128), %o0 |
| 371 | 377 | ||
| 372 | ba,pt %xcc, 2f | 378 | ba,pt %xcc, 3f |
| 373 | nop | 379 | nop |
| 374 | 380 | ||
| 375 | 1: sethi %hi(sparc64_ttable_tl0), %o0 | 381 | 2: sethi %hi(sparc64_ttable_tl0), %o0 |
| 376 | set prom_set_trap_table_name, %g2 | 382 | set prom_set_trap_table_name, %g2 |
| 377 | stx %g2, [%sp + 2047 + 128 + 0x00] | 383 | stx %g2, [%sp + 2047 + 128 + 0x00] |
| 378 | mov 1, %g2 | 384 | mov 1, %g2 |
| @@ -386,7 +392,11 @@ after_lock_tlb: | |||
| 386 | call %o1 | 392 | call %o1 |
| 387 | add %sp, (2047 + 128), %o0 | 393 | add %sp, (2047 + 128), %o0 |
| 388 | 394 | ||
| 389 | 2: ldx [%l0], %g6 | 395 | 3: sethi %hi(prom_entry_lock), %g2 |
| 396 | stb %g0, [%g2 + %lo(prom_entry_lock)] | ||
| 397 | membar #StoreStore | #StoreLoad | ||
| 398 | |||
| 399 | ldx [%l0], %g6 | ||
| 390 | ldx [%g6 + TI_TASK], %g4 | 400 | ldx [%g6 + TI_TASK], %g4 |
| 391 | 401 | ||
| 392 | mov 1, %g5 | 402 | mov 1, %g5 |
diff --git a/arch/x86/boot/video-bios.c b/arch/x86/boot/video-bios.c index 49f26aaaebc8..3fa979c9c363 100644 --- a/arch/x86/boot/video-bios.c +++ b/arch/x86/boot/video-bios.c | |||
| @@ -17,7 +17,7 @@ | |||
| 17 | #include "boot.h" | 17 | #include "boot.h" |
| 18 | #include "video.h" | 18 | #include "video.h" |
| 19 | 19 | ||
| 20 | __videocard video_bios; | 20 | static __videocard video_bios; |
| 21 | 21 | ||
| 22 | /* Set a conventional BIOS mode */ | 22 | /* Set a conventional BIOS mode */ |
| 23 | static int set_bios_mode(u8 mode); | 23 | static int set_bios_mode(u8 mode); |
| @@ -119,7 +119,7 @@ static int bios_probe(void) | |||
| 119 | return nmodes; | 119 | return nmodes; |
| 120 | } | 120 | } |
| 121 | 121 | ||
| 122 | __videocard video_bios = | 122 | static __videocard video_bios = |
| 123 | { | 123 | { |
| 124 | .card_name = "BIOS", | 124 | .card_name = "BIOS", |
| 125 | .probe = bios_probe, | 125 | .probe = bios_probe, |
diff --git a/arch/x86/boot/video-vesa.c b/arch/x86/boot/video-vesa.c index 99b3079dc6ab..75115849af33 100644 --- a/arch/x86/boot/video-vesa.c +++ b/arch/x86/boot/video-vesa.c | |||
| @@ -20,7 +20,7 @@ | |||
| 20 | static struct vesa_general_info vginfo; | 20 | static struct vesa_general_info vginfo; |
| 21 | static struct vesa_mode_info vminfo; | 21 | static struct vesa_mode_info vminfo; |
| 22 | 22 | ||
| 23 | __videocard video_vesa; | 23 | static __videocard video_vesa; |
| 24 | 24 | ||
| 25 | #ifndef _WAKEUP | 25 | #ifndef _WAKEUP |
| 26 | static void vesa_store_mode_params_graphics(void); | 26 | static void vesa_store_mode_params_graphics(void); |
| @@ -293,7 +293,7 @@ void vesa_store_edid(void) | |||
| 293 | 293 | ||
| 294 | #endif /* not _WAKEUP */ | 294 | #endif /* not _WAKEUP */ |
| 295 | 295 | ||
| 296 | __videocard video_vesa = | 296 | static __videocard video_vesa = |
| 297 | { | 297 | { |
| 298 | .card_name = "VESA", | 298 | .card_name = "VESA", |
| 299 | .probe = vesa_probe, | 299 | .probe = vesa_probe, |
diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index fb7d1e9985b5..c012f3b11671 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h | |||
| @@ -348,7 +348,8 @@ static inline void native_pagetable_setup_start(pgd_t *base) {} | |||
| 348 | static inline void native_pagetable_setup_done(pgd_t *base) {} | 348 | static inline void native_pagetable_setup_done(pgd_t *base) {} |
| 349 | #endif | 349 | #endif |
| 350 | 350 | ||
| 351 | extern int arch_report_meminfo(char *page); | 351 | struct seq_file; |
| 352 | extern void arch_report_meminfo(struct seq_file *m); | ||
| 352 | 353 | ||
| 353 | #ifdef CONFIG_PARAVIRT | 354 | #ifdef CONFIG_PARAVIRT |
| 354 | #include <asm/paravirt.h> | 355 | #include <asm/paravirt.h> |
diff --git a/arch/x86/include/asm/syscall.h b/arch/x86/include/asm/syscall.h index 1d88f6957d39..d82f39bb7905 100644 --- a/arch/x86/include/asm/syscall.h +++ b/arch/x86/include/asm/syscall.h | |||
| @@ -93,26 +93,26 @@ static inline void syscall_get_arguments(struct task_struct *task, | |||
| 93 | { | 93 | { |
| 94 | # ifdef CONFIG_IA32_EMULATION | 94 | # ifdef CONFIG_IA32_EMULATION |
| 95 | if (task_thread_info(task)->status & TS_COMPAT) | 95 | if (task_thread_info(task)->status & TS_COMPAT) |
| 96 | switch (i + n) { | 96 | switch (i) { |
| 97 | case 6: | 97 | case 0: |
| 98 | if (!n--) break; | 98 | if (!n--) break; |
| 99 | *args++ = regs->bp; | 99 | *args++ = regs->bx; |
| 100 | case 5: | 100 | case 1: |
| 101 | if (!n--) break; | 101 | if (!n--) break; |
| 102 | *args++ = regs->di; | 102 | *args++ = regs->cx; |
| 103 | case 4: | 103 | case 2: |
| 104 | if (!n--) break; | 104 | if (!n--) break; |
| 105 | *args++ = regs->si; | 105 | *args++ = regs->dx; |
| 106 | case 3: | 106 | case 3: |
| 107 | if (!n--) break; | 107 | if (!n--) break; |
| 108 | *args++ = regs->dx; | 108 | *args++ = regs->si; |
| 109 | case 2: | 109 | case 4: |
| 110 | if (!n--) break; | 110 | if (!n--) break; |
| 111 | *args++ = regs->cx; | 111 | *args++ = regs->di; |
| 112 | case 1: | 112 | case 5: |
| 113 | if (!n--) break; | 113 | if (!n--) break; |
| 114 | *args++ = regs->bx; | 114 | *args++ = regs->bp; |
| 115 | case 0: | 115 | case 6: |
| 116 | if (!n--) break; | 116 | if (!n--) break; |
| 117 | default: | 117 | default: |
| 118 | BUG(); | 118 | BUG(); |
| @@ -120,26 +120,26 @@ static inline void syscall_get_arguments(struct task_struct *task, | |||
| 120 | } | 120 | } |
| 121 | else | 121 | else |
| 122 | # endif | 122 | # endif |
| 123 | switch (i + n) { | 123 | switch (i) { |
| 124 | case 6: | 124 | case 0: |
| 125 | if (!n--) break; | 125 | if (!n--) break; |
| 126 | *args++ = regs->r9; | 126 | *args++ = regs->di; |
| 127 | case 5: | 127 | case 1: |
| 128 | if (!n--) break; | 128 | if (!n--) break; |
| 129 | *args++ = regs->r8; | 129 | *args++ = regs->si; |
| 130 | case 4: | 130 | case 2: |
| 131 | if (!n--) break; | 131 | if (!n--) break; |
| 132 | *args++ = regs->r10; | 132 | *args++ = regs->dx; |
| 133 | case 3: | 133 | case 3: |
| 134 | if (!n--) break; | 134 | if (!n--) break; |
| 135 | *args++ = regs->dx; | 135 | *args++ = regs->r10; |
| 136 | case 2: | 136 | case 4: |
| 137 | if (!n--) break; | 137 | if (!n--) break; |
| 138 | *args++ = regs->si; | 138 | *args++ = regs->r8; |
| 139 | case 1: | 139 | case 5: |
| 140 | if (!n--) break; | 140 | if (!n--) break; |
| 141 | *args++ = regs->di; | 141 | *args++ = regs->r9; |
| 142 | case 0: | 142 | case 6: |
| 143 | if (!n--) break; | 143 | if (!n--) break; |
| 144 | default: | 144 | default: |
| 145 | BUG(); | 145 | BUG(); |
| @@ -154,55 +154,57 @@ static inline void syscall_set_arguments(struct task_struct *task, | |||
| 154 | { | 154 | { |
| 155 | # ifdef CONFIG_IA32_EMULATION | 155 | # ifdef CONFIG_IA32_EMULATION |
| 156 | if (task_thread_info(task)->status & TS_COMPAT) | 156 | if (task_thread_info(task)->status & TS_COMPAT) |
| 157 | switch (i + n) { | 157 | switch (i) { |
| 158 | case 6: | 158 | case 0: |
| 159 | if (!n--) break; | 159 | if (!n--) break; |
| 160 | regs->bp = *args++; | 160 | regs->bx = *args++; |
| 161 | case 5: | 161 | case 1: |
| 162 | if (!n--) break; | 162 | if (!n--) break; |
| 163 | regs->di = *args++; | 163 | regs->cx = *args++; |
| 164 | case 4: | 164 | case 2: |
| 165 | if (!n--) break; | 165 | if (!n--) break; |
| 166 | regs->si = *args++; | 166 | regs->dx = *args++; |
| 167 | case 3: | 167 | case 3: |
| 168 | if (!n--) break; | 168 | if (!n--) break; |
| 169 | regs->dx = *args++; | 169 | regs->si = *args++; |
| 170 | case 2: | 170 | case 4: |
| 171 | if (!n--) break; | 171 | if (!n--) break; |
| 172 | regs->cx = *args++; | 172 | regs->di = *args++; |
| 173 | case 1: | 173 | case 5: |
| 174 | if (!n--) break; | 174 | if (!n--) break; |
| 175 | regs->bx = *args++; | 175 | regs->bp = *args++; |
| 176 | case 0: | 176 | case 6: |
| 177 | if (!n--) break; | 177 | if (!n--) break; |
| 178 | default: | 178 | default: |
| 179 | BUG(); | 179 | BUG(); |
| 180 | break; | ||
| 180 | } | 181 | } |
| 181 | else | 182 | else |
| 182 | # endif | 183 | # endif |
| 183 | switch (i + n) { | 184 | switch (i) { |
| 184 | case 6: | 185 | case 0: |
| 185 | if (!n--) break; | 186 | if (!n--) break; |
| 186 | regs->r9 = *args++; | 187 | regs->di = *args++; |
| 187 | case 5: | 188 | case 1: |
| 188 | if (!n--) break; | 189 | if (!n--) break; |
| 189 | regs->r8 = *args++; | 190 | regs->si = *args++; |
| 190 | case 4: | 191 | case 2: |
| 191 | if (!n--) break; | 192 | if (!n--) break; |
| 192 | regs->r10 = *args++; | 193 | regs->dx = *args++; |
| 193 | case 3: | 194 | case 3: |
| 194 | if (!n--) break; | 195 | if (!n--) break; |
| 195 | regs->dx = *args++; | 196 | regs->r10 = *args++; |
| 196 | case 2: | 197 | case 4: |
| 197 | if (!n--) break; | 198 | if (!n--) break; |
| 198 | regs->si = *args++; | 199 | regs->r8 = *args++; |
| 199 | case 1: | 200 | case 5: |
| 200 | if (!n--) break; | 201 | if (!n--) break; |
| 201 | regs->di = *args++; | 202 | regs->r9 = *args++; |
| 202 | case 0: | 203 | case 6: |
| 203 | if (!n--) break; | 204 | if (!n--) break; |
| 204 | default: | 205 | default: |
| 205 | BUG(); | 206 | BUG(); |
| 207 | break; | ||
| 206 | } | 208 | } |
| 207 | } | 209 | } |
| 208 | 210 | ||
diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index 53b01a1ae10c..8c1f76abae9e 100644 --- a/arch/x86/kernel/acpi/boot.c +++ b/arch/x86/kernel/acpi/boot.c | |||
| @@ -1137,7 +1137,7 @@ int mp_register_gsi(u32 gsi, int triggering, int polarity) | |||
| 1137 | return gsi; | 1137 | return gsi; |
| 1138 | } | 1138 | } |
| 1139 | if (test_bit(ioapic_pin, mp_ioapic_routing[ioapic].pin_programmed)) { | 1139 | if (test_bit(ioapic_pin, mp_ioapic_routing[ioapic].pin_programmed)) { |
| 1140 | pr_debug(KERN_DEBUG "Pin %d-%d already programmed\n", | 1140 | pr_debug("Pin %d-%d already programmed\n", |
| 1141 | mp_ioapic_routing[ioapic].apic_id, ioapic_pin); | 1141 | mp_ioapic_routing[ioapic].apic_id, ioapic_pin); |
| 1142 | #ifdef CONFIG_X86_32 | 1142 | #ifdef CONFIG_X86_32 |
| 1143 | return (gsi < IRQ_COMPRESSION_START ? gsi : gsi_to_irq[gsi]); | 1143 | return (gsi < IRQ_COMPRESSION_START ? gsi : gsi_to_irq[gsi]); |
| @@ -1599,6 +1599,11 @@ static struct dmi_system_id __initdata acpi_dmi_table[] = { | |||
| 1599 | DMI_MATCH(DMI_PRODUCT_NAME, "TravelMate 360"), | 1599 | DMI_MATCH(DMI_PRODUCT_NAME, "TravelMate 360"), |
| 1600 | }, | 1600 | }, |
| 1601 | }, | 1601 | }, |
| 1602 | {} | ||
| 1603 | }; | ||
| 1604 | |||
| 1605 | /* second table for DMI checks that should run after early-quirks */ | ||
| 1606 | static struct dmi_system_id __initdata acpi_dmi_table_late[] = { | ||
| 1602 | /* | 1607 | /* |
| 1603 | * HP laptops which use a DSDT reporting as HP/SB400/10000, | 1608 | * HP laptops which use a DSDT reporting as HP/SB400/10000, |
| 1604 | * which includes some code which overrides all temperature | 1609 | * which includes some code which overrides all temperature |
| @@ -1727,6 +1732,9 @@ int __init early_acpi_boot_init(void) | |||
| 1727 | 1732 | ||
| 1728 | int __init acpi_boot_init(void) | 1733 | int __init acpi_boot_init(void) |
| 1729 | { | 1734 | { |
| 1735 | /* those are executed after early-quirks are executed */ | ||
| 1736 | dmi_check_system(acpi_dmi_table_late); | ||
| 1737 | |||
| 1730 | /* | 1738 | /* |
| 1731 | * If acpi_disabled, bail out | 1739 | * If acpi_disabled, bail out |
| 1732 | * One exception: acpi=ht continues far enough to enumerate LAPICs | 1740 | * One exception: acpi=ht continues far enough to enumerate LAPICs |
diff --git a/arch/x86/kernel/cpu/proc.c b/arch/x86/kernel/cpu/proc.c index a26c480b9491..01b1244ef1c0 100644 --- a/arch/x86/kernel/cpu/proc.c +++ b/arch/x86/kernel/cpu/proc.c | |||
| @@ -160,14 +160,16 @@ static void *c_start(struct seq_file *m, loff_t *pos) | |||
| 160 | { | 160 | { |
| 161 | if (*pos == 0) /* just in case, cpu 0 is not the first */ | 161 | if (*pos == 0) /* just in case, cpu 0 is not the first */ |
| 162 | *pos = first_cpu(cpu_online_map); | 162 | *pos = first_cpu(cpu_online_map); |
| 163 | if ((*pos) < nr_cpu_ids && cpu_online(*pos)) | 163 | else |
| 164 | *pos = next_cpu_nr(*pos - 1, cpu_online_map); | ||
| 165 | if ((*pos) < nr_cpu_ids) | ||
| 164 | return &cpu_data(*pos); | 166 | return &cpu_data(*pos); |
| 165 | return NULL; | 167 | return NULL; |
| 166 | } | 168 | } |
| 167 | 169 | ||
| 168 | static void *c_next(struct seq_file *m, void *v, loff_t *pos) | 170 | static void *c_next(struct seq_file *m, void *v, loff_t *pos) |
| 169 | { | 171 | { |
| 170 | *pos = next_cpu(*pos, cpu_online_map); | 172 | (*pos)++; |
| 171 | return c_start(m, pos); | 173 | return c_start(m, pos); |
| 172 | } | 174 | } |
| 173 | 175 | ||
diff --git a/arch/x86/kernel/dumpstack_32.c b/arch/x86/kernel/dumpstack_32.c index 1a78180f08d3..b3614752197b 100644 --- a/arch/x86/kernel/dumpstack_32.c +++ b/arch/x86/kernel/dumpstack_32.c | |||
| @@ -405,7 +405,6 @@ die_nmi(char *str, struct pt_regs *regs, int do_panic) | |||
| 405 | panic("Non maskable interrupt"); | 405 | panic("Non maskable interrupt"); |
| 406 | console_silent(); | 406 | console_silent(); |
| 407 | spin_unlock(&nmi_print_lock); | 407 | spin_unlock(&nmi_print_lock); |
| 408 | bust_spinlocks(0); | ||
| 409 | 408 | ||
| 410 | /* | 409 | /* |
| 411 | * If we are in kernel we are probably nested up pretty bad | 410 | * If we are in kernel we are probably nested up pretty bad |
| @@ -416,6 +415,7 @@ die_nmi(char *str, struct pt_regs *regs, int do_panic) | |||
| 416 | crash_kexec(regs); | 415 | crash_kexec(regs); |
| 417 | } | 416 | } |
| 418 | 417 | ||
| 418 | bust_spinlocks(0); | ||
| 419 | do_exit(SIGSEGV); | 419 | do_exit(SIGSEGV); |
| 420 | } | 420 | } |
| 421 | 421 | ||
diff --git a/arch/x86/kernel/entry_32.S b/arch/x86/kernel/entry_32.S index c356423a6026..dd65143941a8 100644 --- a/arch/x86/kernel/entry_32.S +++ b/arch/x86/kernel/entry_32.S | |||
| @@ -1024,7 +1024,7 @@ ENTRY(machine_check) | |||
| 1024 | RING0_INT_FRAME | 1024 | RING0_INT_FRAME |
| 1025 | pushl $0 | 1025 | pushl $0 |
| 1026 | CFI_ADJUST_CFA_OFFSET 4 | 1026 | CFI_ADJUST_CFA_OFFSET 4 |
| 1027 | pushl $do_machine_check | 1027 | pushl machine_check_vector |
| 1028 | CFI_ADJUST_CFA_OFFSET 4 | 1028 | CFI_ADJUST_CFA_OFFSET 4 |
| 1029 | jmp error_code | 1029 | jmp error_code |
| 1030 | CFI_ENDPROC | 1030 | CFI_ENDPROC |
diff --git a/arch/x86/kernel/genapic_flat_64.c b/arch/x86/kernel/genapic_flat_64.c index 2ec2de8d8c46..c0262791bda4 100644 --- a/arch/x86/kernel/genapic_flat_64.c +++ b/arch/x86/kernel/genapic_flat_64.c | |||
| @@ -25,7 +25,7 @@ | |||
| 25 | #include <acpi/acpi_bus.h> | 25 | #include <acpi/acpi_bus.h> |
| 26 | #endif | 26 | #endif |
| 27 | 27 | ||
| 28 | static int __init flat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 28 | static int flat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
| 29 | { | 29 | { |
| 30 | return 1; | 30 | return 1; |
| 31 | } | 31 | } |
| @@ -170,7 +170,7 @@ struct genapic apic_flat = { | |||
| 170 | * We cannot use logical delivery in this case because the mask | 170 | * We cannot use logical delivery in this case because the mask |
| 171 | * overflows, so use physical mode. | 171 | * overflows, so use physical mode. |
| 172 | */ | 172 | */ |
| 173 | static int __init physflat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 173 | static int physflat_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
| 174 | { | 174 | { |
| 175 | #ifdef CONFIG_ACPI | 175 | #ifdef CONFIG_ACPI |
| 176 | /* | 176 | /* |
diff --git a/arch/x86/kernel/genx2apic_cluster.c b/arch/x86/kernel/genx2apic_cluster.c index e4bf2cc0d743..f6a2c8eb48a6 100644 --- a/arch/x86/kernel/genx2apic_cluster.c +++ b/arch/x86/kernel/genx2apic_cluster.c | |||
| @@ -12,7 +12,7 @@ | |||
| 12 | 12 | ||
| 13 | DEFINE_PER_CPU(u32, x86_cpu_to_logical_apicid); | 13 | DEFINE_PER_CPU(u32, x86_cpu_to_logical_apicid); |
| 14 | 14 | ||
| 15 | static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 15 | static int x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
| 16 | { | 16 | { |
| 17 | if (cpu_has_x2apic) | 17 | if (cpu_has_x2apic) |
| 18 | return 1; | 18 | return 1; |
diff --git a/arch/x86/kernel/genx2apic_phys.c b/arch/x86/kernel/genx2apic_phys.c index 8f1343df2627..d042211768b7 100644 --- a/arch/x86/kernel/genx2apic_phys.c +++ b/arch/x86/kernel/genx2apic_phys.c | |||
| @@ -19,7 +19,7 @@ static int set_x2apic_phys_mode(char *arg) | |||
| 19 | } | 19 | } |
| 20 | early_param("x2apic_phys", set_x2apic_phys_mode); | 20 | early_param("x2apic_phys", set_x2apic_phys_mode); |
| 21 | 21 | ||
| 22 | static int __init x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 22 | static int x2apic_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
| 23 | { | 23 | { |
| 24 | if (cpu_has_x2apic && x2apic_phys) | 24 | if (cpu_has_x2apic && x2apic_phys) |
| 25 | return 1; | 25 | return 1; |
diff --git a/arch/x86/kernel/genx2apic_uv_x.c b/arch/x86/kernel/genx2apic_uv_x.c index bfd532843df6..680a06557c5e 100644 --- a/arch/x86/kernel/genx2apic_uv_x.c +++ b/arch/x86/kernel/genx2apic_uv_x.c | |||
| @@ -30,7 +30,7 @@ DEFINE_PER_CPU(int, x2apic_extra_bits); | |||
| 30 | 30 | ||
| 31 | static enum uv_system_type uv_system_type; | 31 | static enum uv_system_type uv_system_type; |
| 32 | 32 | ||
| 33 | static int __init uv_acpi_madt_oem_check(char *oem_id, char *oem_table_id) | 33 | static int uv_acpi_madt_oem_check(char *oem_id, char *oem_table_id) |
| 34 | { | 34 | { |
| 35 | if (!strcmp(oem_id, "SGI")) { | 35 | if (!strcmp(oem_id, "SGI")) { |
| 36 | if (!strcmp(oem_table_id, "UVL")) | 36 | if (!strcmp(oem_table_id, "UVL")) |
diff --git a/arch/x86/kernel/setup_percpu.c b/arch/x86/kernel/setup_percpu.c index 410c88f0bfeb..ae0c0d3bb770 100644 --- a/arch/x86/kernel/setup_percpu.c +++ b/arch/x86/kernel/setup_percpu.c | |||
| @@ -218,7 +218,7 @@ static void __init setup_node_to_cpumask_map(void) | |||
| 218 | /* allocate the map */ | 218 | /* allocate the map */ |
| 219 | map = alloc_bootmem_low(nr_node_ids * sizeof(cpumask_t)); | 219 | map = alloc_bootmem_low(nr_node_ids * sizeof(cpumask_t)); |
| 220 | 220 | ||
| 221 | pr_debug(KERN_DEBUG "Node to cpumask map at %p for %d nodes\n", | 221 | pr_debug("Node to cpumask map at %p for %d nodes\n", |
| 222 | map, nr_node_ids); | 222 | map, nr_node_ids); |
| 223 | 223 | ||
| 224 | /* node_to_cpumask() will now work */ | 224 | /* node_to_cpumask() will now work */ |
diff --git a/arch/x86/kernel/smpboot.c b/arch/x86/kernel/smpboot.c index 7ece815ea637..7b1093397319 100644 --- a/arch/x86/kernel/smpboot.c +++ b/arch/x86/kernel/smpboot.c | |||
| @@ -893,9 +893,11 @@ do_rest: | |||
| 893 | smpboot_setup_warm_reset_vector(start_ip); | 893 | smpboot_setup_warm_reset_vector(start_ip); |
| 894 | /* | 894 | /* |
| 895 | * Be paranoid about clearing APIC errors. | 895 | * Be paranoid about clearing APIC errors. |
| 896 | */ | 896 | */ |
| 897 | apic_write(APIC_ESR, 0); | 897 | if (APIC_INTEGRATED(apic_version[boot_cpu_physical_apicid])) { |
| 898 | apic_read(APIC_ESR); | 898 | apic_write(APIC_ESR, 0); |
| 899 | apic_read(APIC_ESR); | ||
| 900 | } | ||
| 899 | } | 901 | } |
| 900 | 902 | ||
| 901 | /* | 903 | /* |
diff --git a/arch/x86/kernel/tlb_uv.c b/arch/x86/kernel/tlb_uv.c index 8b8c0d6640fa..04431f34fd16 100644 --- a/arch/x86/kernel/tlb_uv.c +++ b/arch/x86/kernel/tlb_uv.c | |||
| @@ -6,7 +6,7 @@ | |||
| 6 | * This code is released under the GNU General Public License version 2 or | 6 | * This code is released under the GNU General Public License version 2 or |
| 7 | * later. | 7 | * later. |
| 8 | */ | 8 | */ |
| 9 | #include <linux/mc146818rtc.h> | 9 | #include <linux/seq_file.h> |
| 10 | #include <linux/proc_fs.h> | 10 | #include <linux/proc_fs.h> |
| 11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
| 12 | 12 | ||
diff --git a/arch/x86/kernel/traps.c b/arch/x86/kernel/traps.c index e062974cce34..04d242ab0161 100644 --- a/arch/x86/kernel/traps.c +++ b/arch/x86/kernel/traps.c | |||
| @@ -931,14 +931,6 @@ do_device_not_available(struct pt_regs *regs, long error) | |||
| 931 | } | 931 | } |
| 932 | 932 | ||
| 933 | #ifdef CONFIG_X86_32 | 933 | #ifdef CONFIG_X86_32 |
| 934 | #ifdef CONFIG_X86_MCE | ||
| 935 | dotraplinkage void __kprobes do_machine_check(struct pt_regs *regs, long error) | ||
| 936 | { | ||
| 937 | conditional_sti(regs); | ||
| 938 | machine_check_vector(regs, error); | ||
| 939 | } | ||
| 940 | #endif | ||
| 941 | |||
| 942 | dotraplinkage void do_iret_error(struct pt_regs *regs, long error_code) | 934 | dotraplinkage void do_iret_error(struct pt_regs *regs, long error_code) |
| 943 | { | 935 | { |
| 944 | siginfo_t info; | 936 | siginfo_t info; |
diff --git a/arch/x86/kernel/xsave.c b/arch/x86/kernel/xsave.c index 9abac8a9d823..b13acb75e822 100644 --- a/arch/x86/kernel/xsave.c +++ b/arch/x86/kernel/xsave.c | |||
| @@ -248,7 +248,7 @@ clear: | |||
| 248 | * This will be saved when ever the FP and extended state context is | 248 | * This will be saved when ever the FP and extended state context is |
| 249 | * saved on the user stack during the signal handler delivery to the user. | 249 | * saved on the user stack during the signal handler delivery to the user. |
| 250 | */ | 250 | */ |
| 251 | void prepare_fx_sw_frame(void) | 251 | static void prepare_fx_sw_frame(void) |
| 252 | { | 252 | { |
| 253 | int size_extended = (xstate_size - sizeof(struct i387_fxsave_struct)) + | 253 | int size_extended = (xstate_size - sizeof(struct i387_fxsave_struct)) + |
| 254 | FP_XSTATE_MAGIC2_SIZE; | 254 | FP_XSTATE_MAGIC2_SIZE; |
diff --git a/arch/x86/kvm/i8254.c b/arch/x86/kvm/i8254.c index 634132a9a512..11c6725fb798 100644 --- a/arch/x86/kvm/i8254.c +++ b/arch/x86/kvm/i8254.c | |||
| @@ -204,10 +204,10 @@ static int __pit_timer_fn(struct kvm_kpit_state *ps) | |||
| 204 | if (vcpu0 && waitqueue_active(&vcpu0->wq)) | 204 | if (vcpu0 && waitqueue_active(&vcpu0->wq)) |
| 205 | wake_up_interruptible(&vcpu0->wq); | 205 | wake_up_interruptible(&vcpu0->wq); |
| 206 | 206 | ||
| 207 | pt->timer.expires = ktime_add_ns(pt->timer.expires, pt->period); | 207 | hrtimer_add_expires_ns(&pt->timer, pt->period); |
| 208 | pt->scheduled = ktime_to_ns(pt->timer.expires); | 208 | pt->scheduled = hrtimer_get_expires_ns(&pt->timer); |
| 209 | if (pt->period) | 209 | if (pt->period) |
| 210 | ps->channels[0].count_load_time = pt->timer.expires; | 210 | ps->channels[0].count_load_time = hrtimer_get_expires(&pt->timer); |
| 211 | 211 | ||
| 212 | return (pt->period == 0 ? 0 : 1); | 212 | return (pt->period == 0 ? 0 : 1); |
| 213 | } | 213 | } |
| @@ -257,7 +257,7 @@ void __kvm_migrate_pit_timer(struct kvm_vcpu *vcpu) | |||
| 257 | 257 | ||
| 258 | timer = &pit->pit_state.pit_timer.timer; | 258 | timer = &pit->pit_state.pit_timer.timer; |
| 259 | if (hrtimer_cancel(timer)) | 259 | if (hrtimer_cancel(timer)) |
| 260 | hrtimer_start(timer, timer->expires, HRTIMER_MODE_ABS); | 260 | hrtimer_start_expires(timer, HRTIMER_MODE_ABS); |
| 261 | } | 261 | } |
| 262 | 262 | ||
| 263 | static void destroy_pit_timer(struct kvm_kpit_timer *pt) | 263 | static void destroy_pit_timer(struct kvm_kpit_timer *pt) |
diff --git a/arch/x86/kvm/lapic.c b/arch/x86/kvm/lapic.c index 6571926bfd33..0fc3cab48943 100644 --- a/arch/x86/kvm/lapic.c +++ b/arch/x86/kvm/lapic.c | |||
| @@ -946,9 +946,7 @@ static int __apic_timer_fn(struct kvm_lapic *apic) | |||
| 946 | 946 | ||
| 947 | if (apic_lvtt_period(apic)) { | 947 | if (apic_lvtt_period(apic)) { |
| 948 | result = 1; | 948 | result = 1; |
| 949 | apic->timer.dev.expires = ktime_add_ns( | 949 | hrtimer_add_expires_ns(&apic->timer.dev, apic->timer.period); |
| 950 | apic->timer.dev.expires, | ||
| 951 | apic->timer.period); | ||
| 952 | } | 950 | } |
| 953 | return result; | 951 | return result; |
| 954 | } | 952 | } |
| @@ -1117,7 +1115,7 @@ void __kvm_migrate_apic_timer(struct kvm_vcpu *vcpu) | |||
| 1117 | 1115 | ||
| 1118 | timer = &apic->timer.dev; | 1116 | timer = &apic->timer.dev; |
| 1119 | if (hrtimer_cancel(timer)) | 1117 | if (hrtimer_cancel(timer)) |
| 1120 | hrtimer_start(timer, timer->expires, HRTIMER_MODE_ABS); | 1118 | hrtimer_start_expires(timer, HRTIMER_MODE_ABS); |
| 1121 | } | 1119 | } |
| 1122 | 1120 | ||
| 1123 | void kvm_lapic_sync_from_vapic(struct kvm_vcpu *vcpu) | 1121 | void kvm_lapic_sync_from_vapic(struct kvm_vcpu *vcpu) |
diff --git a/arch/x86/mm/memtest.c b/arch/x86/mm/memtest.c index 672e17f8262a..9cab18b0b857 100644 --- a/arch/x86/mm/memtest.c +++ b/arch/x86/mm/memtest.c | |||
| @@ -61,9 +61,9 @@ static void __init memtest(unsigned long start_phys, unsigned long size, | |||
| 61 | last_bad += incr; | 61 | last_bad += incr; |
| 62 | } else { | 62 | } else { |
| 63 | if (start_bad) { | 63 | if (start_bad) { |
| 64 | printk(KERN_CONT "\n %010lx bad mem addr %010lx - %010lx reserved", | 64 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", |
| 65 | val, start_bad, last_bad + incr); | 65 | val, start_bad, last_bad + incr); |
| 66 | reserve_early(start_bad, last_bad - start_bad, "BAD RAM"); | 66 | reserve_early(start_bad, last_bad + incr, "BAD RAM"); |
| 67 | } | 67 | } |
| 68 | start_bad = last_bad = start_phys_aligned; | 68 | start_bad = last_bad = start_phys_aligned; |
| 69 | } | 69 | } |
| @@ -72,9 +72,8 @@ static void __init memtest(unsigned long start_phys, unsigned long size, | |||
| 72 | if (start_bad) { | 72 | if (start_bad) { |
| 73 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", | 73 | printk(KERN_CONT "\n %016lx bad mem addr %010lx - %010lx reserved", |
| 74 | val, start_bad, last_bad + incr); | 74 | val, start_bad, last_bad + incr); |
| 75 | reserve_early(start_bad, last_bad - start_bad, "BAD RAM"); | 75 | reserve_early(start_bad, last_bad + incr, "BAD RAM"); |
| 76 | } | 76 | } |
| 77 | |||
| 78 | } | 77 | } |
| 79 | 78 | ||
| 80 | /* default is disabled */ | 79 | /* default is disabled */ |
diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c index 407d8784f669..f1dc1b75d166 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c | |||
| @@ -65,23 +65,22 @@ static void split_page_count(int level) | |||
| 65 | direct_pages_count[level - 1] += PTRS_PER_PTE; | 65 | direct_pages_count[level - 1] += PTRS_PER_PTE; |
| 66 | } | 66 | } |
| 67 | 67 | ||
| 68 | int arch_report_meminfo(char *page) | 68 | void arch_report_meminfo(struct seq_file *m) |
| 69 | { | 69 | { |
| 70 | int n = sprintf(page, "DirectMap4k: %8lu kB\n", | 70 | seq_printf(m, "DirectMap4k: %8lu kB\n", |
| 71 | direct_pages_count[PG_LEVEL_4K] << 2); | 71 | direct_pages_count[PG_LEVEL_4K] << 2); |
| 72 | #if defined(CONFIG_X86_64) || defined(CONFIG_X86_PAE) | 72 | #if defined(CONFIG_X86_64) || defined(CONFIG_X86_PAE) |
| 73 | n += sprintf(page + n, "DirectMap2M: %8lu kB\n", | 73 | seq_printf(m, "DirectMap2M: %8lu kB\n", |
| 74 | direct_pages_count[PG_LEVEL_2M] << 11); | 74 | direct_pages_count[PG_LEVEL_2M] << 11); |
| 75 | #else | 75 | #else |
| 76 | n += sprintf(page + n, "DirectMap4M: %8lu kB\n", | 76 | seq_printf(m, "DirectMap4M: %8lu kB\n", |
| 77 | direct_pages_count[PG_LEVEL_2M] << 12); | 77 | direct_pages_count[PG_LEVEL_2M] << 12); |
| 78 | #endif | 78 | #endif |
| 79 | #ifdef CONFIG_X86_64 | 79 | #ifdef CONFIG_X86_64 |
| 80 | if (direct_gbpages) | 80 | if (direct_gbpages) |
| 81 | n += sprintf(page + n, "DirectMap1G: %8lu kB\n", | 81 | seq_printf(m, "DirectMap1G: %8lu kB\n", |
| 82 | direct_pages_count[PG_LEVEL_1G] << 20); | 82 | direct_pages_count[PG_LEVEL_1G] << 20); |
| 83 | #endif | 83 | #endif |
| 84 | return n; | ||
| 85 | } | 84 | } |
| 86 | #else | 85 | #else |
| 87 | static inline void split_page_count(int level) { } | 86 | static inline void split_page_count(int level) { } |
diff --git a/block/genhd.c b/block/genhd.c index 646e1d2507c7..4e5e7493f676 100644 --- a/block/genhd.c +++ b/block/genhd.c | |||
| @@ -10,6 +10,7 @@ | |||
| 10 | #include <linux/blkdev.h> | 10 | #include <linux/blkdev.h> |
| 11 | #include <linux/init.h> | 11 | #include <linux/init.h> |
| 12 | #include <linux/spinlock.h> | 12 | #include <linux/spinlock.h> |
| 13 | #include <linux/proc_fs.h> | ||
| 13 | #include <linux/seq_file.h> | 14 | #include <linux/seq_file.h> |
| 14 | #include <linux/slab.h> | 15 | #include <linux/slab.h> |
| 15 | #include <linux/kmod.h> | 16 | #include <linux/kmod.h> |
| @@ -727,12 +728,24 @@ static int show_partition(struct seq_file *seqf, void *v) | |||
| 727 | return 0; | 728 | return 0; |
| 728 | } | 729 | } |
| 729 | 730 | ||
| 730 | const struct seq_operations partitions_op = { | 731 | static const struct seq_operations partitions_op = { |
| 731 | .start = show_partition_start, | 732 | .start = show_partition_start, |
| 732 | .next = disk_seqf_next, | 733 | .next = disk_seqf_next, |
| 733 | .stop = disk_seqf_stop, | 734 | .stop = disk_seqf_stop, |
| 734 | .show = show_partition | 735 | .show = show_partition |
| 735 | }; | 736 | }; |
| 737 | |||
| 738 | static int partitions_open(struct inode *inode, struct file *file) | ||
| 739 | { | ||
| 740 | return seq_open(file, &partitions_op); | ||
| 741 | } | ||
| 742 | |||
| 743 | static const struct file_operations proc_partitions_operations = { | ||
| 744 | .open = partitions_open, | ||
| 745 | .read = seq_read, | ||
| 746 | .llseek = seq_lseek, | ||
| 747 | .release = seq_release, | ||
| 748 | }; | ||
| 736 | #endif | 749 | #endif |
| 737 | 750 | ||
| 738 | 751 | ||
| @@ -992,12 +1005,32 @@ static int diskstats_show(struct seq_file *seqf, void *v) | |||
| 992 | return 0; | 1005 | return 0; |
| 993 | } | 1006 | } |
| 994 | 1007 | ||
| 995 | const struct seq_operations diskstats_op = { | 1008 | static const struct seq_operations diskstats_op = { |
| 996 | .start = disk_seqf_start, | 1009 | .start = disk_seqf_start, |
| 997 | .next = disk_seqf_next, | 1010 | .next = disk_seqf_next, |
| 998 | .stop = disk_seqf_stop, | 1011 | .stop = disk_seqf_stop, |
| 999 | .show = diskstats_show | 1012 | .show = diskstats_show |
| 1000 | }; | 1013 | }; |
| 1014 | |||
| 1015 | static int diskstats_open(struct inode *inode, struct file *file) | ||
| 1016 | { | ||
| 1017 | return seq_open(file, &diskstats_op); | ||
| 1018 | } | ||
| 1019 | |||
| 1020 | static const struct file_operations proc_diskstats_operations = { | ||
| 1021 | .open = diskstats_open, | ||
| 1022 | .read = seq_read, | ||
| 1023 | .llseek = seq_lseek, | ||
| 1024 | .release = seq_release, | ||
| 1025 | }; | ||
| 1026 | |||
| 1027 | static int __init proc_genhd_init(void) | ||
| 1028 | { | ||
| 1029 | proc_create("diskstats", 0, NULL, &proc_diskstats_operations); | ||
| 1030 | proc_create("partitions", 0, NULL, &proc_partitions_operations); | ||
| 1031 | return 0; | ||
| 1032 | } | ||
| 1033 | module_init(proc_genhd_init); | ||
| 1001 | #endif /* CONFIG_PROC_FS */ | 1034 | #endif /* CONFIG_PROC_FS */ |
| 1002 | 1035 | ||
| 1003 | static void media_change_notify_thread(struct work_struct *work) | 1036 | static void media_change_notify_thread(struct work_struct *work) |
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index bbb3cae57492..8cb0b360bfd8 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c | |||
| @@ -1713,8 +1713,6 @@ unsigned ata_exec_internal_sg(struct ata_device *dev, | |||
| 1713 | else | 1713 | else |
| 1714 | tag = 0; | 1714 | tag = 0; |
| 1715 | 1715 | ||
| 1716 | if (test_and_set_bit(tag, &ap->qc_allocated)) | ||
| 1717 | BUG(); | ||
| 1718 | qc = __ata_qc_from_tag(ap, tag); | 1716 | qc = __ata_qc_from_tag(ap, tag); |
| 1719 | 1717 | ||
| 1720 | qc->tag = tag; | 1718 | qc->tag = tag; |
| @@ -4553,37 +4551,6 @@ void swap_buf_le16(u16 *buf, unsigned int buf_words) | |||
| 4553 | } | 4551 | } |
| 4554 | 4552 | ||
| 4555 | /** | 4553 | /** |
| 4556 | * ata_qc_new - Request an available ATA command, for queueing | ||
| 4557 | * @ap: Port associated with device @dev | ||
| 4558 | * @dev: Device from whom we request an available command structure | ||
| 4559 | * | ||
| 4560 | * LOCKING: | ||
| 4561 | * None. | ||
| 4562 | */ | ||
| 4563 | |||
| 4564 | static struct ata_queued_cmd *ata_qc_new(struct ata_port *ap) | ||
| 4565 | { | ||
| 4566 | struct ata_queued_cmd *qc = NULL; | ||
| 4567 | unsigned int i; | ||
| 4568 | |||
| 4569 | /* no command while frozen */ | ||
| 4570 | if (unlikely(ap->pflags & ATA_PFLAG_FROZEN)) | ||
| 4571 | return NULL; | ||
| 4572 | |||
| 4573 | /* the last tag is reserved for internal command. */ | ||
| 4574 | for (i = 0; i < ATA_MAX_QUEUE - 1; i++) | ||
| 4575 | if (!test_and_set_bit(i, &ap->qc_allocated)) { | ||
| 4576 | qc = __ata_qc_from_tag(ap, i); | ||
| 4577 | break; | ||
| 4578 | } | ||
| 4579 | |||
| 4580 | if (qc) | ||
| 4581 | qc->tag = i; | ||
| 4582 | |||
| 4583 | return qc; | ||
| 4584 | } | ||
| 4585 | |||
| 4586 | /** | ||
| 4587 | * ata_qc_new_init - Request an available ATA command, and initialize it | 4554 | * ata_qc_new_init - Request an available ATA command, and initialize it |
| 4588 | * @dev: Device from whom we request an available command structure | 4555 | * @dev: Device from whom we request an available command structure |
| 4589 | * | 4556 | * |
| @@ -4591,16 +4558,20 @@ static struct ata_queued_cmd *ata_qc_new(struct ata_port *ap) | |||
| 4591 | * None. | 4558 | * None. |
| 4592 | */ | 4559 | */ |
| 4593 | 4560 | ||
| 4594 | struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev) | 4561 | struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev, int tag) |
| 4595 | { | 4562 | { |
| 4596 | struct ata_port *ap = dev->link->ap; | 4563 | struct ata_port *ap = dev->link->ap; |
| 4597 | struct ata_queued_cmd *qc; | 4564 | struct ata_queued_cmd *qc; |
| 4598 | 4565 | ||
| 4599 | qc = ata_qc_new(ap); | 4566 | if (unlikely(ap->pflags & ATA_PFLAG_FROZEN)) |
| 4567 | return NULL; | ||
| 4568 | |||
| 4569 | qc = __ata_qc_from_tag(ap, tag); | ||
| 4600 | if (qc) { | 4570 | if (qc) { |
| 4601 | qc->scsicmd = NULL; | 4571 | qc->scsicmd = NULL; |
| 4602 | qc->ap = ap; | 4572 | qc->ap = ap; |
| 4603 | qc->dev = dev; | 4573 | qc->dev = dev; |
| 4574 | qc->tag = tag; | ||
| 4604 | 4575 | ||
| 4605 | ata_qc_reinit(qc); | 4576 | ata_qc_reinit(qc); |
| 4606 | } | 4577 | } |
| @@ -4608,31 +4579,6 @@ struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev) | |||
| 4608 | return qc; | 4579 | return qc; |
| 4609 | } | 4580 | } |
| 4610 | 4581 | ||
| 4611 | /** | ||
| 4612 | * ata_qc_free - free unused ata_queued_cmd | ||
| 4613 | * @qc: Command to complete | ||
| 4614 | * | ||
| 4615 | * Designed to free unused ata_queued_cmd object | ||
| 4616 | * in case something prevents using it. | ||
| 4617 | * | ||
| 4618 | * LOCKING: | ||
| 4619 | * spin_lock_irqsave(host lock) | ||
| 4620 | */ | ||
| 4621 | void ata_qc_free(struct ata_queued_cmd *qc) | ||
| 4622 | { | ||
| 4623 | struct ata_port *ap = qc->ap; | ||
| 4624 | unsigned int tag; | ||
| 4625 | |||
| 4626 | WARN_ON(qc == NULL); /* ata_qc_from_tag _might_ return NULL */ | ||
| 4627 | |||
| 4628 | qc->flags = 0; | ||
| 4629 | tag = qc->tag; | ||
| 4630 | if (likely(ata_tag_valid(tag))) { | ||
| 4631 | qc->tag = ATA_TAG_POISON; | ||
| 4632 | clear_bit(tag, &ap->qc_allocated); | ||
| 4633 | } | ||
| 4634 | } | ||
| 4635 | |||
| 4636 | void __ata_qc_complete(struct ata_queued_cmd *qc) | 4582 | void __ata_qc_complete(struct ata_queued_cmd *qc) |
| 4637 | { | 4583 | { |
| 4638 | struct ata_port *ap = qc->ap; | 4584 | struct ata_port *ap = qc->ap; |
diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c index 5d312dc9be9f..d5b9b7266c8b 100644 --- a/drivers/ata/libata-scsi.c +++ b/drivers/ata/libata-scsi.c | |||
| @@ -708,7 +708,7 @@ static struct ata_queued_cmd *ata_scsi_qc_new(struct ata_device *dev, | |||
| 708 | { | 708 | { |
| 709 | struct ata_queued_cmd *qc; | 709 | struct ata_queued_cmd *qc; |
| 710 | 710 | ||
| 711 | qc = ata_qc_new_init(dev); | 711 | qc = ata_qc_new_init(dev, cmd->request->tag); |
| 712 | if (qc) { | 712 | if (qc) { |
| 713 | qc->scsicmd = cmd; | 713 | qc->scsicmd = cmd; |
| 714 | qc->scsidone = done; | 714 | qc->scsidone = done; |
| @@ -1103,7 +1103,8 @@ static int ata_scsi_dev_config(struct scsi_device *sdev, | |||
| 1103 | 1103 | ||
| 1104 | depth = min(sdev->host->can_queue, ata_id_queue_depth(dev->id)); | 1104 | depth = min(sdev->host->can_queue, ata_id_queue_depth(dev->id)); |
| 1105 | depth = min(ATA_MAX_QUEUE - 1, depth); | 1105 | depth = min(ATA_MAX_QUEUE - 1, depth); |
| 1106 | scsi_adjust_queue_depth(sdev, MSG_SIMPLE_TAG, depth); | 1106 | scsi_set_tag_type(sdev, MSG_SIMPLE_TAG); |
| 1107 | scsi_activate_tcq(sdev, depth); | ||
| 1107 | } | 1108 | } |
| 1108 | 1109 | ||
| 1109 | return 0; | 1110 | return 0; |
| @@ -1943,6 +1944,11 @@ static unsigned int ata_scsiop_inq_std(struct ata_scsi_args *args, u8 *rbuf) | |||
| 1943 | hdr[1] |= (1 << 7); | 1944 | hdr[1] |= (1 << 7); |
| 1944 | 1945 | ||
| 1945 | memcpy(rbuf, hdr, sizeof(hdr)); | 1946 | memcpy(rbuf, hdr, sizeof(hdr)); |
| 1947 | |||
| 1948 | /* if ncq, set tags supported */ | ||
| 1949 | if (ata_id_has_ncq(args->id)) | ||
| 1950 | rbuf[7] |= (1 << 1); | ||
| 1951 | |||
| 1946 | memcpy(&rbuf[8], "ATA ", 8); | 1952 | memcpy(&rbuf[8], "ATA ", 8); |
| 1947 | ata_id_string(args->id, &rbuf[16], ATA_ID_PROD, 16); | 1953 | ata_id_string(args->id, &rbuf[16], ATA_ID_PROD, 16); |
| 1948 | ata_id_string(args->id, &rbuf[32], ATA_ID_FW_REV, 4); | 1954 | ata_id_string(args->id, &rbuf[32], ATA_ID_FW_REV, 4); |
diff --git a/drivers/ata/libata.h b/drivers/ata/libata.h index fe2839e58774..d3831d39bdaa 100644 --- a/drivers/ata/libata.h +++ b/drivers/ata/libata.h | |||
| @@ -74,7 +74,7 @@ extern struct ata_link *ata_dev_phys_link(struct ata_device *dev); | |||
| 74 | extern void ata_force_cbl(struct ata_port *ap); | 74 | extern void ata_force_cbl(struct ata_port *ap); |
| 75 | extern u64 ata_tf_to_lba(const struct ata_taskfile *tf); | 75 | extern u64 ata_tf_to_lba(const struct ata_taskfile *tf); |
| 76 | extern u64 ata_tf_to_lba48(const struct ata_taskfile *tf); | 76 | extern u64 ata_tf_to_lba48(const struct ata_taskfile *tf); |
| 77 | extern struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev); | 77 | extern struct ata_queued_cmd *ata_qc_new_init(struct ata_device *dev, int tag); |
| 78 | extern int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev, | 78 | extern int ata_build_rw_tf(struct ata_taskfile *tf, struct ata_device *dev, |
| 79 | u64 block, u32 n_block, unsigned int tf_flags, | 79 | u64 block, u32 n_block, unsigned int tf_flags, |
| 80 | unsigned int tag); | 80 | unsigned int tag); |
| @@ -103,7 +103,6 @@ extern int ata_dev_configure(struct ata_device *dev); | |||
| 103 | extern int sata_down_spd_limit(struct ata_link *link); | 103 | extern int sata_down_spd_limit(struct ata_link *link); |
| 104 | extern int ata_down_xfermask_limit(struct ata_device *dev, unsigned int sel); | 104 | extern int ata_down_xfermask_limit(struct ata_device *dev, unsigned int sel); |
| 105 | extern void ata_sg_clean(struct ata_queued_cmd *qc); | 105 | extern void ata_sg_clean(struct ata_queued_cmd *qc); |
| 106 | extern void ata_qc_free(struct ata_queued_cmd *qc); | ||
| 107 | extern void ata_qc_issue(struct ata_queued_cmd *qc); | 106 | extern void ata_qc_issue(struct ata_queued_cmd *qc); |
| 108 | extern void __ata_qc_complete(struct ata_queued_cmd *qc); | 107 | extern void __ata_qc_complete(struct ata_queued_cmd *qc); |
| 109 | extern int atapi_check_dma(struct ata_queued_cmd *qc); | 108 | extern int atapi_check_dma(struct ata_queued_cmd *qc); |
| @@ -119,6 +118,22 @@ extern struct ata_port *ata_port_alloc(struct ata_host *host); | |||
| 119 | extern void ata_dev_enable_pm(struct ata_device *dev, enum link_pm policy); | 118 | extern void ata_dev_enable_pm(struct ata_device *dev, enum link_pm policy); |
| 120 | extern void ata_lpm_schedule(struct ata_port *ap, enum link_pm); | 119 | extern void ata_lpm_schedule(struct ata_port *ap, enum link_pm); |
| 121 | 120 | ||
| 121 | /** | ||
| 122 | * ata_qc_free - free unused ata_queued_cmd | ||
| 123 | * @qc: Command to complete | ||
| 124 | * | ||
| 125 | * Designed to free unused ata_queued_cmd object | ||
| 126 | * in case something prevents using it. | ||
| 127 | * | ||
| 128 | * LOCKING: | ||
| 129 | * spin_lock_irqsave(host lock) | ||
| 130 | */ | ||
| 131 | static inline void ata_qc_free(struct ata_queued_cmd *qc) | ||
| 132 | { | ||
| 133 | qc->flags = 0; | ||
| 134 | qc->tag = ATA_TAG_POISON; | ||
| 135 | } | ||
| 136 | |||
| 122 | /* libata-acpi.c */ | 137 | /* libata-acpi.c */ |
| 123 | #ifdef CONFIG_ATA_ACPI | 138 | #ifdef CONFIG_ATA_ACPI |
| 124 | extern void ata_acpi_associate_sata_port(struct ata_port *ap); | 139 | extern void ata_acpi_associate_sata_port(struct ata_port *ap); |
diff --git a/drivers/cpuidle/cpuidle.c b/drivers/cpuidle/cpuidle.c index bb6e3b338043..5bed73329ef8 100644 --- a/drivers/cpuidle/cpuidle.c +++ b/drivers/cpuidle/cpuidle.c | |||
| @@ -16,6 +16,7 @@ | |||
| 16 | #include <linux/cpu.h> | 16 | #include <linux/cpu.h> |
| 17 | #include <linux/cpuidle.h> | 17 | #include <linux/cpuidle.h> |
| 18 | #include <linux/ktime.h> | 18 | #include <linux/ktime.h> |
| 19 | #include <linux/hrtimer.h> | ||
| 19 | 20 | ||
| 20 | #include "cpuidle.h" | 21 | #include "cpuidle.h" |
| 21 | 22 | ||
| @@ -64,6 +65,12 @@ static void cpuidle_idle_call(void) | |||
| 64 | return; | 65 | return; |
| 65 | } | 66 | } |
| 66 | 67 | ||
| 68 | /* | ||
| 69 | * run any timers that can be run now, at this point | ||
| 70 | * before calculating the idle duration etc. | ||
| 71 | */ | ||
| 72 | hrtimer_peek_ahead_timers(); | ||
| 73 | |||
| 67 | /* ask the governor for the next state */ | 74 | /* ask the governor for the next state */ |
| 68 | next_state = cpuidle_curr_governor->select(dev); | 75 | next_state = cpuidle_curr_governor->select(dev); |
| 69 | if (need_resched()) | 76 | if (need_resched()) |
diff --git a/drivers/ide/Kconfig b/drivers/ide/Kconfig index a820ca6fc327..6d7401772a8f 100644 --- a/drivers/ide/Kconfig +++ b/drivers/ide/Kconfig | |||
| @@ -720,6 +720,16 @@ config BLK_DEV_IDE_AU1XXX_SEQTS_PER_RQ | |||
| 720 | default "128" | 720 | default "128" |
| 721 | depends on BLK_DEV_IDE_AU1XXX | 721 | depends on BLK_DEV_IDE_AU1XXX |
| 722 | 722 | ||
| 723 | config BLK_DEV_IDE_TX4938 | ||
| 724 | tristate "TX4938 internal IDE support" | ||
| 725 | depends on SOC_TX4938 | ||
| 726 | select IDE_TIMINGS | ||
| 727 | |||
| 728 | config BLK_DEV_IDE_TX4939 | ||
| 729 | tristate "TX4939 internal IDE support" | ||
| 730 | depends on SOC_TX4939 | ||
| 731 | select BLK_DEV_IDEDMA_SFF | ||
| 732 | |||
| 723 | config IDE_ARM | 733 | config IDE_ARM |
| 724 | tristate "ARM IDE support" | 734 | tristate "ARM IDE support" |
| 725 | depends on ARM && (ARCH_CLPS7500 || ARCH_RPC || ARCH_SHARK) | 735 | depends on ARM && (ARCH_CLPS7500 || ARCH_RPC || ARCH_SHARK) |
diff --git a/drivers/ide/Makefile b/drivers/ide/Makefile index 9cf92ac939d2..7818d402b188 100644 --- a/drivers/ide/Makefile +++ b/drivers/ide/Makefile | |||
| @@ -68,7 +68,6 @@ obj-$(CONFIG_BLK_DEV_VIA82CXXX) += via82cxxx.o | |||
| 68 | 68 | ||
| 69 | # Must appear at the end of the block | 69 | # Must appear at the end of the block |
| 70 | obj-$(CONFIG_BLK_DEV_GENERIC) += ide-pci-generic.o | 70 | obj-$(CONFIG_BLK_DEV_GENERIC) += ide-pci-generic.o |
| 71 | ide-pci-generic-y += generic.o | ||
| 72 | 71 | ||
| 73 | obj-$(CONFIG_IDEPCI_PCIBUS_ORDER) += ide-scan-pci.o | 72 | obj-$(CONFIG_IDEPCI_PCIBUS_ORDER) += ide-scan-pci.o |
| 74 | 73 | ||
| @@ -111,3 +110,6 @@ obj-$(CONFIG_BLK_DEV_IDE_RAPIDE) += rapide.o | |||
| 111 | obj-$(CONFIG_BLK_DEV_PALMCHIP_BK3710) += palm_bk3710.o | 110 | obj-$(CONFIG_BLK_DEV_PALMCHIP_BK3710) += palm_bk3710.o |
| 112 | 111 | ||
| 113 | obj-$(CONFIG_BLK_DEV_IDE_AU1XXX) += au1xxx-ide.o | 112 | obj-$(CONFIG_BLK_DEV_IDE_AU1XXX) += au1xxx-ide.o |
| 113 | |||
| 114 | obj-$(CONFIG_BLK_DEV_IDE_TX4938) += tx4938ide.o | ||
| 115 | obj-$(CONFIG_BLK_DEV_IDE_TX4939) += tx4939ide.o | ||
diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c index 133afd09843c..48b5eda3ab41 100644 --- a/drivers/ide/ide-cd.c +++ b/drivers/ide/ide-cd.c | |||
| @@ -1966,6 +1966,7 @@ static const struct cd_list_entry ide_cd_quirks_list[] = { | |||
| 1966 | { "Optiarc DVD RW AD-5200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, | 1966 | { "Optiarc DVD RW AD-5200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, |
| 1967 | { "Optiarc DVD RW AD-7200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, | 1967 | { "Optiarc DVD RW AD-7200A", NULL, IDE_AFLAG_PLAY_AUDIO_OK }, |
| 1968 | { "Optiarc DVD RW AD-7543A", NULL, IDE_AFLAG_NO_AUTOCLOSE }, | 1968 | { "Optiarc DVD RW AD-7543A", NULL, IDE_AFLAG_NO_AUTOCLOSE }, |
| 1969 | { "TEAC CD-ROM CD-224E", NULL, IDE_AFLAG_NO_AUTOCLOSE }, | ||
| 1969 | { NULL, NULL, 0 } | 1970 | { NULL, NULL, 0 } |
| 1970 | }; | 1971 | }; |
| 1971 | 1972 | ||
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c index 223750c1b5a6..e5adebe8ac2c 100644 --- a/drivers/ide/ide-disk.c +++ b/drivers/ide/ide-disk.c | |||
| @@ -600,6 +600,7 @@ static int ide_disk_check(ide_drive_t *drive, const char *s) | |||
| 600 | static void ide_disk_setup(ide_drive_t *drive) | 600 | static void ide_disk_setup(ide_drive_t *drive) |
| 601 | { | 601 | { |
| 602 | struct ide_disk_obj *idkp = drive->driver_data; | 602 | struct ide_disk_obj *idkp = drive->driver_data; |
| 603 | struct request_queue *q = drive->queue; | ||
| 603 | ide_hwif_t *hwif = drive->hwif; | 604 | ide_hwif_t *hwif = drive->hwif; |
| 604 | u16 *id = drive->id; | 605 | u16 *id = drive->id; |
| 605 | char *m = (char *)&id[ATA_ID_PROD]; | 606 | char *m = (char *)&id[ATA_ID_PROD]; |
| @@ -626,11 +627,14 @@ static void ide_disk_setup(ide_drive_t *drive) | |||
| 626 | if (max_s > hwif->rqsize) | 627 | if (max_s > hwif->rqsize) |
| 627 | max_s = hwif->rqsize; | 628 | max_s = hwif->rqsize; |
| 628 | 629 | ||
| 629 | blk_queue_max_sectors(drive->queue, max_s); | 630 | blk_queue_max_sectors(q, max_s); |
| 630 | } | 631 | } |
| 631 | 632 | ||
| 632 | printk(KERN_INFO "%s: max request size: %dKiB\n", drive->name, | 633 | printk(KERN_INFO "%s: max request size: %dKiB\n", drive->name, |
| 633 | drive->queue->max_sectors / 2); | 634 | q->max_sectors / 2); |
| 635 | |||
| 636 | if (ata_id_is_ssd(id) || ata_id_is_cfa(id)) | ||
| 637 | queue_flag_set_unlocked(QUEUE_FLAG_NONROT, q); | ||
| 634 | 638 | ||
| 635 | /* calculate drive capacity, and select LBA if possible */ | 639 | /* calculate drive capacity, and select LBA if possible */ |
| 636 | ide_disk_get_capacity(drive); | 640 | ide_disk_get_capacity(drive); |
diff --git a/drivers/ide/generic.c b/drivers/ide/ide-pci-generic.c index 474f96a7c076..474f96a7c076 100644 --- a/drivers/ide/generic.c +++ b/drivers/ide/ide-pci-generic.c | |||
diff --git a/drivers/ide/scc_pata.c b/drivers/ide/scc_pata.c index 49f163aa51e3..f26aa5d54efb 100644 --- a/drivers/ide/scc_pata.c +++ b/drivers/ide/scc_pata.c | |||
| @@ -536,10 +536,6 @@ static u8 scc_udma_filter(ide_drive_t *drive) | |||
| 536 | 536 | ||
| 537 | static int setup_mmio_scc (struct pci_dev *dev, const char *name) | 537 | static int setup_mmio_scc (struct pci_dev *dev, const char *name) |
| 538 | { | 538 | { |
| 539 | unsigned long ctl_base = pci_resource_start(dev, 0); | ||
| 540 | unsigned long dma_base = pci_resource_start(dev, 1); | ||
| 541 | unsigned long ctl_size = pci_resource_len(dev, 0); | ||
| 542 | unsigned long dma_size = pci_resource_len(dev, 1); | ||
| 543 | void __iomem *ctl_addr; | 539 | void __iomem *ctl_addr; |
| 544 | void __iomem *dma_addr; | 540 | void __iomem *dma_addr; |
| 545 | int i, ret; | 541 | int i, ret; |
| @@ -557,10 +553,12 @@ static int setup_mmio_scc (struct pci_dev *dev, const char *name) | |||
| 557 | return ret; | 553 | return ret; |
| 558 | } | 554 | } |
| 559 | 555 | ||
| 560 | if ((ctl_addr = ioremap(ctl_base, ctl_size)) == NULL) | 556 | ctl_addr = pci_ioremap_bar(dev, 0); |
| 557 | if (!ctl_addr) | ||
| 561 | goto fail_0; | 558 | goto fail_0; |
| 562 | 559 | ||
| 563 | if ((dma_addr = ioremap(dma_base, dma_size)) == NULL) | 560 | dma_addr = pci_ioremap_bar(dev, 1); |
| 561 | if (!dma_addr) | ||
| 564 | goto fail_1; | 562 | goto fail_1; |
| 565 | 563 | ||
| 566 | pci_set_master(dev); | 564 | pci_set_master(dev); |
diff --git a/drivers/ide/sgiioc4.c b/drivers/ide/sgiioc4.c index 8af9b23499fd..7defa0ae2014 100644 --- a/drivers/ide/sgiioc4.c +++ b/drivers/ide/sgiioc4.c | |||
| @@ -567,14 +567,12 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
| 567 | unsigned long cmd_base, irqport; | 567 | unsigned long cmd_base, irqport; |
| 568 | unsigned long bar0, cmd_phys_base, ctl; | 568 | unsigned long bar0, cmd_phys_base, ctl; |
| 569 | void __iomem *virt_base; | 569 | void __iomem *virt_base; |
| 570 | struct ide_host *host; | ||
| 571 | hw_regs_t hw, *hws[] = { &hw, NULL, NULL, NULL }; | 570 | hw_regs_t hw, *hws[] = { &hw, NULL, NULL, NULL }; |
| 572 | struct ide_port_info d = sgiioc4_port_info; | ||
| 573 | int rc; | 571 | int rc; |
| 574 | 572 | ||
| 575 | /* Get the CmdBlk and CtrlBlk Base Registers */ | 573 | /* Get the CmdBlk and CtrlBlk Base Registers */ |
| 576 | bar0 = pci_resource_start(dev, 0); | 574 | bar0 = pci_resource_start(dev, 0); |
| 577 | virt_base = ioremap(bar0, pci_resource_len(dev, 0)); | 575 | virt_base = pci_ioremap_bar(dev, 0); |
| 578 | if (virt_base == NULL) { | 576 | if (virt_base == NULL) { |
| 579 | printk(KERN_ERR "%s: Unable to remap BAR 0 address: 0x%lx\n", | 577 | printk(KERN_ERR "%s: Unable to remap BAR 0 address: 0x%lx\n", |
| 580 | DRV_NAME, bar0); | 578 | DRV_NAME, bar0); |
| @@ -590,7 +588,8 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
| 590 | printk(KERN_ERR "%s %s -- ERROR: addresses 0x%08lx to 0x%08lx " | 588 | printk(KERN_ERR "%s %s -- ERROR: addresses 0x%08lx to 0x%08lx " |
| 591 | "already in use\n", DRV_NAME, pci_name(dev), | 589 | "already in use\n", DRV_NAME, pci_name(dev), |
| 592 | cmd_phys_base, cmd_phys_base + IOC4_CMD_CTL_BLK_SIZE); | 590 | cmd_phys_base, cmd_phys_base + IOC4_CMD_CTL_BLK_SIZE); |
| 593 | return -EBUSY; | 591 | rc = -EBUSY; |
| 592 | goto req_mem_rgn_err; | ||
| 594 | } | 593 | } |
| 595 | 594 | ||
| 596 | /* Initialize the IO registers */ | 595 | /* Initialize the IO registers */ |
| @@ -603,21 +602,12 @@ sgiioc4_ide_setup_pci_device(struct pci_dev *dev) | |||
| 603 | /* Initializing chipset IRQ Registers */ | 602 | /* Initializing chipset IRQ Registers */ |
| 604 | writel(0x03, (void __iomem *)(irqport + IOC4_INTR_SET * 4)); | 603 | writel(0x03, (void __iomem *)(irqport + IOC4_INTR_SET * 4)); |
| 605 | 604 | ||
| 606 | host = ide_host_alloc(&d, hws); | 605 | rc = ide_host_add(&sgiioc4_port_info, hws, NULL); |
| 607 | if (host == NULL) { | 606 | if (!rc) |
| 608 | rc = -ENOMEM; | 607 | return 0; |
| 609 | goto err; | ||
| 610 | } | ||
| 611 | |||
| 612 | rc = ide_host_register(host, &d, hws); | ||
| 613 | if (rc) | ||
| 614 | goto err_free; | ||
| 615 | 608 | ||
| 616 | return 0; | ||
| 617 | err_free: | ||
| 618 | ide_host_free(host); | ||
| 619 | err: | ||
| 620 | release_mem_region(cmd_phys_base, IOC4_CMD_CTL_BLK_SIZE); | 609 | release_mem_region(cmd_phys_base, IOC4_CMD_CTL_BLK_SIZE); |
| 610 | req_mem_rgn_err: | ||
| 621 | iounmap(virt_base); | 611 | iounmap(virt_base); |
| 622 | return rc; | 612 | return rc; |
| 623 | } | 613 | } |
diff --git a/drivers/ide/siimage.c b/drivers/ide/siimage.c index eb4faf92c571..c3107df7773d 100644 --- a/drivers/ide/siimage.c +++ b/drivers/ide/siimage.c | |||
| @@ -784,7 +784,7 @@ static int __devinit siimage_init_one(struct pci_dev *dev, | |||
| 784 | printk(KERN_WARNING DRV_NAME " %s: MMIO ports not " | 784 | printk(KERN_WARNING DRV_NAME " %s: MMIO ports not " |
| 785 | "available\n", pci_name(dev)); | 785 | "available\n", pci_name(dev)); |
| 786 | } else { | 786 | } else { |
| 787 | ioaddr = ioremap(bar5, barsize); | 787 | ioaddr = pci_ioremap_bar(dev, 5); |
| 788 | if (ioaddr == NULL) | 788 | if (ioaddr == NULL) |
| 789 | release_mem_region(bar5, barsize); | 789 | release_mem_region(bar5, barsize); |
| 790 | } | 790 | } |
diff --git a/drivers/ide/tx4938ide.c b/drivers/ide/tx4938ide.c new file mode 100644 index 000000000000..fa660f931a11 --- /dev/null +++ b/drivers/ide/tx4938ide.c | |||
| @@ -0,0 +1,310 @@ | |||
| 1 | /* | ||
| 2 | * TX4938 internal IDE driver | ||
| 3 | * Based on tx4939ide.c. | ||
| 4 | * | ||
| 5 | * This file is subject to the terms and conditions of the GNU General Public | ||
| 6 | * License. See the file "COPYING" in the main directory of this archive | ||
| 7 | * for more details. | ||
| 8 | * | ||
| 9 | * (C) Copyright TOSHIBA CORPORATION 2005-2007 | ||
| 10 | */ | ||
| 11 | |||
| 12 | #include <linux/module.h> | ||
| 13 | #include <linux/types.h> | ||
| 14 | #include <linux/ide.h> | ||
| 15 | #include <linux/init.h> | ||
| 16 | #include <linux/platform_device.h> | ||
| 17 | #include <linux/io.h> | ||
| 18 | #include <asm/txx9/tx4938.h> | ||
| 19 | |||
| 20 | static void tx4938ide_tune_ebusc(unsigned int ebus_ch, | ||
| 21 | unsigned int gbus_clock, | ||
| 22 | u8 pio) | ||
| 23 | { | ||
| 24 | struct ide_timing *t = ide_timing_find_mode(XFER_PIO_0 + pio); | ||
| 25 | u64 cr = __raw_readq(&tx4938_ebuscptr->cr[ebus_ch]); | ||
| 26 | unsigned int sp = (cr >> 4) & 3; | ||
| 27 | unsigned int clock = gbus_clock / (4 - sp); | ||
| 28 | unsigned int cycle = 1000000000 / clock; | ||
| 29 | unsigned int wt, shwt; | ||
| 30 | |||
| 31 | /* Minimum DIOx- active time */ | ||
| 32 | wt = DIV_ROUND_UP(t->act8b, cycle) - 2; | ||
| 33 | /* IORDY setup time: 35ns */ | ||
| 34 | wt = max(wt, DIV_ROUND_UP(35, cycle)); | ||
| 35 | /* actual wait-cycle is max(wt & ~1, 1) */ | ||
| 36 | if (wt > 2 && (wt & 1)) | ||
| 37 | wt++; | ||
| 38 | wt &= ~1; | ||
| 39 | /* Address-valid to DIOR/DIOW setup */ | ||
| 40 | shwt = DIV_ROUND_UP(t->setup, cycle); | ||
| 41 | |||
| 42 | pr_debug("tx4938ide: ebus %d, bus cycle %dns, WT %d, SHWT %d\n", | ||
| 43 | ebus_ch, cycle, wt, shwt); | ||
| 44 | |||
| 45 | __raw_writeq((cr & ~(0x3f007ull)) | (wt << 12) | shwt, | ||
| 46 | &tx4938_ebuscptr->cr[ebus_ch]); | ||
| 47 | } | ||
| 48 | |||
| 49 | static void tx4938ide_set_pio_mode(ide_drive_t *drive, const u8 pio) | ||
| 50 | { | ||
| 51 | ide_hwif_t *hwif = drive->hwif; | ||
| 52 | struct tx4938ide_platform_info *pdata = hwif->dev->platform_data; | ||
| 53 | u8 safe = pio; | ||
| 54 | ide_drive_t *pair; | ||
| 55 | |||
| 56 | pair = ide_get_pair_dev(drive); | ||
| 57 | if (pair) | ||
| 58 | safe = min(safe, ide_get_best_pio_mode(pair, 255, 5)); | ||
| 59 | tx4938ide_tune_ebusc(pdata->ebus_ch, pdata->gbus_clock, safe); | ||
| 60 | } | ||
| 61 | |||
| 62 | #ifdef __BIG_ENDIAN | ||
| 63 | |||
| 64 | /* custom iops (independent from SWAP_IO_SPACE) */ | ||
| 65 | static u8 tx4938ide_inb(unsigned long port) | ||
| 66 | { | ||
| 67 | return __raw_readb((void __iomem *)port); | ||
| 68 | } | ||
| 69 | |||
| 70 | static void tx4938ide_outb(u8 value, unsigned long port) | ||
| 71 | { | ||
| 72 | __raw_writeb(value, (void __iomem *)port); | ||
| 73 | } | ||
| 74 | |||
| 75 | static void tx4938ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
| 76 | { | ||
| 77 | ide_hwif_t *hwif = drive->hwif; | ||
| 78 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
| 79 | struct ide_taskfile *tf = &task->tf; | ||
| 80 | u8 HIHI = task->tf_flags & IDE_TFLAG_LBA48 ? 0xE0 : 0xEF; | ||
| 81 | |||
| 82 | if (task->tf_flags & IDE_TFLAG_FLAGGED) | ||
| 83 | HIHI = 0xFF; | ||
| 84 | |||
| 85 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) { | ||
| 86 | u16 data = (tf->hob_data << 8) | tf->data; | ||
| 87 | |||
| 88 | /* no endian swap */ | ||
| 89 | __raw_writew(data, (void __iomem *)io_ports->data_addr); | ||
| 90 | } | ||
| 91 | |||
| 92 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | ||
| 93 | tx4938ide_outb(tf->hob_feature, io_ports->feature_addr); | ||
| 94 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | ||
| 95 | tx4938ide_outb(tf->hob_nsect, io_ports->nsect_addr); | ||
| 96 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) | ||
| 97 | tx4938ide_outb(tf->hob_lbal, io_ports->lbal_addr); | ||
| 98 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) | ||
| 99 | tx4938ide_outb(tf->hob_lbam, io_ports->lbam_addr); | ||
| 100 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) | ||
| 101 | tx4938ide_outb(tf->hob_lbah, io_ports->lbah_addr); | ||
| 102 | |||
| 103 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) | ||
| 104 | tx4938ide_outb(tf->feature, io_ports->feature_addr); | ||
| 105 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) | ||
| 106 | tx4938ide_outb(tf->nsect, io_ports->nsect_addr); | ||
| 107 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) | ||
| 108 | tx4938ide_outb(tf->lbal, io_ports->lbal_addr); | ||
| 109 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) | ||
| 110 | tx4938ide_outb(tf->lbam, io_ports->lbam_addr); | ||
| 111 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) | ||
| 112 | tx4938ide_outb(tf->lbah, io_ports->lbah_addr); | ||
| 113 | |||
| 114 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) | ||
| 115 | tx4938ide_outb((tf->device & HIHI) | drive->select, | ||
| 116 | io_ports->device_addr); | ||
| 117 | } | ||
| 118 | |||
| 119 | static void tx4938ide_tf_read(ide_drive_t *drive, ide_task_t *task) | ||
| 120 | { | ||
| 121 | ide_hwif_t *hwif = drive->hwif; | ||
| 122 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
| 123 | struct ide_taskfile *tf = &task->tf; | ||
| 124 | |||
| 125 | if (task->tf_flags & IDE_TFLAG_IN_DATA) { | ||
| 126 | u16 data; | ||
| 127 | |||
| 128 | /* no endian swap */ | ||
| 129 | data = __raw_readw((void __iomem *)io_ports->data_addr); | ||
| 130 | tf->data = data & 0xff; | ||
| 131 | tf->hob_data = (data >> 8) & 0xff; | ||
| 132 | } | ||
| 133 | |||
| 134 | /* be sure we're looking at the low order bits */ | ||
| 135 | tx4938ide_outb(ATA_DEVCTL_OBS & ~0x80, io_ports->ctl_addr); | ||
| 136 | |||
| 137 | if (task->tf_flags & IDE_TFLAG_IN_FEATURE) | ||
| 138 | tf->feature = tx4938ide_inb(io_ports->feature_addr); | ||
| 139 | if (task->tf_flags & IDE_TFLAG_IN_NSECT) | ||
| 140 | tf->nsect = tx4938ide_inb(io_ports->nsect_addr); | ||
| 141 | if (task->tf_flags & IDE_TFLAG_IN_LBAL) | ||
| 142 | tf->lbal = tx4938ide_inb(io_ports->lbal_addr); | ||
| 143 | if (task->tf_flags & IDE_TFLAG_IN_LBAM) | ||
| 144 | tf->lbam = tx4938ide_inb(io_ports->lbam_addr); | ||
| 145 | if (task->tf_flags & IDE_TFLAG_IN_LBAH) | ||
| 146 | tf->lbah = tx4938ide_inb(io_ports->lbah_addr); | ||
| 147 | if (task->tf_flags & IDE_TFLAG_IN_DEVICE) | ||
| 148 | tf->device = tx4938ide_inb(io_ports->device_addr); | ||
| 149 | |||
| 150 | if (task->tf_flags & IDE_TFLAG_LBA48) { | ||
| 151 | tx4938ide_outb(ATA_DEVCTL_OBS | 0x80, io_ports->ctl_addr); | ||
| 152 | |||
| 153 | if (task->tf_flags & IDE_TFLAG_IN_HOB_FEATURE) | ||
| 154 | tf->hob_feature = | ||
| 155 | tx4938ide_inb(io_ports->feature_addr); | ||
| 156 | if (task->tf_flags & IDE_TFLAG_IN_HOB_NSECT) | ||
| 157 | tf->hob_nsect = tx4938ide_inb(io_ports->nsect_addr); | ||
| 158 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAL) | ||
| 159 | tf->hob_lbal = tx4938ide_inb(io_ports->lbal_addr); | ||
| 160 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAM) | ||
| 161 | tf->hob_lbam = tx4938ide_inb(io_ports->lbam_addr); | ||
| 162 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAH) | ||
| 163 | tf->hob_lbah = tx4938ide_inb(io_ports->lbah_addr); | ||
| 164 | } | ||
| 165 | } | ||
| 166 | |||
| 167 | static void tx4938ide_input_data_swap(ide_drive_t *drive, struct request *rq, | ||
| 168 | void *buf, unsigned int len) | ||
| 169 | { | ||
| 170 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
| 171 | unsigned short *ptr = buf; | ||
| 172 | unsigned int count = (len + 1) / 2; | ||
| 173 | |||
| 174 | while (count--) | ||
| 175 | *ptr++ = cpu_to_le16(__raw_readw((void __iomem *)port)); | ||
| 176 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
| 177 | } | ||
| 178 | |||
| 179 | static void tx4938ide_output_data_swap(ide_drive_t *drive, struct request *rq, | ||
| 180 | void *buf, unsigned int len) | ||
| 181 | { | ||
| 182 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
| 183 | unsigned short *ptr = buf; | ||
| 184 | unsigned int count = (len + 1) / 2; | ||
| 185 | |||
| 186 | while (count--) { | ||
| 187 | __raw_writew(le16_to_cpu(*ptr), (void __iomem *)port); | ||
| 188 | ptr++; | ||
| 189 | } | ||
| 190 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
| 191 | } | ||
| 192 | |||
| 193 | static const struct ide_tp_ops tx4938ide_tp_ops = { | ||
| 194 | .exec_command = ide_exec_command, | ||
| 195 | .read_status = ide_read_status, | ||
| 196 | .read_altstatus = ide_read_altstatus, | ||
| 197 | .read_sff_dma_status = ide_read_sff_dma_status, | ||
| 198 | |||
| 199 | .set_irq = ide_set_irq, | ||
| 200 | |||
| 201 | .tf_load = tx4938ide_tf_load, | ||
| 202 | .tf_read = tx4938ide_tf_read, | ||
| 203 | |||
| 204 | .input_data = tx4938ide_input_data_swap, | ||
| 205 | .output_data = tx4938ide_output_data_swap, | ||
| 206 | }; | ||
| 207 | |||
| 208 | #endif /* __BIG_ENDIAN */ | ||
| 209 | |||
| 210 | static const struct ide_port_ops tx4938ide_port_ops = { | ||
| 211 | .set_pio_mode = tx4938ide_set_pio_mode, | ||
| 212 | }; | ||
| 213 | |||
| 214 | static const struct ide_port_info tx4938ide_port_info __initdata = { | ||
| 215 | .port_ops = &tx4938ide_port_ops, | ||
| 216 | #ifdef __BIG_ENDIAN | ||
| 217 | .tp_ops = &tx4938ide_tp_ops, | ||
| 218 | #endif | ||
| 219 | .host_flags = IDE_HFLAG_MMIO | IDE_HFLAG_NO_DMA, | ||
| 220 | .pio_mask = ATA_PIO5, | ||
| 221 | }; | ||
| 222 | |||
| 223 | static int __init tx4938ide_probe(struct platform_device *pdev) | ||
| 224 | { | ||
| 225 | hw_regs_t hw; | ||
| 226 | hw_regs_t *hws[] = { &hw, NULL, NULL, NULL }; | ||
| 227 | struct ide_host *host; | ||
| 228 | struct resource *res; | ||
| 229 | struct tx4938ide_platform_info *pdata = pdev->dev.platform_data; | ||
| 230 | int irq, ret, i; | ||
| 231 | unsigned long mapbase; | ||
| 232 | struct ide_port_info d = tx4938ide_port_info; | ||
| 233 | |||
| 234 | irq = platform_get_irq(pdev, 0); | ||
| 235 | if (irq < 0) | ||
| 236 | return -ENODEV; | ||
| 237 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | ||
| 238 | if (!res) | ||
| 239 | return -ENODEV; | ||
| 240 | |||
| 241 | if (!devm_request_mem_region(&pdev->dev, res->start, | ||
| 242 | res->end - res->start + 1, "tx4938ide")) | ||
| 243 | return -EBUSY; | ||
| 244 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, | ||
| 245 | res->end - res->start + 1); | ||
| 246 | if (!mapbase) | ||
| 247 | return -EBUSY; | ||
| 248 | |||
| 249 | memset(&hw, 0, sizeof(hw)); | ||
| 250 | if (pdata->ioport_shift) { | ||
| 251 | unsigned long port = mapbase; | ||
| 252 | |||
| 253 | hw.io_ports_array[0] = port; | ||
| 254 | #ifdef __BIG_ENDIAN | ||
| 255 | port++; | ||
| 256 | #endif | ||
| 257 | for (i = 1; i <= 7; i++) | ||
| 258 | hw.io_ports_array[i] = | ||
| 259 | port + (i << pdata->ioport_shift); | ||
| 260 | hw.io_ports.ctl_addr = | ||
| 261 | port + 0x10000 + (6 << pdata->ioport_shift); | ||
| 262 | } else | ||
| 263 | ide_std_init_ports(&hw, mapbase, mapbase + 0x10006); | ||
| 264 | hw.irq = irq; | ||
| 265 | hw.dev = &pdev->dev; | ||
| 266 | |||
| 267 | pr_info("TX4938 IDE interface (base %#lx, irq %d)\n", mapbase, hw.irq); | ||
| 268 | if (pdata->gbus_clock) | ||
| 269 | tx4938ide_tune_ebusc(pdata->ebus_ch, pdata->gbus_clock, 0); | ||
| 270 | else | ||
| 271 | d.port_ops = NULL; | ||
| 272 | ret = ide_host_add(&d, hws, &host); | ||
| 273 | if (ret) | ||
| 274 | return ret; | ||
| 275 | platform_set_drvdata(pdev, host); | ||
| 276 | return 0; | ||
| 277 | } | ||
| 278 | |||
| 279 | static int __exit tx4938ide_remove(struct platform_device *pdev) | ||
| 280 | { | ||
| 281 | struct ide_host *host = platform_get_drvdata(pdev); | ||
| 282 | |||
| 283 | ide_host_remove(host); | ||
| 284 | return 0; | ||
| 285 | } | ||
| 286 | |||
| 287 | static struct platform_driver tx4938ide_driver = { | ||
| 288 | .driver = { | ||
| 289 | .name = "tx4938ide", | ||
| 290 | .owner = THIS_MODULE, | ||
| 291 | }, | ||
| 292 | .remove = __exit_p(tx4938ide_remove), | ||
| 293 | }; | ||
| 294 | |||
| 295 | static int __init tx4938ide_init(void) | ||
| 296 | { | ||
| 297 | return platform_driver_probe(&tx4938ide_driver, tx4938ide_probe); | ||
| 298 | } | ||
| 299 | |||
| 300 | static void __exit tx4938ide_exit(void) | ||
| 301 | { | ||
| 302 | platform_driver_unregister(&tx4938ide_driver); | ||
| 303 | } | ||
| 304 | |||
| 305 | module_init(tx4938ide_init); | ||
| 306 | module_exit(tx4938ide_exit); | ||
| 307 | |||
| 308 | MODULE_DESCRIPTION("TX4938 internal IDE driver"); | ||
| 309 | MODULE_LICENSE("GPL"); | ||
| 310 | MODULE_ALIAS("platform:tx4938ide"); | ||
diff --git a/drivers/ide/tx4939ide.c b/drivers/ide/tx4939ide.c new file mode 100644 index 000000000000..bafb7d1a22e2 --- /dev/null +++ b/drivers/ide/tx4939ide.c | |||
| @@ -0,0 +1,754 @@ | |||
| 1 | /* | ||
| 2 | * TX4939 internal IDE driver | ||
| 3 | * Based on RBTX49xx patch from CELF patch archive. | ||
| 4 | * | ||
| 5 | * This file is subject to the terms and conditions of the GNU General Public | ||
| 6 | * License. See the file "COPYING" in the main directory of this archive | ||
| 7 | * for more details. | ||
| 8 | * | ||
| 9 | * (C) Copyright TOSHIBA CORPORATION 2005-2007 | ||
| 10 | */ | ||
| 11 | |||
| 12 | #include <linux/module.h> | ||
| 13 | #include <linux/types.h> | ||
| 14 | #include <linux/ide.h> | ||
| 15 | #include <linux/init.h> | ||
| 16 | #include <linux/delay.h> | ||
| 17 | #include <linux/platform_device.h> | ||
| 18 | #include <linux/io.h> | ||
| 19 | #include <linux/scatterlist.h> | ||
| 20 | |||
| 21 | #define MODNAME "tx4939ide" | ||
| 22 | |||
| 23 | /* ATA Shadow Registers (8-bit except for Data which is 16-bit) */ | ||
| 24 | #define TX4939IDE_Data 0x000 | ||
| 25 | #define TX4939IDE_Error_Feature 0x001 | ||
| 26 | #define TX4939IDE_Sec 0x002 | ||
| 27 | #define TX4939IDE_LBA0 0x003 | ||
| 28 | #define TX4939IDE_LBA1 0x004 | ||
| 29 | #define TX4939IDE_LBA2 0x005 | ||
| 30 | #define TX4939IDE_DevHead 0x006 | ||
| 31 | #define TX4939IDE_Stat_Cmd 0x007 | ||
| 32 | #define TX4939IDE_AltStat_DevCtl 0x402 | ||
| 33 | /* H/W DMA Registers */ | ||
| 34 | #define TX4939IDE_DMA_Cmd 0x800 /* 8-bit */ | ||
| 35 | #define TX4939IDE_DMA_Stat 0x802 /* 8-bit */ | ||
| 36 | #define TX4939IDE_PRD_Ptr 0x804 /* 32-bit */ | ||
| 37 | /* ATA100 CORE Registers (16-bit) */ | ||
| 38 | #define TX4939IDE_Sys_Ctl 0xc00 | ||
| 39 | #define TX4939IDE_Xfer_Cnt_1 0xc08 | ||
| 40 | #define TX4939IDE_Xfer_Cnt_2 0xc0a | ||
| 41 | #define TX4939IDE_Sec_Cnt 0xc10 | ||
| 42 | #define TX4939IDE_Start_Lo_Addr 0xc18 | ||
| 43 | #define TX4939IDE_Start_Up_Addr 0xc20 | ||
| 44 | #define TX4939IDE_Add_Ctl 0xc28 | ||
| 45 | #define TX4939IDE_Lo_Burst_Cnt 0xc30 | ||
| 46 | #define TX4939IDE_Up_Burst_Cnt 0xc38 | ||
| 47 | #define TX4939IDE_PIO_Addr 0xc88 | ||
| 48 | #define TX4939IDE_H_Rst_Tim 0xc90 | ||
| 49 | #define TX4939IDE_Int_Ctl 0xc98 | ||
| 50 | #define TX4939IDE_Pkt_Cmd 0xcb8 | ||
| 51 | #define TX4939IDE_Bxfer_Cnt_Hi 0xcc0 | ||
| 52 | #define TX4939IDE_Bxfer_Cnt_Lo 0xcc8 | ||
| 53 | #define TX4939IDE_Dev_TErr 0xcd0 | ||
| 54 | #define TX4939IDE_Pkt_Xfer_Ctl 0xcd8 | ||
| 55 | #define TX4939IDE_Start_TAddr 0xce0 | ||
| 56 | |||
| 57 | /* bits for Int_Ctl */ | ||
| 58 | #define TX4939IDE_INT_ADDRERR 0x80 | ||
| 59 | #define TX4939IDE_INT_REACHMUL 0x40 | ||
| 60 | #define TX4939IDE_INT_DEVTIMING 0x20 | ||
| 61 | #define TX4939IDE_INT_UDMATERM 0x10 | ||
| 62 | #define TX4939IDE_INT_TIMER 0x08 | ||
| 63 | #define TX4939IDE_INT_BUSERR 0x04 | ||
| 64 | #define TX4939IDE_INT_XFEREND 0x02 | ||
| 65 | #define TX4939IDE_INT_HOST 0x01 | ||
| 66 | |||
| 67 | #define TX4939IDE_IGNORE_INTS \ | ||
| 68 | (TX4939IDE_INT_ADDRERR | TX4939IDE_INT_REACHMUL | \ | ||
| 69 | TX4939IDE_INT_DEVTIMING | TX4939IDE_INT_UDMATERM | \ | ||
| 70 | TX4939IDE_INT_TIMER | TX4939IDE_INT_XFEREND) | ||
| 71 | |||
| 72 | #ifdef __BIG_ENDIAN | ||
| 73 | #define tx4939ide_swizzlel(a) ((a) ^ 4) | ||
| 74 | #define tx4939ide_swizzlew(a) ((a) ^ 6) | ||
| 75 | #define tx4939ide_swizzleb(a) ((a) ^ 7) | ||
| 76 | #else | ||
| 77 | #define tx4939ide_swizzlel(a) (a) | ||
| 78 | #define tx4939ide_swizzlew(a) (a) | ||
| 79 | #define tx4939ide_swizzleb(a) (a) | ||
| 80 | #endif | ||
| 81 | |||
| 82 | static u16 tx4939ide_readw(void __iomem *base, u32 reg) | ||
| 83 | { | ||
| 84 | return __raw_readw(base + tx4939ide_swizzlew(reg)); | ||
| 85 | } | ||
| 86 | static u8 tx4939ide_readb(void __iomem *base, u32 reg) | ||
| 87 | { | ||
| 88 | return __raw_readb(base + tx4939ide_swizzleb(reg)); | ||
| 89 | } | ||
| 90 | static void tx4939ide_writel(u32 val, void __iomem *base, u32 reg) | ||
| 91 | { | ||
| 92 | __raw_writel(val, base + tx4939ide_swizzlel(reg)); | ||
| 93 | } | ||
| 94 | static void tx4939ide_writew(u16 val, void __iomem *base, u32 reg) | ||
| 95 | { | ||
| 96 | __raw_writew(val, base + tx4939ide_swizzlew(reg)); | ||
| 97 | } | ||
| 98 | static void tx4939ide_writeb(u8 val, void __iomem *base, u32 reg) | ||
| 99 | { | ||
| 100 | __raw_writeb(val, base + tx4939ide_swizzleb(reg)); | ||
| 101 | } | ||
| 102 | |||
| 103 | #define TX4939IDE_BASE(hwif) ((void __iomem *)(hwif)->extra_base) | ||
| 104 | |||
| 105 | static void tx4939ide_set_pio_mode(ide_drive_t *drive, const u8 pio) | ||
| 106 | { | ||
| 107 | ide_hwif_t *hwif = drive->hwif; | ||
| 108 | int is_slave = drive->dn; | ||
| 109 | u32 mask, val; | ||
| 110 | u8 safe = pio; | ||
| 111 | ide_drive_t *pair; | ||
| 112 | |||
| 113 | pair = ide_get_pair_dev(drive); | ||
| 114 | if (pair) | ||
| 115 | safe = min(safe, ide_get_best_pio_mode(pair, 255, 4)); | ||
| 116 | /* | ||
| 117 | * Update Command Transfer Mode for master/slave and Data | ||
| 118 | * Transfer Mode for this drive. | ||
| 119 | */ | ||
| 120 | mask = is_slave ? 0x07f00000 : 0x000007f0; | ||
| 121 | val = ((safe << 8) | (pio << 4)) << (is_slave ? 16 : 0); | ||
| 122 | hwif->select_data = (hwif->select_data & ~mask) | val; | ||
| 123 | /* tx4939ide_tf_load_fixup() will set the Sys_Ctl register */ | ||
| 124 | } | ||
| 125 | |||
| 126 | static void tx4939ide_set_dma_mode(ide_drive_t *drive, const u8 mode) | ||
| 127 | { | ||
| 128 | ide_hwif_t *hwif = drive->hwif; | ||
| 129 | u32 mask, val; | ||
| 130 | |||
| 131 | /* Update Data Transfer Mode for this drive. */ | ||
| 132 | if (mode >= XFER_UDMA_0) | ||
| 133 | val = mode - XFER_UDMA_0 + 8; | ||
| 134 | else | ||
| 135 | val = mode - XFER_MW_DMA_0 + 5; | ||
| 136 | if (drive->dn) { | ||
| 137 | mask = 0x00f00000; | ||
| 138 | val <<= 20; | ||
| 139 | } else { | ||
| 140 | mask = 0x000000f0; | ||
| 141 | val <<= 4; | ||
| 142 | } | ||
| 143 | hwif->select_data = (hwif->select_data & ~mask) | val; | ||
| 144 | /* tx4939ide_tf_load_fixup() will set the Sys_Ctl register */ | ||
| 145 | } | ||
| 146 | |||
| 147 | static u16 tx4939ide_check_error_ints(ide_hwif_t *hwif) | ||
| 148 | { | ||
| 149 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 150 | u16 ctl = tx4939ide_readw(base, TX4939IDE_Int_Ctl); | ||
| 151 | |||
| 152 | if (ctl & TX4939IDE_INT_BUSERR) { | ||
| 153 | /* reset FIFO */ | ||
| 154 | u16 sysctl = tx4939ide_readw(base, TX4939IDE_Sys_Ctl); | ||
| 155 | |||
| 156 | tx4939ide_writew(sysctl | 0x4000, base, TX4939IDE_Sys_Ctl); | ||
| 157 | mmiowb(); | ||
| 158 | /* wait 12GBUSCLK (typ. 60ns @ GBUS200MHz, max 270ns) */ | ||
| 159 | ndelay(270); | ||
| 160 | tx4939ide_writew(sysctl, base, TX4939IDE_Sys_Ctl); | ||
| 161 | } | ||
| 162 | if (ctl & (TX4939IDE_INT_ADDRERR | | ||
| 163 | TX4939IDE_INT_DEVTIMING | TX4939IDE_INT_BUSERR)) | ||
| 164 | pr_err("%s: Error interrupt %#x (%s%s%s )\n", | ||
| 165 | hwif->name, ctl, | ||
| 166 | ctl & TX4939IDE_INT_ADDRERR ? " Address-Error" : "", | ||
| 167 | ctl & TX4939IDE_INT_DEVTIMING ? " DEV-Timing" : "", | ||
| 168 | ctl & TX4939IDE_INT_BUSERR ? " Bus-Error" : ""); | ||
| 169 | return ctl; | ||
| 170 | } | ||
| 171 | |||
| 172 | static void tx4939ide_clear_irq(ide_drive_t *drive) | ||
| 173 | { | ||
| 174 | ide_hwif_t *hwif; | ||
| 175 | void __iomem *base; | ||
| 176 | u16 ctl; | ||
| 177 | |||
| 178 | /* | ||
| 179 | * tx4939ide_dma_test_irq() and tx4939ide_dma_end() do all job | ||
| 180 | * for DMA case. | ||
| 181 | */ | ||
| 182 | if (drive->waiting_for_dma) | ||
| 183 | return; | ||
| 184 | hwif = drive->hwif; | ||
| 185 | base = TX4939IDE_BASE(hwif); | ||
| 186 | ctl = tx4939ide_check_error_ints(hwif); | ||
| 187 | tx4939ide_writew(ctl, base, TX4939IDE_Int_Ctl); | ||
| 188 | } | ||
| 189 | |||
| 190 | static u8 tx4939ide_cable_detect(ide_hwif_t *hwif) | ||
| 191 | { | ||
| 192 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 193 | |||
| 194 | return tx4939ide_readw(base, TX4939IDE_Sys_Ctl) & 0x2000 ? | ||
| 195 | ATA_CBL_PATA40 : ATA_CBL_PATA80; | ||
| 196 | } | ||
| 197 | |||
| 198 | #ifdef __BIG_ENDIAN | ||
| 199 | static void tx4939ide_dma_host_set(ide_drive_t *drive, int on) | ||
| 200 | { | ||
| 201 | ide_hwif_t *hwif = drive->hwif; | ||
| 202 | u8 unit = drive->dn; | ||
| 203 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 204 | u8 dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
| 205 | |||
| 206 | if (on) | ||
| 207 | dma_stat |= (1 << (5 + unit)); | ||
| 208 | else | ||
| 209 | dma_stat &= ~(1 << (5 + unit)); | ||
| 210 | |||
| 211 | tx4939ide_writeb(dma_stat, base, TX4939IDE_DMA_Stat); | ||
| 212 | } | ||
| 213 | #else | ||
| 214 | #define tx4939ide_dma_host_set ide_dma_host_set | ||
| 215 | #endif | ||
| 216 | |||
| 217 | static u8 tx4939ide_clear_dma_status(void __iomem *base) | ||
| 218 | { | ||
| 219 | u8 dma_stat; | ||
| 220 | |||
| 221 | /* read DMA status for INTR & ERROR flags */ | ||
| 222 | dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
| 223 | /* clear INTR & ERROR flags */ | ||
| 224 | tx4939ide_writeb(dma_stat | ATA_DMA_INTR | ATA_DMA_ERR, base, | ||
| 225 | TX4939IDE_DMA_Stat); | ||
| 226 | /* recover intmask cleared by writing to bit2 of DMA_Stat */ | ||
| 227 | tx4939ide_writew(TX4939IDE_IGNORE_INTS << 8, base, TX4939IDE_Int_Ctl); | ||
| 228 | return dma_stat; | ||
| 229 | } | ||
| 230 | |||
| 231 | #ifdef __BIG_ENDIAN | ||
| 232 | /* custom ide_build_dmatable to handle swapped layout */ | ||
| 233 | static int tx4939ide_build_dmatable(ide_drive_t *drive, struct request *rq) | ||
| 234 | { | ||
| 235 | ide_hwif_t *hwif = drive->hwif; | ||
| 236 | u32 *table = (u32 *)hwif->dmatable_cpu; | ||
| 237 | unsigned int count = 0; | ||
| 238 | int i; | ||
| 239 | struct scatterlist *sg; | ||
| 240 | |||
| 241 | hwif->sg_nents = ide_build_sglist(drive, rq); | ||
| 242 | if (hwif->sg_nents == 0) | ||
| 243 | return 0; | ||
| 244 | |||
| 245 | for_each_sg(hwif->sg_table, sg, hwif->sg_nents, i) { | ||
| 246 | u32 cur_addr, cur_len, bcount; | ||
| 247 | |||
| 248 | cur_addr = sg_dma_address(sg); | ||
| 249 | cur_len = sg_dma_len(sg); | ||
| 250 | |||
| 251 | /* | ||
| 252 | * Fill in the DMA table, without crossing any 64kB boundaries. | ||
| 253 | */ | ||
| 254 | |||
| 255 | while (cur_len) { | ||
| 256 | if (count++ >= PRD_ENTRIES) | ||
| 257 | goto use_pio_instead; | ||
| 258 | |||
| 259 | bcount = 0x10000 - (cur_addr & 0xffff); | ||
| 260 | if (bcount > cur_len) | ||
| 261 | bcount = cur_len; | ||
| 262 | *table++ = bcount & 0xffff; | ||
| 263 | *table++ = cur_addr; | ||
| 264 | cur_addr += bcount; | ||
| 265 | cur_len -= bcount; | ||
| 266 | } | ||
| 267 | } | ||
| 268 | |||
| 269 | if (count) { | ||
| 270 | *(table - 2) |= 0x80000000; | ||
| 271 | return count; | ||
| 272 | } | ||
| 273 | |||
| 274 | use_pio_instead: | ||
| 275 | printk(KERN_ERR "%s: %s\n", drive->name, | ||
| 276 | count ? "DMA table too small" : "empty DMA table?"); | ||
| 277 | |||
| 278 | ide_destroy_dmatable(drive); | ||
| 279 | |||
| 280 | return 0; /* revert to PIO for this request */ | ||
| 281 | } | ||
| 282 | #else | ||
| 283 | #define tx4939ide_build_dmatable ide_build_dmatable | ||
| 284 | #endif | ||
| 285 | |||
| 286 | static int tx4939ide_dma_setup(ide_drive_t *drive) | ||
| 287 | { | ||
| 288 | ide_hwif_t *hwif = drive->hwif; | ||
| 289 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 290 | struct request *rq = hwif->hwgroup->rq; | ||
| 291 | u8 reading; | ||
| 292 | int nent; | ||
| 293 | |||
| 294 | if (rq_data_dir(rq)) | ||
| 295 | reading = 0; | ||
| 296 | else | ||
| 297 | reading = ATA_DMA_WR; | ||
| 298 | |||
| 299 | /* fall back to PIO! */ | ||
| 300 | nent = tx4939ide_build_dmatable(drive, rq); | ||
| 301 | if (!nent) { | ||
| 302 | ide_map_sg(drive, rq); | ||
| 303 | return 1; | ||
| 304 | } | ||
| 305 | |||
| 306 | /* PRD table */ | ||
| 307 | tx4939ide_writel(hwif->dmatable_dma, base, TX4939IDE_PRD_Ptr); | ||
| 308 | |||
| 309 | /* specify r/w */ | ||
| 310 | tx4939ide_writeb(reading, base, TX4939IDE_DMA_Cmd); | ||
| 311 | |||
| 312 | /* clear INTR & ERROR flags */ | ||
| 313 | tx4939ide_clear_dma_status(base); | ||
| 314 | |||
| 315 | drive->waiting_for_dma = 1; | ||
| 316 | |||
| 317 | tx4939ide_writew(SECTOR_SIZE / 2, base, drive->dn ? | ||
| 318 | TX4939IDE_Xfer_Cnt_2 : TX4939IDE_Xfer_Cnt_1); | ||
| 319 | tx4939ide_writew(rq->nr_sectors, base, TX4939IDE_Sec_Cnt); | ||
| 320 | return 0; | ||
| 321 | } | ||
| 322 | |||
| 323 | static int tx4939ide_dma_end(ide_drive_t *drive) | ||
| 324 | { | ||
| 325 | ide_hwif_t *hwif = drive->hwif; | ||
| 326 | u8 dma_stat, dma_cmd; | ||
| 327 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 328 | u16 ctl = tx4939ide_readw(base, TX4939IDE_Int_Ctl); | ||
| 329 | |||
| 330 | drive->waiting_for_dma = 0; | ||
| 331 | |||
| 332 | /* get DMA command mode */ | ||
| 333 | dma_cmd = tx4939ide_readb(base, TX4939IDE_DMA_Cmd); | ||
| 334 | /* stop DMA */ | ||
| 335 | tx4939ide_writeb(dma_cmd & ~ATA_DMA_START, base, TX4939IDE_DMA_Cmd); | ||
| 336 | |||
| 337 | /* read and clear the INTR & ERROR bits */ | ||
| 338 | dma_stat = tx4939ide_clear_dma_status(base); | ||
| 339 | |||
| 340 | /* purge DMA mappings */ | ||
| 341 | ide_destroy_dmatable(drive); | ||
| 342 | /* verify good DMA status */ | ||
| 343 | wmb(); | ||
| 344 | |||
| 345 | if ((dma_stat & (ATA_DMA_INTR | ATA_DMA_ERR | ATA_DMA_ACTIVE)) == 0 && | ||
| 346 | (ctl & (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST)) == | ||
| 347 | (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST)) | ||
| 348 | /* INT_IDE lost... bug? */ | ||
| 349 | return 0; | ||
| 350 | return ((dma_stat & (ATA_DMA_INTR | ATA_DMA_ERR | ATA_DMA_ACTIVE)) != | ||
| 351 | ATA_DMA_INTR) ? 0x10 | dma_stat : 0; | ||
| 352 | } | ||
| 353 | |||
| 354 | /* returns 1 if DMA IRQ issued, 0 otherwise */ | ||
| 355 | static int tx4939ide_dma_test_irq(ide_drive_t *drive) | ||
| 356 | { | ||
| 357 | ide_hwif_t *hwif = drive->hwif; | ||
| 358 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 359 | u16 ctl, ide_int; | ||
| 360 | u8 dma_stat, stat; | ||
| 361 | int found = 0; | ||
| 362 | |||
| 363 | ctl = tx4939ide_check_error_ints(hwif); | ||
| 364 | ide_int = ctl & (TX4939IDE_INT_XFEREND | TX4939IDE_INT_HOST); | ||
| 365 | switch (ide_int) { | ||
| 366 | case TX4939IDE_INT_HOST: | ||
| 367 | /* On error, XFEREND might not be asserted. */ | ||
| 368 | stat = tx4939ide_readb(base, TX4939IDE_AltStat_DevCtl); | ||
| 369 | if ((stat & (ATA_BUSY | ATA_DRQ | ATA_ERR)) == ATA_ERR) | ||
| 370 | found = 1; | ||
| 371 | else | ||
| 372 | /* Wait for XFEREND (Mask HOST and unmask XFEREND) */ | ||
| 373 | ctl &= ~TX4939IDE_INT_XFEREND << 8; | ||
| 374 | ctl |= ide_int << 8; | ||
| 375 | break; | ||
| 376 | case TX4939IDE_INT_HOST | TX4939IDE_INT_XFEREND: | ||
| 377 | dma_stat = tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
| 378 | if (!(dma_stat & ATA_DMA_INTR)) | ||
| 379 | pr_warning("%s: weird interrupt status. " | ||
| 380 | "DMA_Stat %#02x int_ctl %#04x\n", | ||
| 381 | hwif->name, dma_stat, ctl); | ||
| 382 | found = 1; | ||
| 383 | break; | ||
| 384 | } | ||
| 385 | /* | ||
| 386 | * Do not clear XFEREND, HOST now. They will be cleared by | ||
| 387 | * clearing bit2 of DMA_Stat. | ||
| 388 | */ | ||
| 389 | ctl &= ~ide_int; | ||
| 390 | tx4939ide_writew(ctl, base, TX4939IDE_Int_Ctl); | ||
| 391 | return found; | ||
| 392 | } | ||
| 393 | |||
| 394 | static void tx4939ide_init_hwif(ide_hwif_t *hwif) | ||
| 395 | { | ||
| 396 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 397 | |||
| 398 | /* Soft Reset */ | ||
| 399 | tx4939ide_writew(0x8000, base, TX4939IDE_Sys_Ctl); | ||
| 400 | mmiowb(); | ||
| 401 | /* at least 20 GBUSCLK (typ. 100ns @ GBUS200MHz, max 450ns) */ | ||
| 402 | ndelay(450); | ||
| 403 | tx4939ide_writew(0x0000, base, TX4939IDE_Sys_Ctl); | ||
| 404 | /* mask some interrupts and clear all interrupts */ | ||
| 405 | tx4939ide_writew((TX4939IDE_IGNORE_INTS << 8) | 0xff, base, | ||
| 406 | TX4939IDE_Int_Ctl); | ||
| 407 | |||
| 408 | tx4939ide_writew(0x0008, base, TX4939IDE_Lo_Burst_Cnt); | ||
| 409 | tx4939ide_writew(0, base, TX4939IDE_Up_Burst_Cnt); | ||
| 410 | } | ||
| 411 | |||
| 412 | static int tx4939ide_init_dma(ide_hwif_t *hwif, const struct ide_port_info *d) | ||
| 413 | { | ||
| 414 | hwif->dma_base = | ||
| 415 | hwif->extra_base + tx4939ide_swizzleb(TX4939IDE_DMA_Cmd); | ||
| 416 | /* | ||
| 417 | * Note that we cannot use ATA_DMA_TABLE_OFS, ATA_DMA_STATUS | ||
| 418 | * for big endian. | ||
| 419 | */ | ||
| 420 | return ide_allocate_dma_engine(hwif); | ||
| 421 | } | ||
| 422 | |||
| 423 | static void tx4939ide_tf_load_fixup(ide_drive_t *drive, ide_task_t *task) | ||
| 424 | { | ||
| 425 | ide_hwif_t *hwif = drive->hwif; | ||
| 426 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 427 | u16 sysctl = hwif->select_data >> (drive->dn ? 16 : 0); | ||
| 428 | |||
| 429 | /* | ||
| 430 | * Fix ATA100 CORE System Control Register. (The write to the | ||
| 431 | * Device/Head register may write wrong data to the System | ||
| 432 | * Control Register) | ||
| 433 | * While Sys_Ctl is written here, selectproc is not needed. | ||
| 434 | */ | ||
| 435 | tx4939ide_writew(sysctl, base, TX4939IDE_Sys_Ctl); | ||
| 436 | } | ||
| 437 | |||
| 438 | #ifdef __BIG_ENDIAN | ||
| 439 | |||
| 440 | static u8 tx4939ide_read_sff_dma_status(ide_hwif_t *hwif) | ||
| 441 | { | ||
| 442 | void __iomem *base = TX4939IDE_BASE(hwif); | ||
| 443 | |||
| 444 | return tx4939ide_readb(base, TX4939IDE_DMA_Stat); | ||
| 445 | } | ||
| 446 | |||
| 447 | /* custom iops (independent from SWAP_IO_SPACE) */ | ||
| 448 | static u8 tx4939ide_inb(unsigned long port) | ||
| 449 | { | ||
| 450 | return __raw_readb((void __iomem *)port); | ||
| 451 | } | ||
| 452 | |||
| 453 | static void tx4939ide_outb(u8 value, unsigned long port) | ||
| 454 | { | ||
| 455 | __raw_writeb(value, (void __iomem *)port); | ||
| 456 | } | ||
| 457 | |||
| 458 | static void tx4939ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
| 459 | { | ||
| 460 | ide_hwif_t *hwif = drive->hwif; | ||
| 461 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
| 462 | struct ide_taskfile *tf = &task->tf; | ||
| 463 | u8 HIHI = task->tf_flags & IDE_TFLAG_LBA48 ? 0xE0 : 0xEF; | ||
| 464 | |||
| 465 | if (task->tf_flags & IDE_TFLAG_FLAGGED) | ||
| 466 | HIHI = 0xFF; | ||
| 467 | |||
| 468 | if (task->tf_flags & IDE_TFLAG_OUT_DATA) { | ||
| 469 | u16 data = (tf->hob_data << 8) | tf->data; | ||
| 470 | |||
| 471 | /* no endian swap */ | ||
| 472 | __raw_writew(data, (void __iomem *)io_ports->data_addr); | ||
| 473 | } | ||
| 474 | |||
| 475 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_FEATURE) | ||
| 476 | tx4939ide_outb(tf->hob_feature, io_ports->feature_addr); | ||
| 477 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_NSECT) | ||
| 478 | tx4939ide_outb(tf->hob_nsect, io_ports->nsect_addr); | ||
| 479 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAL) | ||
| 480 | tx4939ide_outb(tf->hob_lbal, io_ports->lbal_addr); | ||
| 481 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAM) | ||
| 482 | tx4939ide_outb(tf->hob_lbam, io_ports->lbam_addr); | ||
| 483 | if (task->tf_flags & IDE_TFLAG_OUT_HOB_LBAH) | ||
| 484 | tx4939ide_outb(tf->hob_lbah, io_ports->lbah_addr); | ||
| 485 | |||
| 486 | if (task->tf_flags & IDE_TFLAG_OUT_FEATURE) | ||
| 487 | tx4939ide_outb(tf->feature, io_ports->feature_addr); | ||
| 488 | if (task->tf_flags & IDE_TFLAG_OUT_NSECT) | ||
| 489 | tx4939ide_outb(tf->nsect, io_ports->nsect_addr); | ||
| 490 | if (task->tf_flags & IDE_TFLAG_OUT_LBAL) | ||
| 491 | tx4939ide_outb(tf->lbal, io_ports->lbal_addr); | ||
| 492 | if (task->tf_flags & IDE_TFLAG_OUT_LBAM) | ||
| 493 | tx4939ide_outb(tf->lbam, io_ports->lbam_addr); | ||
| 494 | if (task->tf_flags & IDE_TFLAG_OUT_LBAH) | ||
| 495 | tx4939ide_outb(tf->lbah, io_ports->lbah_addr); | ||
| 496 | |||
| 497 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) { | ||
| 498 | tx4939ide_outb((tf->device & HIHI) | drive->select, | ||
| 499 | io_ports->device_addr); | ||
| 500 | tx4939ide_tf_load_fixup(drive, task); | ||
| 501 | } | ||
| 502 | } | ||
| 503 | |||
| 504 | static void tx4939ide_tf_read(ide_drive_t *drive, ide_task_t *task) | ||
| 505 | { | ||
| 506 | ide_hwif_t *hwif = drive->hwif; | ||
| 507 | struct ide_io_ports *io_ports = &hwif->io_ports; | ||
| 508 | struct ide_taskfile *tf = &task->tf; | ||
| 509 | |||
| 510 | if (task->tf_flags & IDE_TFLAG_IN_DATA) { | ||
| 511 | u16 data; | ||
| 512 | |||
| 513 | /* no endian swap */ | ||
| 514 | data = __raw_readw((void __iomem *)io_ports->data_addr); | ||
| 515 | tf->data = data & 0xff; | ||
| 516 | tf->hob_data = (data >> 8) & 0xff; | ||
| 517 | } | ||
| 518 | |||
| 519 | /* be sure we're looking at the low order bits */ | ||
| 520 | tx4939ide_outb(ATA_DEVCTL_OBS & ~0x80, io_ports->ctl_addr); | ||
| 521 | |||
| 522 | if (task->tf_flags & IDE_TFLAG_IN_FEATURE) | ||
| 523 | tf->feature = tx4939ide_inb(io_ports->feature_addr); | ||
| 524 | if (task->tf_flags & IDE_TFLAG_IN_NSECT) | ||
| 525 | tf->nsect = tx4939ide_inb(io_ports->nsect_addr); | ||
| 526 | if (task->tf_flags & IDE_TFLAG_IN_LBAL) | ||
| 527 | tf->lbal = tx4939ide_inb(io_ports->lbal_addr); | ||
| 528 | if (task->tf_flags & IDE_TFLAG_IN_LBAM) | ||
| 529 | tf->lbam = tx4939ide_inb(io_ports->lbam_addr); | ||
| 530 | if (task->tf_flags & IDE_TFLAG_IN_LBAH) | ||
| 531 | tf->lbah = tx4939ide_inb(io_ports->lbah_addr); | ||
| 532 | if (task->tf_flags & IDE_TFLAG_IN_DEVICE) | ||
| 533 | tf->device = tx4939ide_inb(io_ports->device_addr); | ||
| 534 | |||
| 535 | if (task->tf_flags & IDE_TFLAG_LBA48) { | ||
| 536 | tx4939ide_outb(ATA_DEVCTL_OBS | 0x80, io_ports->ctl_addr); | ||
| 537 | |||
| 538 | if (task->tf_flags & IDE_TFLAG_IN_HOB_FEATURE) | ||
| 539 | tf->hob_feature = | ||
| 540 | tx4939ide_inb(io_ports->feature_addr); | ||
| 541 | if (task->tf_flags & IDE_TFLAG_IN_HOB_NSECT) | ||
| 542 | tf->hob_nsect = tx4939ide_inb(io_ports->nsect_addr); | ||
| 543 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAL) | ||
| 544 | tf->hob_lbal = tx4939ide_inb(io_ports->lbal_addr); | ||
| 545 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAM) | ||
| 546 | tf->hob_lbam = tx4939ide_inb(io_ports->lbam_addr); | ||
| 547 | if (task->tf_flags & IDE_TFLAG_IN_HOB_LBAH) | ||
| 548 | tf->hob_lbah = tx4939ide_inb(io_ports->lbah_addr); | ||
| 549 | } | ||
| 550 | } | ||
| 551 | |||
| 552 | static void tx4939ide_input_data_swap(ide_drive_t *drive, struct request *rq, | ||
| 553 | void *buf, unsigned int len) | ||
| 554 | { | ||
| 555 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
| 556 | unsigned short *ptr = buf; | ||
| 557 | unsigned int count = (len + 1) / 2; | ||
| 558 | |||
| 559 | while (count--) | ||
| 560 | *ptr++ = cpu_to_le16(__raw_readw((void __iomem *)port)); | ||
| 561 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
| 562 | } | ||
| 563 | |||
| 564 | static void tx4939ide_output_data_swap(ide_drive_t *drive, struct request *rq, | ||
| 565 | void *buf, unsigned int len) | ||
| 566 | { | ||
| 567 | unsigned long port = drive->hwif->io_ports.data_addr; | ||
| 568 | unsigned short *ptr = buf; | ||
| 569 | unsigned int count = (len + 1) / 2; | ||
| 570 | |||
| 571 | while (count--) { | ||
| 572 | __raw_writew(le16_to_cpu(*ptr), (void __iomem *)port); | ||
| 573 | ptr++; | ||
| 574 | } | ||
| 575 | __ide_flush_dcache_range((unsigned long)buf, count * 2); | ||
| 576 | } | ||
| 577 | |||
| 578 | static const struct ide_tp_ops tx4939ide_tp_ops = { | ||
| 579 | .exec_command = ide_exec_command, | ||
| 580 | .read_status = ide_read_status, | ||
| 581 | .read_altstatus = ide_read_altstatus, | ||
| 582 | .read_sff_dma_status = tx4939ide_read_sff_dma_status, | ||
| 583 | |||
| 584 | .set_irq = ide_set_irq, | ||
| 585 | |||
| 586 | .tf_load = tx4939ide_tf_load, | ||
| 587 | .tf_read = tx4939ide_tf_read, | ||
| 588 | |||
| 589 | .input_data = tx4939ide_input_data_swap, | ||
| 590 | .output_data = tx4939ide_output_data_swap, | ||
| 591 | }; | ||
| 592 | |||
| 593 | #else /* __LITTLE_ENDIAN */ | ||
| 594 | |||
| 595 | static void tx4939ide_tf_load(ide_drive_t *drive, ide_task_t *task) | ||
| 596 | { | ||
| 597 | ide_tf_load(drive, task); | ||
| 598 | if (task->tf_flags & IDE_TFLAG_OUT_DEVICE) | ||
| 599 | tx4939ide_tf_load_fixup(drive, task); | ||
| 600 | } | ||
| 601 | |||
| 602 | static const struct ide_tp_ops tx4939ide_tp_ops = { | ||
| 603 | .exec_command = ide_exec_command, | ||
| 604 | .read_status = ide_read_status, | ||
| 605 | .read_altstatus = ide_read_altstatus, | ||
| 606 | .read_sff_dma_status = ide_read_sff_dma_status, | ||
| 607 | |||
| 608 | .set_irq = ide_set_irq, | ||
| 609 | |||
| 610 | .tf_load = tx4939ide_tf_load, | ||
| 611 | .tf_read = ide_tf_read, | ||
| 612 | |||
| 613 | .input_data = ide_input_data, | ||
| 614 | .output_data = ide_output_data, | ||
| 615 | }; | ||
| 616 | |||
| 617 | #endif /* __LITTLE_ENDIAN */ | ||
| 618 | |||
| 619 | static const struct ide_port_ops tx4939ide_port_ops = { | ||
| 620 | .set_pio_mode = tx4939ide_set_pio_mode, | ||
| 621 | .set_dma_mode = tx4939ide_set_dma_mode, | ||
| 622 | .clear_irq = tx4939ide_clear_irq, | ||
| 623 | .cable_detect = tx4939ide_cable_detect, | ||
| 624 | }; | ||
| 625 | |||
| 626 | static const struct ide_dma_ops tx4939ide_dma_ops = { | ||
| 627 | .dma_host_set = tx4939ide_dma_host_set, | ||
| 628 | .dma_setup = tx4939ide_dma_setup, | ||
| 629 | .dma_exec_cmd = ide_dma_exec_cmd, | ||
| 630 | .dma_start = ide_dma_start, | ||
| 631 | .dma_end = tx4939ide_dma_end, | ||
| 632 | .dma_test_irq = tx4939ide_dma_test_irq, | ||
| 633 | .dma_lost_irq = ide_dma_lost_irq, | ||
| 634 | .dma_timeout = ide_dma_timeout, | ||
| 635 | }; | ||
| 636 | |||
| 637 | static const struct ide_port_info tx4939ide_port_info __initdata = { | ||
| 638 | .init_hwif = tx4939ide_init_hwif, | ||
| 639 | .init_dma = tx4939ide_init_dma, | ||
| 640 | .port_ops = &tx4939ide_port_ops, | ||
| 641 | .dma_ops = &tx4939ide_dma_ops, | ||
| 642 | .tp_ops = &tx4939ide_tp_ops, | ||
| 643 | .host_flags = IDE_HFLAG_MMIO, | ||
| 644 | .pio_mask = ATA_PIO4, | ||
| 645 | .mwdma_mask = ATA_MWDMA2, | ||
| 646 | .udma_mask = ATA_UDMA5, | ||
| 647 | }; | ||
| 648 | |||
| 649 | static int __init tx4939ide_probe(struct platform_device *pdev) | ||
| 650 | { | ||
| 651 | hw_regs_t hw; | ||
| 652 | hw_regs_t *hws[] = { &hw, NULL, NULL, NULL }; | ||
| 653 | struct ide_host *host; | ||
| 654 | struct resource *res; | ||
| 655 | int irq, ret; | ||
| 656 | unsigned long mapbase; | ||
| 657 | |||
| 658 | irq = platform_get_irq(pdev, 0); | ||
| 659 | if (irq < 0) | ||
| 660 | return -ENODEV; | ||
| 661 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | ||
| 662 | if (!res) | ||
| 663 | return -ENODEV; | ||
| 664 | |||
| 665 | if (!devm_request_mem_region(&pdev->dev, res->start, | ||
| 666 | res->end - res->start + 1, "tx4938ide")) | ||
| 667 | return -EBUSY; | ||
| 668 | mapbase = (unsigned long)devm_ioremap(&pdev->dev, res->start, | ||
| 669 | res->end - res->start + 1); | ||
| 670 | if (!mapbase) | ||
| 671 | return -EBUSY; | ||
| 672 | memset(&hw, 0, sizeof(hw)); | ||
| 673 | hw.io_ports.data_addr = | ||
| 674 | mapbase + tx4939ide_swizzlew(TX4939IDE_Data); | ||
| 675 | hw.io_ports.error_addr = | ||
| 676 | mapbase + tx4939ide_swizzleb(TX4939IDE_Error_Feature); | ||
| 677 | hw.io_ports.nsect_addr = | ||
| 678 | mapbase + tx4939ide_swizzleb(TX4939IDE_Sec); | ||
| 679 | hw.io_ports.lbal_addr = | ||
| 680 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA0); | ||
| 681 | hw.io_ports.lbam_addr = | ||
| 682 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA1); | ||
| 683 | hw.io_ports.lbah_addr = | ||
| 684 | mapbase + tx4939ide_swizzleb(TX4939IDE_LBA2); | ||
| 685 | hw.io_ports.device_addr = | ||
| 686 | mapbase + tx4939ide_swizzleb(TX4939IDE_DevHead); | ||
| 687 | hw.io_ports.command_addr = | ||
| 688 | mapbase + tx4939ide_swizzleb(TX4939IDE_Stat_Cmd); | ||
| 689 | hw.io_ports.ctl_addr = | ||
| 690 | mapbase + tx4939ide_swizzleb(TX4939IDE_AltStat_DevCtl); | ||
| 691 | hw.irq = irq; | ||
| 692 | hw.dev = &pdev->dev; | ||
| 693 | |||
| 694 | pr_info("TX4939 IDE interface (base %#lx, irq %d)\n", mapbase, irq); | ||
| 695 | host = ide_host_alloc(&tx4939ide_port_info, hws); | ||
| 696 | if (!host) | ||
| 697 | return -ENOMEM; | ||
| 698 | /* use extra_base for base address of the all registers */ | ||
| 699 | host->ports[0]->extra_base = mapbase; | ||
| 700 | ret = ide_host_register(host, &tx4939ide_port_info, hws); | ||
| 701 | if (ret) { | ||
| 702 | ide_host_free(host); | ||
| 703 | return ret; | ||
| 704 | } | ||
| 705 | platform_set_drvdata(pdev, host); | ||
| 706 | return 0; | ||
| 707 | } | ||
| 708 | |||
| 709 | static int __exit tx4939ide_remove(struct platform_device *pdev) | ||
| 710 | { | ||
| 711 | struct ide_host *host = platform_get_drvdata(pdev); | ||
| 712 | |||
| 713 | ide_host_remove(host); | ||
| 714 | return 0; | ||
| 715 | } | ||
| 716 | |||
| 717 | #ifdef CONFIG_PM | ||
| 718 | static int tx4939ide_resume(struct platform_device *dev) | ||
| 719 | { | ||
| 720 | struct ide_host *host = platform_get_drvdata(dev); | ||
| 721 | ide_hwif_t *hwif = host->ports[0]; | ||
| 722 | |||
| 723 | tx4939ide_init_hwif(hwif); | ||
| 724 | return 0; | ||
| 725 | } | ||
| 726 | #else | ||
| 727 | #define tx4939ide_resume NULL | ||
| 728 | #endif | ||
| 729 | |||
| 730 | static struct platform_driver tx4939ide_driver = { | ||
| 731 | .driver = { | ||
| 732 | .name = MODNAME, | ||
| 733 | .owner = THIS_MODULE, | ||
| 734 | }, | ||
| 735 | .remove = __exit_p(tx4939ide_remove), | ||
| 736 | .resume = tx4939ide_resume, | ||
| 737 | }; | ||
| 738 | |||
| 739 | static int __init tx4939ide_init(void) | ||
| 740 | { | ||
| 741 | return platform_driver_probe(&tx4939ide_driver, tx4939ide_probe); | ||
| 742 | } | ||
| 743 | |||
| 744 | static void __exit tx4939ide_exit(void) | ||
| 745 | { | ||
| 746 | platform_driver_unregister(&tx4939ide_driver); | ||
| 747 | } | ||
| 748 | |||
| 749 | module_init(tx4939ide_init); | ||
| 750 | module_exit(tx4939ide_exit); | ||
| 751 | |||
| 752 | MODULE_DESCRIPTION("TX4939 internal IDE driver"); | ||
| 753 | MODULE_LICENSE("GPL"); | ||
| 754 | MODULE_ALIAS("platform:tx4939ide"); | ||
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig index 8317fdef1691..3d1ab8fa9acc 100644 --- a/drivers/input/touchscreen/Kconfig +++ b/drivers/input/touchscreen/Kconfig | |||
| @@ -42,8 +42,9 @@ config TOUCHSCREEN_BITSY | |||
| 42 | module will be called h3600_ts_input. | 42 | module will be called h3600_ts_input. |
| 43 | 43 | ||
| 44 | config TOUCHSCREEN_CORGI | 44 | config TOUCHSCREEN_CORGI |
| 45 | tristate "SharpSL (Corgi and Spitz series) touchscreen driver" | 45 | tristate "SharpSL (Corgi and Spitz series) touchscreen driver (DEPRECATED)" |
| 46 | depends on PXA_SHARPSL | 46 | depends on PXA_SHARPSL |
| 47 | select CORGI_SSP_DEPRECATED | ||
| 47 | default y | 48 | default y |
| 48 | help | 49 | help |
| 49 | Say Y here to enable the driver for the touchscreen on the | 50 | Say Y here to enable the driver for the touchscreen on the |
| @@ -54,6 +55,9 @@ config TOUCHSCREEN_CORGI | |||
| 54 | To compile this driver as a module, choose M here: the | 55 | To compile this driver as a module, choose M here: the |
| 55 | module will be called corgi_ts. | 56 | module will be called corgi_ts. |
| 56 | 57 | ||
| 58 | NOTE: this driver is deprecated, try enable SPI and generic | ||
| 59 | ADS7846-based touchscreen driver. | ||
| 60 | |||
| 57 | config TOUCHSCREEN_FUJITSU | 61 | config TOUCHSCREEN_FUJITSU |
| 58 | tristate "Fujitsu serial touchscreen" | 62 | tristate "Fujitsu serial touchscreen" |
| 59 | select SERIO | 63 | select SERIO |
diff --git a/drivers/leds/Kconfig b/drivers/leds/Kconfig index c7ff1e11ea85..e7fb7d2fcbfc 100644 --- a/drivers/leds/Kconfig +++ b/drivers/leds/Kconfig | |||
| @@ -113,11 +113,12 @@ config LEDS_GPIO | |||
| 113 | outputs. To be useful the particular board must have LEDs | 113 | outputs. To be useful the particular board must have LEDs |
| 114 | and they must be connected to the GPIO lines. | 114 | and they must be connected to the GPIO lines. |
| 115 | 115 | ||
| 116 | config LEDS_CM_X270 | 116 | config LEDS_HP_DISK |
| 117 | tristate "LED Support for the CM-X270 LEDs" | 117 | tristate "LED Support for disk protection LED on HP notebooks" |
| 118 | depends on LEDS_CLASS && MACH_ARMCORE | 118 | depends on LEDS_CLASS && ACPI |
| 119 | help | 119 | help |
| 120 | This option enables support for the CM-X270 LEDs. | 120 | This option enable support for disk protection LED, found on |
| 121 | newer HP notebooks. | ||
| 121 | 122 | ||
| 122 | config LEDS_CLEVO_MAIL | 123 | config LEDS_CLEVO_MAIL |
| 123 | tristate "Mail LED on Clevo notebook (EXPERIMENTAL)" | 124 | tristate "Mail LED on Clevo notebook (EXPERIMENTAL)" |
| @@ -157,6 +158,13 @@ config LEDS_PCA955X | |||
| 157 | LED driver chips accessed via the I2C bus. Supported | 158 | LED driver chips accessed via the I2C bus. Supported |
| 158 | devices include PCA9550, PCA9551, PCA9552, and PCA9553. | 159 | devices include PCA9550, PCA9551, PCA9552, and PCA9553. |
| 159 | 160 | ||
| 161 | config LEDS_DA903X | ||
| 162 | tristate "LED Support for DA9030/DA9034 PMIC" | ||
| 163 | depends on LEDS_CLASS && PMIC_DA903X | ||
| 164 | help | ||
| 165 | This option enables support for on-chip LED drivers found | ||
| 166 | on Dialog Semiconductor DA9030/DA9034 PMICs. | ||
| 167 | |||
| 160 | comment "LED Triggers" | 168 | comment "LED Triggers" |
| 161 | 169 | ||
| 162 | config LEDS_TRIGGERS | 170 | config LEDS_TRIGGERS |
| @@ -193,6 +201,15 @@ config LEDS_TRIGGER_HEARTBEAT | |||
| 193 | load average. | 201 | load average. |
| 194 | If unsure, say Y. | 202 | If unsure, say Y. |
| 195 | 203 | ||
| 204 | config LEDS_TRIGGER_BACKLIGHT | ||
| 205 | tristate "LED backlight Trigger" | ||
| 206 | depends on LEDS_TRIGGERS | ||
| 207 | help | ||
| 208 | This allows LEDs to be controlled as a backlight device: they | ||
| 209 | turn off and on when the display is blanked and unblanked. | ||
| 210 | |||
| 211 | If unsure, say N. | ||
| 212 | |||
| 196 | config LEDS_TRIGGER_DEFAULT_ON | 213 | config LEDS_TRIGGER_DEFAULT_ON |
| 197 | tristate "LED Default ON Trigger" | 214 | tristate "LED Default ON Trigger" |
| 198 | depends on LEDS_TRIGGERS | 215 | depends on LEDS_TRIGGERS |
diff --git a/drivers/leds/Makefile b/drivers/leds/Makefile index eb186c351a1c..e1967a29850e 100644 --- a/drivers/leds/Makefile +++ b/drivers/leds/Makefile | |||
| @@ -17,14 +17,16 @@ obj-$(CONFIG_LEDS_COBALT_RAQ) += leds-cobalt-raq.o | |||
| 17 | obj-$(CONFIG_LEDS_SUNFIRE) += leds-sunfire.o | 17 | obj-$(CONFIG_LEDS_SUNFIRE) += leds-sunfire.o |
| 18 | obj-$(CONFIG_LEDS_PCA9532) += leds-pca9532.o | 18 | obj-$(CONFIG_LEDS_PCA9532) += leds-pca9532.o |
| 19 | obj-$(CONFIG_LEDS_GPIO) += leds-gpio.o | 19 | obj-$(CONFIG_LEDS_GPIO) += leds-gpio.o |
| 20 | obj-$(CONFIG_LEDS_CM_X270) += leds-cm-x270.o | ||
| 21 | obj-$(CONFIG_LEDS_CLEVO_MAIL) += leds-clevo-mail.o | 20 | obj-$(CONFIG_LEDS_CLEVO_MAIL) += leds-clevo-mail.o |
| 22 | obj-$(CONFIG_LEDS_HP6XX) += leds-hp6xx.o | 21 | obj-$(CONFIG_LEDS_HP6XX) += leds-hp6xx.o |
| 23 | obj-$(CONFIG_LEDS_FSG) += leds-fsg.o | 22 | obj-$(CONFIG_LEDS_FSG) += leds-fsg.o |
| 24 | obj-$(CONFIG_LEDS_PCA955X) += leds-pca955x.o | 23 | obj-$(CONFIG_LEDS_PCA955X) += leds-pca955x.o |
| 24 | obj-$(CONFIG_LEDS_DA903X) += leds-da903x.o | ||
| 25 | obj-$(CONFIG_LEDS_HP_DISK) += leds-hp-disk.o | ||
| 25 | 26 | ||
| 26 | # LED Triggers | 27 | # LED Triggers |
| 27 | obj-$(CONFIG_LEDS_TRIGGER_TIMER) += ledtrig-timer.o | 28 | obj-$(CONFIG_LEDS_TRIGGER_TIMER) += ledtrig-timer.o |
| 28 | obj-$(CONFIG_LEDS_TRIGGER_IDE_DISK) += ledtrig-ide-disk.o | 29 | obj-$(CONFIG_LEDS_TRIGGER_IDE_DISK) += ledtrig-ide-disk.o |
| 29 | obj-$(CONFIG_LEDS_TRIGGER_HEARTBEAT) += ledtrig-heartbeat.o | 30 | obj-$(CONFIG_LEDS_TRIGGER_HEARTBEAT) += ledtrig-heartbeat.o |
| 31 | obj-$(CONFIG_LEDS_TRIGGER_BACKLIGHT) += ledtrig-backlight.o | ||
| 30 | obj-$(CONFIG_LEDS_TRIGGER_DEFAULT_ON) += ledtrig-default-on.o | 32 | obj-$(CONFIG_LEDS_TRIGGER_DEFAULT_ON) += ledtrig-default-on.o |
diff --git a/drivers/leds/led-class.c b/drivers/leds/led-class.c index ee74ee7b2acc..6c4a326176d7 100644 --- a/drivers/leds/led-class.c +++ b/drivers/leds/led-class.c | |||
| @@ -34,14 +34,11 @@ static ssize_t led_brightness_show(struct device *dev, | |||
| 34 | struct device_attribute *attr, char *buf) | 34 | struct device_attribute *attr, char *buf) |
| 35 | { | 35 | { |
| 36 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 36 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
| 37 | ssize_t ret = 0; | ||
| 38 | 37 | ||
| 39 | /* no lock needed for this */ | 38 | /* no lock needed for this */ |
| 40 | led_update_brightness(led_cdev); | 39 | led_update_brightness(led_cdev); |
| 41 | sprintf(buf, "%u\n", led_cdev->brightness); | ||
| 42 | ret = strlen(buf) + 1; | ||
| 43 | 40 | ||
| 44 | return ret; | 41 | return sprintf(buf, "%u\n", led_cdev->brightness); |
| 45 | } | 42 | } |
| 46 | 43 | ||
| 47 | static ssize_t led_brightness_store(struct device *dev, | 44 | static ssize_t led_brightness_store(struct device *dev, |
| @@ -113,6 +110,9 @@ int led_classdev_register(struct device *parent, struct led_classdev *led_cdev) | |||
| 113 | if (rc) | 110 | if (rc) |
| 114 | goto err_out; | 111 | goto err_out; |
| 115 | 112 | ||
| 113 | #ifdef CONFIG_LEDS_TRIGGERS | ||
| 114 | init_rwsem(&led_cdev->trigger_lock); | ||
| 115 | #endif | ||
| 116 | /* add to the list of leds */ | 116 | /* add to the list of leds */ |
| 117 | down_write(&leds_list_lock); | 117 | down_write(&leds_list_lock); |
| 118 | list_add_tail(&led_cdev->node, &leds_list); | 118 | list_add_tail(&led_cdev->node, &leds_list); |
| @@ -121,8 +121,6 @@ int led_classdev_register(struct device *parent, struct led_classdev *led_cdev) | |||
| 121 | led_update_brightness(led_cdev); | 121 | led_update_brightness(led_cdev); |
| 122 | 122 | ||
| 123 | #ifdef CONFIG_LEDS_TRIGGERS | 123 | #ifdef CONFIG_LEDS_TRIGGERS |
| 124 | init_rwsem(&led_cdev->trigger_lock); | ||
| 125 | |||
| 126 | rc = device_create_file(led_cdev->dev, &dev_attr_trigger); | 124 | rc = device_create_file(led_cdev->dev, &dev_attr_trigger); |
| 127 | if (rc) | 125 | if (rc) |
| 128 | goto err_out_led_list; | 126 | goto err_out_led_list; |
| @@ -147,7 +145,7 @@ err_out: | |||
| 147 | EXPORT_SYMBOL_GPL(led_classdev_register); | 145 | EXPORT_SYMBOL_GPL(led_classdev_register); |
| 148 | 146 | ||
| 149 | /** | 147 | /** |
| 150 | * __led_classdev_unregister - unregisters a object of led_properties class. | 148 | * led_classdev_unregister - unregisters a object of led_properties class. |
| 151 | * @led_cdev: the led device to unregister | 149 | * @led_cdev: the led device to unregister |
| 152 | * | 150 | * |
| 153 | * Unregisters a previously registered via led_classdev_register object. | 151 | * Unregisters a previously registered via led_classdev_register object. |
diff --git a/drivers/leds/leds-ams-delta.c b/drivers/leds/leds-ams-delta.c index 32c98b2efa3f..1bd590bb3a6e 100644 --- a/drivers/leds/leds-ams-delta.c +++ b/drivers/leds/leds-ams-delta.c | |||
| @@ -107,27 +107,27 @@ static int ams_delta_led_resume(struct platform_device *dev) | |||
| 107 | 107 | ||
| 108 | static int ams_delta_led_probe(struct platform_device *pdev) | 108 | static int ams_delta_led_probe(struct platform_device *pdev) |
| 109 | { | 109 | { |
| 110 | int i; | 110 | int i, ret; |
| 111 | int ret; | ||
| 112 | 111 | ||
| 113 | for (i = ret = 0; ret >= 0 && i < ARRAY_SIZE(ams_delta_leds); i++) { | 112 | for (i = 0; i < ARRAY_SIZE(ams_delta_leds); i++) { |
| 114 | ret = led_classdev_register(&pdev->dev, | 113 | ret = led_classdev_register(&pdev->dev, |
| 115 | &ams_delta_leds[i].cdev); | 114 | &ams_delta_leds[i].cdev); |
| 115 | if (ret < 0) | ||
| 116 | goto fail; | ||
| 116 | } | 117 | } |
| 117 | 118 | ||
| 118 | if (ret < 0 && i > 1) { | 119 | return 0; |
| 119 | for (i = i - 2; i >= 0; i--) | 120 | fail: |
| 120 | led_classdev_unregister(&ams_delta_leds[i].cdev); | 121 | while (--i >= 0) |
| 121 | } | 122 | led_classdev_unregister(&ams_delta_leds[i].cdev); |
| 122 | 123 | return ret; | |
| 123 | return ret; | ||
| 124 | } | 124 | } |
| 125 | 125 | ||
| 126 | static int ams_delta_led_remove(struct platform_device *pdev) | 126 | static int ams_delta_led_remove(struct platform_device *pdev) |
| 127 | { | 127 | { |
| 128 | int i; | 128 | int i; |
| 129 | 129 | ||
| 130 | for (i = ARRAY_SIZE(ams_delta_leds) - 1; i >= 0; i--) | 130 | for (i = 0; i < ARRAY_SIZE(ams_delta_leds); i--) |
| 131 | led_classdev_unregister(&ams_delta_leds[i].cdev); | 131 | led_classdev_unregister(&ams_delta_leds[i].cdev); |
| 132 | 132 | ||
| 133 | return 0; | 133 | return 0; |
diff --git a/drivers/leds/leds-cm-x270.c b/drivers/leds/leds-cm-x270.c deleted file mode 100644 index 836a43d776e6..000000000000 --- a/drivers/leds/leds-cm-x270.c +++ /dev/null | |||
| @@ -1,124 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * drivers/leds/leds-cm-x270.c | ||
| 3 | * | ||
| 4 | * Copyright 2007 CompuLab Ltd. | ||
| 5 | * Author: Mike Rapoport <mike@compulab.co.il> | ||
| 6 | * | ||
| 7 | * Based on leds-corgi.c | ||
| 8 | * Author: Richard Purdie <rpurdie@openedhand.com> | ||
| 9 | * | ||
| 10 | * This program is free software; you can redistribute it and/or modify | ||
| 11 | * it under the terms of the GNU General Public License version 2 as | ||
| 12 | * published by the Free Software Foundation. | ||
| 13 | * | ||
| 14 | */ | ||
| 15 | |||
| 16 | #include <linux/kernel.h> | ||
| 17 | #include <linux/init.h> | ||
| 18 | #include <linux/platform_device.h> | ||
| 19 | #include <linux/leds.h> | ||
| 20 | |||
| 21 | #include <mach/hardware.h> | ||
| 22 | #include <mach/pxa-regs.h> | ||
| 23 | |||
| 24 | #define GPIO_RED_LED (93) | ||
| 25 | #define GPIO_GREEN_LED (94) | ||
| 26 | |||
| 27 | static void cmx270_red_set(struct led_classdev *led_cdev, | ||
| 28 | enum led_brightness value) | ||
| 29 | { | ||
| 30 | if (value) | ||
| 31 | GPCR(GPIO_RED_LED) = GPIO_bit(GPIO_RED_LED); | ||
| 32 | else | ||
| 33 | GPSR(GPIO_RED_LED) = GPIO_bit(GPIO_RED_LED); | ||
| 34 | } | ||
| 35 | |||
| 36 | static void cmx270_green_set(struct led_classdev *led_cdev, | ||
| 37 | enum led_brightness value) | ||
| 38 | { | ||
| 39 | if (value) | ||
| 40 | GPCR(GPIO_GREEN_LED) = GPIO_bit(GPIO_GREEN_LED); | ||
| 41 | else | ||
| 42 | GPSR(GPIO_GREEN_LED) = GPIO_bit(GPIO_GREEN_LED); | ||
| 43 | } | ||
| 44 | |||
| 45 | static struct led_classdev cmx270_red_led = { | ||
| 46 | .name = "cm-x270:red", | ||
| 47 | .default_trigger = "nand-disk", | ||
| 48 | .brightness_set = cmx270_red_set, | ||
| 49 | }; | ||
| 50 | |||
| 51 | static struct led_classdev cmx270_green_led = { | ||
| 52 | .name = "cm-x270:green", | ||
| 53 | .default_trigger = "heartbeat", | ||
| 54 | .brightness_set = cmx270_green_set, | ||
| 55 | }; | ||
| 56 | |||
| 57 | #ifdef CONFIG_PM | ||
| 58 | static int cmx270led_suspend(struct platform_device *dev, pm_message_t state) | ||
| 59 | { | ||
| 60 | led_classdev_suspend(&cmx270_red_led); | ||
| 61 | led_classdev_suspend(&cmx270_green_led); | ||
| 62 | return 0; | ||
| 63 | } | ||
| 64 | |||
| 65 | static int cmx270led_resume(struct platform_device *dev) | ||
| 66 | { | ||
| 67 | led_classdev_resume(&cmx270_red_led); | ||
| 68 | led_classdev_resume(&cmx270_green_led); | ||
| 69 | return 0; | ||
| 70 | } | ||
| 71 | #endif | ||
| 72 | |||
| 73 | static int cmx270led_probe(struct platform_device *pdev) | ||
| 74 | { | ||
| 75 | int ret; | ||
| 76 | |||
| 77 | ret = led_classdev_register(&pdev->dev, &cmx270_red_led); | ||
| 78 | if (ret < 0) | ||
| 79 | return ret; | ||
| 80 | |||
| 81 | ret = led_classdev_register(&pdev->dev, &cmx270_green_led); | ||
| 82 | if (ret < 0) | ||
| 83 | led_classdev_unregister(&cmx270_red_led); | ||
| 84 | |||
| 85 | return ret; | ||
| 86 | } | ||
| 87 | |||
| 88 | static int cmx270led_remove(struct platform_device *pdev) | ||
| 89 | { | ||
| 90 | led_classdev_unregister(&cmx270_red_led); | ||
| 91 | led_classdev_unregister(&cmx270_green_led); | ||
| 92 | return 0; | ||
| 93 | } | ||
| 94 | |||
| 95 | static struct platform_driver cmx270led_driver = { | ||
| 96 | .probe = cmx270led_probe, | ||
| 97 | .remove = cmx270led_remove, | ||
| 98 | #ifdef CONFIG_PM | ||
| 99 | .suspend = cmx270led_suspend, | ||
| 100 | .resume = cmx270led_resume, | ||
| 101 | #endif | ||
| 102 | .driver = { | ||
| 103 | .name = "cm-x270-led", | ||
| 104 | .owner = THIS_MODULE, | ||
| 105 | }, | ||
| 106 | }; | ||
| 107 | |||
| 108 | static int __init cmx270led_init(void) | ||
| 109 | { | ||
| 110 | return platform_driver_register(&cmx270led_driver); | ||
| 111 | } | ||
| 112 | |||
| 113 | static void __exit cmx270led_exit(void) | ||
| 114 | { | ||
| 115 | platform_driver_unregister(&cmx270led_driver); | ||
| 116 | } | ||
| 117 | |||
| 118 | module_init(cmx270led_init); | ||
| 119 | module_exit(cmx270led_exit); | ||
| 120 | |||
| 121 | MODULE_AUTHOR("Mike Rapoport <mike@compulab.co.il>"); | ||
| 122 | MODULE_DESCRIPTION("CM-x270 LED driver"); | ||
| 123 | MODULE_LICENSE("GPL"); | ||
| 124 | MODULE_ALIAS("platform:cm-x270-led"); | ||
diff --git a/drivers/leds/leds-da903x.c b/drivers/leds/leds-da903x.c new file mode 100644 index 000000000000..f1fddb18d70d --- /dev/null +++ b/drivers/leds/leds-da903x.c | |||
| @@ -0,0 +1,175 @@ | |||
| 1 | /* | ||
| 2 | * LEDs driver for Dialog Semiconductor DA9030/DA9034 | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Compulab, Ltd. | ||
| 5 | * Mike Rapoport <mike@compulab.co.il> | ||
| 6 | * | ||
| 7 | * Copyright (C) 2006-2008 Marvell International Ltd. | ||
| 8 | * Eric Miao <eric.miao@marvell.com> | ||
| 9 | * | ||
| 10 | * This program is free software; you can redistribute it and/or modify | ||
| 11 | * it under the terms of the GNU General Public License version 2 as | ||
| 12 | * published by the Free Software Foundation. | ||
| 13 | */ | ||
| 14 | |||
| 15 | #include <linux/module.h> | ||
| 16 | #include <linux/kernel.h> | ||
| 17 | #include <linux/init.h> | ||
| 18 | #include <linux/platform_device.h> | ||
| 19 | #include <linux/leds.h> | ||
| 20 | #include <linux/mfd/da903x.h> | ||
| 21 | |||
| 22 | #define DA9030_LED1_CONTROL 0x20 | ||
| 23 | #define DA9030_LED2_CONTROL 0x21 | ||
| 24 | #define DA9030_LED3_CONTROL 0x22 | ||
| 25 | #define DA9030_LED4_CONTROL 0x23 | ||
| 26 | #define DA9030_LEDPC_CONTROL 0x24 | ||
| 27 | #define DA9030_MISC_CONTROL_A 0x26 /* Vibrator Control */ | ||
| 28 | |||
| 29 | #define DA9034_LED1_CONTROL 0x35 | ||
| 30 | #define DA9034_LED2_CONTROL 0x36 | ||
| 31 | #define DA9034_VIBRA 0x40 | ||
| 32 | |||
| 33 | struct da903x_led { | ||
| 34 | struct led_classdev cdev; | ||
| 35 | struct work_struct work; | ||
| 36 | struct device *master; | ||
| 37 | enum led_brightness new_brightness; | ||
| 38 | int id; | ||
| 39 | int flags; | ||
| 40 | }; | ||
| 41 | |||
| 42 | #define DA9030_LED_OFFSET(id) ((id) - DA9030_ID_LED_1) | ||
| 43 | #define DA9034_LED_OFFSET(id) ((id) - DA9034_ID_LED_1) | ||
| 44 | |||
| 45 | static void da903x_led_work(struct work_struct *work) | ||
| 46 | { | ||
| 47 | struct da903x_led *led = container_of(work, struct da903x_led, work); | ||
| 48 | uint8_t val; | ||
| 49 | int offset; | ||
| 50 | |||
| 51 | switch (led->id) { | ||
| 52 | case DA9030_ID_LED_1: | ||
| 53 | case DA9030_ID_LED_2: | ||
| 54 | case DA9030_ID_LED_3: | ||
| 55 | case DA9030_ID_LED_4: | ||
| 56 | case DA9030_ID_LED_PC: | ||
| 57 | offset = DA9030_LED_OFFSET(led->id); | ||
| 58 | val = led->flags & ~0x87; | ||
| 59 | val |= (led->new_brightness) ? 0x80 : 0; /* EN bit */ | ||
| 60 | val |= (led->new_brightness >> 5) & 0x7; /* PWM<2:0> */ | ||
| 61 | da903x_write(led->master, DA9030_LED1_CONTROL + offset, val); | ||
| 62 | break; | ||
| 63 | case DA9030_ID_VIBRA: | ||
| 64 | val = led->flags & ~0x80; | ||
| 65 | val |= (led->new_brightness) ? 0x80 : 0; /* EN bit */ | ||
| 66 | da903x_write(led->master, DA9030_MISC_CONTROL_A, val); | ||
| 67 | break; | ||
| 68 | case DA9034_ID_LED_1: | ||
| 69 | case DA9034_ID_LED_2: | ||
| 70 | offset = DA9034_LED_OFFSET(led->id); | ||
| 71 | val = (led->new_brightness * 0x5f / LED_FULL) & 0x7f; | ||
| 72 | val |= (led->flags & DA9034_LED_RAMP) ? 0x80 : 0; | ||
| 73 | da903x_write(led->master, DA9034_LED1_CONTROL + offset, val); | ||
| 74 | break; | ||
| 75 | case DA9034_ID_VIBRA: | ||
| 76 | val = led->new_brightness & 0xfe; | ||
| 77 | da903x_write(led->master, DA9034_VIBRA, val); | ||
| 78 | break; | ||
| 79 | } | ||
| 80 | } | ||
| 81 | |||
| 82 | static void da903x_led_set(struct led_classdev *led_cdev, | ||
| 83 | enum led_brightness value) | ||
| 84 | { | ||
| 85 | struct da903x_led *led; | ||
| 86 | |||
| 87 | led = container_of(led_cdev, struct da903x_led, cdev); | ||
| 88 | led->new_brightness = value; | ||
| 89 | schedule_work(&led->work); | ||
| 90 | } | ||
| 91 | |||
| 92 | static int __devinit da903x_led_probe(struct platform_device *pdev) | ||
| 93 | { | ||
| 94 | struct led_info *pdata = pdev->dev.platform_data; | ||
| 95 | struct da903x_led *led; | ||
| 96 | int id, ret; | ||
| 97 | |||
| 98 | if (pdata == NULL) | ||
| 99 | return 0; | ||
| 100 | |||
| 101 | id = pdev->id; | ||
| 102 | |||
| 103 | if (!((id >= DA9030_ID_LED_1 && id <= DA9030_ID_VIBRA) || | ||
| 104 | (id >= DA9034_ID_LED_1 && id <= DA9034_ID_VIBRA))) { | ||
| 105 | dev_err(&pdev->dev, "invalid LED ID (%d) specified\n", id); | ||
| 106 | return -EINVAL; | ||
| 107 | } | ||
| 108 | |||
| 109 | led = kzalloc(sizeof(struct da903x_led), GFP_KERNEL); | ||
| 110 | if (led == NULL) { | ||
| 111 | dev_err(&pdev->dev, "failed to alloc memory for LED%d\n", id); | ||
| 112 | return -ENOMEM; | ||
| 113 | } | ||
| 114 | |||
| 115 | led->cdev.name = pdata->name; | ||
| 116 | led->cdev.default_trigger = pdata->default_trigger; | ||
| 117 | led->cdev.brightness_set = da903x_led_set; | ||
| 118 | led->cdev.brightness = LED_OFF; | ||
| 119 | |||
| 120 | led->id = id; | ||
| 121 | led->flags = pdata->flags; | ||
| 122 | led->master = pdev->dev.parent; | ||
| 123 | led->new_brightness = LED_OFF; | ||
| 124 | |||
| 125 | INIT_WORK(&led->work, da903x_led_work); | ||
| 126 | |||
| 127 | ret = led_classdev_register(led->master, &led->cdev); | ||
| 128 | if (ret) { | ||
| 129 | dev_err(&pdev->dev, "failed to register LED %d\n", id); | ||
| 130 | goto err; | ||
| 131 | } | ||
| 132 | |||
| 133 | platform_set_drvdata(pdev, led); | ||
| 134 | return 0; | ||
| 135 | |||
| 136 | err: | ||
| 137 | kfree(led); | ||
| 138 | return ret; | ||
| 139 | } | ||
| 140 | |||
| 141 | static int __devexit da903x_led_remove(struct platform_device *pdev) | ||
| 142 | { | ||
| 143 | struct da903x_led *led = platform_get_drvdata(pdev); | ||
| 144 | |||
| 145 | led_classdev_unregister(&led->cdev); | ||
| 146 | kfree(led); | ||
| 147 | return 0; | ||
| 148 | } | ||
| 149 | |||
| 150 | static struct platform_driver da903x_led_driver = { | ||
| 151 | .driver = { | ||
| 152 | .name = "da903x-led", | ||
| 153 | .owner = THIS_MODULE, | ||
| 154 | }, | ||
| 155 | .probe = da903x_led_probe, | ||
| 156 | .remove = __devexit_p(da903x_led_remove), | ||
| 157 | }; | ||
| 158 | |||
| 159 | static int __init da903x_led_init(void) | ||
| 160 | { | ||
| 161 | return platform_driver_register(&da903x_led_driver); | ||
| 162 | } | ||
| 163 | module_init(da903x_led_init); | ||
| 164 | |||
| 165 | static void __exit da903x_led_exit(void) | ||
| 166 | { | ||
| 167 | platform_driver_unregister(&da903x_led_driver); | ||
| 168 | } | ||
| 169 | module_exit(da903x_led_exit); | ||
| 170 | |||
| 171 | MODULE_DESCRIPTION("LEDs driver for Dialog Semiconductor DA9030/DA9034"); | ||
| 172 | MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>" | ||
| 173 | "Mike Rapoport <mike@compulab.co.il>"); | ||
| 174 | MODULE_LICENSE("GPL"); | ||
| 175 | MODULE_ALIAS("platform:da903x-led"); | ||
diff --git a/drivers/leds/leds-hp-disk.c b/drivers/leds/leds-hp-disk.c new file mode 100644 index 000000000000..53a25b1c2dae --- /dev/null +++ b/drivers/leds/leds-hp-disk.c | |||
| @@ -0,0 +1,156 @@ | |||
| 1 | /* | ||
| 2 | * leds-hp-disk.c - driver for HP "hard disk protection" LED | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Pavel Machek | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License as published by | ||
| 8 | * the Free Software Foundation; either version 2 of the License, or | ||
| 9 | * (at your option) any later version. | ||
| 10 | * | ||
| 11 | * This program is distributed in the hope that it will be useful, | ||
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 14 | * GNU General Public License for more details. | ||
| 15 | * | ||
| 16 | * You should have received a copy of the GNU General Public License | ||
| 17 | * along with this program; if not, write to the Free Software | ||
| 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 19 | */ | ||
| 20 | |||
| 21 | #include <linux/kernel.h> | ||
| 22 | #include <linux/init.h> | ||
| 23 | #include <linux/dmi.h> | ||
| 24 | #include <linux/module.h> | ||
| 25 | #include <linux/types.h> | ||
| 26 | #include <linux/platform_device.h> | ||
| 27 | #include <linux/interrupt.h> | ||
| 28 | #include <linux/input.h> | ||
| 29 | #include <linux/kthread.h> | ||
| 30 | #include <linux/version.h> | ||
| 31 | #include <linux/leds.h> | ||
| 32 | #include <acpi/acpi_drivers.h> | ||
| 33 | |||
| 34 | #define DRIVER_NAME "leds-hp-disk" | ||
| 35 | #define ACPI_MDPS_CLASS "led" | ||
| 36 | |||
| 37 | /* For automatic insertion of the module */ | ||
| 38 | static struct acpi_device_id hpled_device_ids[] = { | ||
| 39 | {"HPQ0004", 0}, /* HP Mobile Data Protection System PNP */ | ||
| 40 | {"", 0}, | ||
| 41 | }; | ||
| 42 | MODULE_DEVICE_TABLE(acpi, hpled_device_ids); | ||
| 43 | |||
| 44 | struct acpi_hpled { | ||
| 45 | struct acpi_device *device; /* The ACPI device */ | ||
| 46 | }; | ||
| 47 | |||
| 48 | static struct acpi_hpled adev; | ||
| 49 | |||
| 50 | static acpi_status hpled_acpi_write(acpi_handle handle, int reg) | ||
| 51 | { | ||
| 52 | unsigned long ret; /* Not used when writing */ | ||
| 53 | union acpi_object in_obj[1]; | ||
| 54 | struct acpi_object_list args = { 1, in_obj }; | ||
| 55 | |||
| 56 | in_obj[0].type = ACPI_TYPE_INTEGER; | ||
| 57 | in_obj[0].integer.value = reg; | ||
| 58 | |||
| 59 | return acpi_evaluate_integer(handle, "ALED", &args, &ret); | ||
| 60 | } | ||
| 61 | |||
| 62 | static void hpled_set(struct led_classdev *led_cdev, | ||
| 63 | enum led_brightness value) | ||
| 64 | { | ||
| 65 | hpled_acpi_write(adev.device->handle, !!value); | ||
| 66 | } | ||
| 67 | |||
| 68 | static struct led_classdev hpled_led = { | ||
| 69 | .name = "hp:red:hddprotection", | ||
| 70 | .default_trigger = "heartbeat", | ||
| 71 | .brightness_set = hpled_set, | ||
| 72 | }; | ||
| 73 | |||
| 74 | #ifdef CONFIG_PM | ||
| 75 | static int hpled_suspend(struct acpi_device *dev, pm_message_t state) | ||
| 76 | { | ||
| 77 | led_classdev_suspend(&hpled_led); | ||
| 78 | return 0; | ||
| 79 | } | ||
| 80 | |||
| 81 | static int hpled_resume(struct acpi_device *dev) | ||
| 82 | { | ||
| 83 | led_classdev_resume(&hpled_led); | ||
| 84 | return 0; | ||
| 85 | } | ||
| 86 | #else | ||
| 87 | #define hpled_suspend NULL | ||
| 88 | #define hpled_resume NULL | ||
| 89 | #endif | ||
| 90 | |||
| 91 | static int hpled_add(struct acpi_device *device) | ||
| 92 | { | ||
| 93 | int ret; | ||
| 94 | |||
| 95 | if (!device) | ||
| 96 | return -EINVAL; | ||
| 97 | |||
| 98 | adev.device = device; | ||
| 99 | strcpy(acpi_device_name(device), DRIVER_NAME); | ||
| 100 | strcpy(acpi_device_class(device), ACPI_MDPS_CLASS); | ||
| 101 | device->driver_data = &adev; | ||
| 102 | |||
| 103 | ret = led_classdev_register(NULL, &hpled_led); | ||
| 104 | return ret; | ||
| 105 | } | ||
| 106 | |||
| 107 | static int hpled_remove(struct acpi_device *device, int type) | ||
| 108 | { | ||
| 109 | if (!device) | ||
| 110 | return -EINVAL; | ||
| 111 | |||
| 112 | led_classdev_unregister(&hpled_led); | ||
| 113 | return 0; | ||
| 114 | } | ||
| 115 | |||
| 116 | |||
| 117 | |||
| 118 | static struct acpi_driver leds_hp_driver = { | ||
| 119 | .name = DRIVER_NAME, | ||
| 120 | .class = ACPI_MDPS_CLASS, | ||
| 121 | .ids = hpled_device_ids, | ||
| 122 | .ops = { | ||
| 123 | .add = hpled_add, | ||
| 124 | .remove = hpled_remove, | ||
| 125 | .suspend = hpled_suspend, | ||
| 126 | .resume = hpled_resume, | ||
| 127 | } | ||
| 128 | }; | ||
| 129 | |||
| 130 | static int __init hpled_init_module(void) | ||
| 131 | { | ||
| 132 | int ret; | ||
| 133 | |||
| 134 | if (acpi_disabled) | ||
| 135 | return -ENODEV; | ||
| 136 | |||
| 137 | ret = acpi_bus_register_driver(&leds_hp_driver); | ||
| 138 | if (ret < 0) | ||
| 139 | return ret; | ||
| 140 | |||
| 141 | printk(KERN_INFO DRIVER_NAME " driver loaded.\n"); | ||
| 142 | |||
| 143 | return 0; | ||
| 144 | } | ||
| 145 | |||
| 146 | static void __exit hpled_exit_module(void) | ||
| 147 | { | ||
| 148 | acpi_bus_unregister_driver(&leds_hp_driver); | ||
| 149 | } | ||
| 150 | |||
| 151 | MODULE_DESCRIPTION("Driver for HP disk protection LED"); | ||
| 152 | MODULE_AUTHOR("Pavel Machek <pavel@suse.cz>"); | ||
| 153 | MODULE_LICENSE("GPL"); | ||
| 154 | |||
| 155 | module_init(hpled_init_module); | ||
| 156 | module_exit(hpled_exit_module); | ||
diff --git a/drivers/leds/leds-pca955x.c b/drivers/leds/leds-pca955x.c index f508729123b5..4e2d1a42b48f 100644 --- a/drivers/leds/leds-pca955x.c +++ b/drivers/leds/leds-pca955x.c | |||
| @@ -226,7 +226,7 @@ static void pca955x_led_work(struct work_struct *work) | |||
| 226 | pca955x_write_ls(pca955x->client, chip_ls, ls); | 226 | pca955x_write_ls(pca955x->client, chip_ls, ls); |
| 227 | } | 227 | } |
| 228 | 228 | ||
| 229 | void pca955x_led_set(struct led_classdev *led_cdev, enum led_brightness value) | 229 | static void pca955x_led_set(struct led_classdev *led_cdev, enum led_brightness value) |
| 230 | { | 230 | { |
| 231 | struct pca955x_led *pca955x; | 231 | struct pca955x_led *pca955x; |
| 232 | 232 | ||
diff --git a/drivers/leds/leds-wrap.c b/drivers/leds/leds-wrap.c index 7ac61a7b56ad..2f3aa87f2a1f 100644 --- a/drivers/leds/leds-wrap.c +++ b/drivers/leds/leds-wrap.c | |||
| @@ -53,8 +53,9 @@ static void wrap_extra_led_set(struct led_classdev *led_cdev, | |||
| 53 | } | 53 | } |
| 54 | 54 | ||
| 55 | static struct led_classdev wrap_power_led = { | 55 | static struct led_classdev wrap_power_led = { |
| 56 | .name = "wrap::power", | 56 | .name = "wrap::power", |
| 57 | .brightness_set = wrap_power_led_set, | 57 | .brightness_set = wrap_power_led_set, |
| 58 | .default_trigger = "default-on", | ||
| 58 | }; | 59 | }; |
| 59 | 60 | ||
| 60 | static struct led_classdev wrap_error_led = { | 61 | static struct led_classdev wrap_error_led = { |
diff --git a/drivers/leds/ledtrig-backlight.c b/drivers/leds/ledtrig-backlight.c new file mode 100644 index 000000000000..d3dfcfb417b8 --- /dev/null +++ b/drivers/leds/ledtrig-backlight.c | |||
| @@ -0,0 +1,110 @@ | |||
| 1 | /* | ||
| 2 | * Backlight emulation LED trigger | ||
| 3 | * | ||
| 4 | * Copyright 2008 (C) Rodolfo Giometti <giometti@linux.it> | ||
| 5 | * Copyright 2008 (C) Eurotech S.p.A. <info@eurotech.it> | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License version 2 as | ||
| 9 | * published by the Free Software Foundation. | ||
| 10 | * | ||
| 11 | */ | ||
| 12 | |||
| 13 | #include <linux/module.h> | ||
| 14 | #include <linux/kernel.h> | ||
| 15 | #include <linux/init.h> | ||
| 16 | #include <linux/fb.h> | ||
| 17 | #include <linux/leds.h> | ||
| 18 | #include "leds.h" | ||
| 19 | |||
| 20 | #define BLANK 1 | ||
| 21 | #define UNBLANK 0 | ||
| 22 | |||
| 23 | struct bl_trig_notifier { | ||
| 24 | struct led_classdev *led; | ||
| 25 | int brightness; | ||
| 26 | int old_status; | ||
| 27 | struct notifier_block notifier; | ||
| 28 | }; | ||
| 29 | |||
| 30 | static int fb_notifier_callback(struct notifier_block *p, | ||
| 31 | unsigned long event, void *data) | ||
| 32 | { | ||
| 33 | struct bl_trig_notifier *n = container_of(p, | ||
| 34 | struct bl_trig_notifier, notifier); | ||
| 35 | struct led_classdev *led = n->led; | ||
| 36 | struct fb_event *fb_event = data; | ||
| 37 | int *blank = fb_event->data; | ||
| 38 | |||
| 39 | switch (event) { | ||
| 40 | case FB_EVENT_BLANK : | ||
| 41 | if (*blank && n->old_status == UNBLANK) { | ||
| 42 | n->brightness = led->brightness; | ||
| 43 | led_set_brightness(led, LED_OFF); | ||
| 44 | n->old_status = BLANK; | ||
| 45 | } else if (!*blank && n->old_status == BLANK) { | ||
| 46 | led_set_brightness(led, n->brightness); | ||
| 47 | n->old_status = UNBLANK; | ||
| 48 | } | ||
| 49 | break; | ||
| 50 | } | ||
| 51 | |||
| 52 | return 0; | ||
| 53 | } | ||
| 54 | |||
| 55 | static void bl_trig_activate(struct led_classdev *led) | ||
| 56 | { | ||
| 57 | int ret; | ||
| 58 | |||
| 59 | struct bl_trig_notifier *n; | ||
| 60 | |||
| 61 | n = kzalloc(sizeof(struct bl_trig_notifier), GFP_KERNEL); | ||
| 62 | led->trigger_data = n; | ||
| 63 | if (!n) { | ||
| 64 | dev_err(led->dev, "unable to allocate backlight trigger\n"); | ||
| 65 | return; | ||
| 66 | } | ||
| 67 | |||
| 68 | n->led = led; | ||
| 69 | n->brightness = led->brightness; | ||
| 70 | n->old_status = UNBLANK; | ||
| 71 | n->notifier.notifier_call = fb_notifier_callback; | ||
| 72 | |||
| 73 | ret = fb_register_client(&n->notifier); | ||
| 74 | if (ret) | ||
| 75 | dev_err(led->dev, "unable to register backlight trigger\n"); | ||
| 76 | } | ||
| 77 | |||
| 78 | static void bl_trig_deactivate(struct led_classdev *led) | ||
| 79 | { | ||
| 80 | struct bl_trig_notifier *n = | ||
| 81 | (struct bl_trig_notifier *) led->trigger_data; | ||
| 82 | |||
| 83 | if (n) { | ||
| 84 | fb_unregister_client(&n->notifier); | ||
| 85 | kfree(n); | ||
| 86 | } | ||
| 87 | } | ||
| 88 | |||
| 89 | static struct led_trigger bl_led_trigger = { | ||
| 90 | .name = "backlight", | ||
| 91 | .activate = bl_trig_activate, | ||
| 92 | .deactivate = bl_trig_deactivate | ||
| 93 | }; | ||
| 94 | |||
| 95 | static int __init bl_trig_init(void) | ||
| 96 | { | ||
| 97 | return led_trigger_register(&bl_led_trigger); | ||
| 98 | } | ||
| 99 | |||
| 100 | static void __exit bl_trig_exit(void) | ||
| 101 | { | ||
| 102 | led_trigger_unregister(&bl_led_trigger); | ||
| 103 | } | ||
| 104 | |||
| 105 | module_init(bl_trig_init); | ||
| 106 | module_exit(bl_trig_exit); | ||
| 107 | |||
| 108 | MODULE_AUTHOR("Rodolfo Giometti <giometti@linux.it>"); | ||
| 109 | MODULE_DESCRIPTION("Backlight emulation LED trigger"); | ||
| 110 | MODULE_LICENSE("GPL v2"); | ||
diff --git a/drivers/leds/ledtrig-timer.c b/drivers/leds/ledtrig-timer.c index 5c99f4f0c692..db681962d7bb 100644 --- a/drivers/leds/ledtrig-timer.c +++ b/drivers/leds/ledtrig-timer.c | |||
| @@ -70,9 +70,7 @@ static ssize_t led_delay_on_show(struct device *dev, | |||
| 70 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 70 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
| 71 | struct timer_trig_data *timer_data = led_cdev->trigger_data; | 71 | struct timer_trig_data *timer_data = led_cdev->trigger_data; |
| 72 | 72 | ||
| 73 | sprintf(buf, "%lu\n", timer_data->delay_on); | 73 | return sprintf(buf, "%lu\n", timer_data->delay_on); |
| 74 | |||
| 75 | return strlen(buf) + 1; | ||
| 76 | } | 74 | } |
| 77 | 75 | ||
| 78 | static ssize_t led_delay_on_store(struct device *dev, | 76 | static ssize_t led_delay_on_store(struct device *dev, |
| @@ -116,9 +114,7 @@ static ssize_t led_delay_off_show(struct device *dev, | |||
| 116 | struct led_classdev *led_cdev = dev_get_drvdata(dev); | 114 | struct led_classdev *led_cdev = dev_get_drvdata(dev); |
| 117 | struct timer_trig_data *timer_data = led_cdev->trigger_data; | 115 | struct timer_trig_data *timer_data = led_cdev->trigger_data; |
| 118 | 116 | ||
| 119 | sprintf(buf, "%lu\n", timer_data->delay_off); | 117 | return sprintf(buf, "%lu\n", timer_data->delay_off); |
| 120 | |||
| 121 | return strlen(buf) + 1; | ||
| 122 | } | 118 | } |
| 123 | 119 | ||
| 124 | static ssize_t led_delay_off_store(struct device *dev, | 120 | static ssize_t led_delay_off_store(struct device *dev, |
diff --git a/drivers/message/fusion/mptscsih.c b/drivers/message/fusion/mptscsih.c index 9f9354fd3516..d62fd4f6b52e 100644 --- a/drivers/message/fusion/mptscsih.c +++ b/drivers/message/fusion/mptscsih.c | |||
| @@ -1760,10 +1760,9 @@ mptscsih_get_tm_timeout(MPT_ADAPTER *ioc) | |||
| 1760 | case FC: | 1760 | case FC: |
| 1761 | return 40; | 1761 | return 40; |
| 1762 | case SAS: | 1762 | case SAS: |
| 1763 | return 10; | ||
| 1764 | case SPI: | 1763 | case SPI: |
| 1765 | default: | 1764 | default: |
| 1766 | return 2; | 1765 | return 10; |
| 1767 | } | 1766 | } |
| 1768 | } | 1767 | } |
| 1769 | 1768 | ||
diff --git a/drivers/net/8139cp.c b/drivers/net/8139cp.c index 85fa40a0a667..9ba1f0b46429 100644 --- a/drivers/net/8139cp.c +++ b/drivers/net/8139cp.c | |||
| @@ -1836,10 +1836,9 @@ static int cp_init_one (struct pci_dev *pdev, const struct pci_device_id *ent) | |||
| 1836 | 1836 | ||
| 1837 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 1837 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
| 1838 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision < 0x20) { | 1838 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision < 0x20) { |
| 1839 | dev_err(&pdev->dev, | 1839 | dev_info(&pdev->dev, |
| 1840 | "This (id %04x:%04x rev %02x) is not an 8139C+ compatible chip\n", | 1840 | "This (id %04x:%04x rev %02x) is not an 8139C+ compatible chip, use 8139too\n", |
| 1841 | pdev->vendor, pdev->device, pdev->revision); | 1841 | pdev->vendor, pdev->device, pdev->revision); |
| 1842 | dev_err(&pdev->dev, "Try the \"8139too\" driver instead.\n"); | ||
| 1843 | return -ENODEV; | 1842 | return -ENODEV; |
| 1844 | } | 1843 | } |
| 1845 | 1844 | ||
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c index 0daf8c15e381..63f906b04899 100644 --- a/drivers/net/8139too.c +++ b/drivers/net/8139too.c | |||
| @@ -946,10 +946,9 @@ static int __devinit rtl8139_init_one (struct pci_dev *pdev, | |||
| 946 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 946 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
| 947 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision >= 0x20) { | 947 | pdev->device == PCI_DEVICE_ID_REALTEK_8139 && pdev->revision >= 0x20) { |
| 948 | dev_info(&pdev->dev, | 948 | dev_info(&pdev->dev, |
| 949 | "This (id %04x:%04x rev %02x) is an enhanced 8139C+ chip\n", | 949 | "This (id %04x:%04x rev %02x) is an enhanced 8139C+ chip, use 8139cp\n", |
| 950 | pdev->vendor, pdev->device, pdev->revision); | 950 | pdev->vendor, pdev->device, pdev->revision); |
| 951 | dev_info(&pdev->dev, | 951 | return -ENODEV; |
| 952 | "Use the \"8139cp\" driver for improved performance and stability.\n"); | ||
| 953 | } | 952 | } |
| 954 | 953 | ||
| 955 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && | 954 | if (pdev->vendor == PCI_VENDOR_ID_REALTEK && |
diff --git a/drivers/net/Kconfig b/drivers/net/Kconfig index 0b71ebc074b6..f749b40f954e 100644 --- a/drivers/net/Kconfig +++ b/drivers/net/Kconfig | |||
| @@ -894,7 +894,7 @@ config SMC91X | |||
| 894 | select CRC32 | 894 | select CRC32 |
| 895 | select MII | 895 | select MII |
| 896 | depends on ARM || REDWOOD_5 || REDWOOD_6 || M32R || SUPERH || \ | 896 | depends on ARM || REDWOOD_5 || REDWOOD_6 || M32R || SUPERH || \ |
| 897 | SOC_AU1X00 || BLACKFIN || MN10300 | 897 | MIPS || BLACKFIN || MN10300 |
| 898 | help | 898 | help |
| 899 | This is a driver for SMC's 91x series of Ethernet chipsets, | 899 | This is a driver for SMC's 91x series of Ethernet chipsets, |
| 900 | including the SMC91C94 and the SMC91C111. Say Y if you want it | 900 | including the SMC91C94 and the SMC91C111. Say Y if you want it |
| @@ -966,7 +966,7 @@ config SMC911X | |||
| 966 | tristate "SMSC LAN911[5678] support" | 966 | tristate "SMSC LAN911[5678] support" |
| 967 | select CRC32 | 967 | select CRC32 |
| 968 | select MII | 968 | select MII |
| 969 | depends on ARCH_PXA || SUPERH | 969 | depends on ARM || SUPERH |
| 970 | help | 970 | help |
| 971 | This is a driver for SMSC's LAN911x series of Ethernet chipsets | 971 | This is a driver for SMSC's LAN911x series of Ethernet chipsets |
| 972 | including the new LAN9115, LAN9116, LAN9117, and LAN9118. | 972 | including the new LAN9115, LAN9116, LAN9117, and LAN9118. |
| @@ -2009,6 +2009,11 @@ config IGB_LRO | |||
| 2009 | 2009 | ||
| 2010 | If in doubt, say N. | 2010 | If in doubt, say N. |
| 2011 | 2011 | ||
| 2012 | config IGB_DCA | ||
| 2013 | bool "Enable DCA" | ||
| 2014 | default y | ||
| 2015 | depends on IGB && DCA && !(IGB=y && DCA=m) | ||
| 2016 | |||
| 2012 | source "drivers/net/ixp2000/Kconfig" | 2017 | source "drivers/net/ixp2000/Kconfig" |
| 2013 | 2018 | ||
| 2014 | config MYRI_SBUS | 2019 | config MYRI_SBUS |
diff --git a/drivers/net/ax88796.c b/drivers/net/ax88796.c index 4207d6efddc0..9a314d88e7b6 100644 --- a/drivers/net/ax88796.c +++ b/drivers/net/ax88796.c | |||
| @@ -838,12 +838,12 @@ static int ax_probe(struct platform_device *pdev) | |||
| 838 | 838 | ||
| 839 | /* find the platform resources */ | 839 | /* find the platform resources */ |
| 840 | 840 | ||
| 841 | dev->irq = platform_get_irq(pdev, 0); | 841 | ret = platform_get_irq(pdev, 0); |
| 842 | if (dev->irq < 0) { | 842 | if (ret < 0) { |
| 843 | dev_err(&pdev->dev, "no IRQ specified\n"); | 843 | dev_err(&pdev->dev, "no IRQ specified\n"); |
| 844 | ret = -ENXIO; | ||
| 845 | goto exit_mem; | 844 | goto exit_mem; |
| 846 | } | 845 | } |
| 846 | dev->irq = ret; | ||
| 847 | 847 | ||
| 848 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); | 848 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
| 849 | if (res == NULL) { | 849 | if (res == NULL) { |
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index 8e2be24f3fe4..832739f38db4 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
| @@ -1341,18 +1341,24 @@ static int bond_compute_features(struct bonding *bond) | |||
| 1341 | int i; | 1341 | int i; |
| 1342 | 1342 | ||
| 1343 | features &= ~(NETIF_F_ALL_CSUM | BOND_VLAN_FEATURES); | 1343 | features &= ~(NETIF_F_ALL_CSUM | BOND_VLAN_FEATURES); |
| 1344 | features |= NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | | 1344 | features |= NETIF_F_GSO_MASK | NETIF_F_NO_CSUM; |
| 1345 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM; | 1345 | |
| 1346 | if (!bond->first_slave) | ||
| 1347 | goto done; | ||
| 1348 | |||
| 1349 | features &= ~NETIF_F_ONE_FOR_ALL; | ||
| 1346 | 1350 | ||
| 1347 | bond_for_each_slave(bond, slave, i) { | 1351 | bond_for_each_slave(bond, slave, i) { |
| 1348 | features = netdev_compute_features(features, | 1352 | features = netdev_increment_features(features, |
| 1349 | slave->dev->features); | 1353 | slave->dev->features, |
| 1354 | NETIF_F_ONE_FOR_ALL); | ||
| 1350 | if (slave->dev->hard_header_len > max_hard_header_len) | 1355 | if (slave->dev->hard_header_len > max_hard_header_len) |
| 1351 | max_hard_header_len = slave->dev->hard_header_len; | 1356 | max_hard_header_len = slave->dev->hard_header_len; |
| 1352 | } | 1357 | } |
| 1353 | 1358 | ||
| 1359 | done: | ||
| 1354 | features |= (bond_dev->features & BOND_VLAN_FEATURES); | 1360 | features |= (bond_dev->features & BOND_VLAN_FEATURES); |
| 1355 | bond_dev->features = features; | 1361 | bond_dev->features = netdev_fix_features(features, NULL); |
| 1356 | bond_dev->hard_header_len = max_hard_header_len; | 1362 | bond_dev->hard_header_len = max_hard_header_len; |
| 1357 | 1363 | ||
| 1358 | return 0; | 1364 | return 0; |
diff --git a/drivers/net/cxgb3/l2t.c b/drivers/net/cxgb3/l2t.c index 4407ac9bb555..ff1611f90e7a 100644 --- a/drivers/net/cxgb3/l2t.c +++ b/drivers/net/cxgb3/l2t.c | |||
| @@ -431,6 +431,7 @@ struct l2t_data *t3_init_l2t(unsigned int l2t_capacity) | |||
| 431 | for (i = 0; i < l2t_capacity; ++i) { | 431 | for (i = 0; i < l2t_capacity; ++i) { |
| 432 | d->l2tab[i].idx = i; | 432 | d->l2tab[i].idx = i; |
| 433 | d->l2tab[i].state = L2T_STATE_UNUSED; | 433 | d->l2tab[i].state = L2T_STATE_UNUSED; |
| 434 | __skb_queue_head_init(&d->l2tab[i].arpq); | ||
| 434 | spin_lock_init(&d->l2tab[i].lock); | 435 | spin_lock_init(&d->l2tab[i].lock); |
| 435 | atomic_set(&d->l2tab[i].refcnt, 0); | 436 | atomic_set(&d->l2tab[i].refcnt, 0); |
| 436 | } | 437 | } |
diff --git a/drivers/net/dm9000.c b/drivers/net/dm9000.c index f42c23f42652..5a9083e3f443 100644 --- a/drivers/net/dm9000.c +++ b/drivers/net/dm9000.c | |||
| @@ -47,15 +47,6 @@ | |||
| 47 | #define CARDNAME "dm9000" | 47 | #define CARDNAME "dm9000" |
| 48 | #define DRV_VERSION "1.31" | 48 | #define DRV_VERSION "1.31" |
| 49 | 49 | ||
| 50 | #ifdef CONFIG_BLACKFIN | ||
| 51 | #define readsb insb | ||
| 52 | #define readsw insw | ||
| 53 | #define readsl insl | ||
| 54 | #define writesb outsb | ||
| 55 | #define writesw outsw | ||
| 56 | #define writesl outsl | ||
| 57 | #endif | ||
| 58 | |||
| 59 | /* | 50 | /* |
| 60 | * Transmit timeout, default 5 seconds. | 51 | * Transmit timeout, default 5 seconds. |
| 61 | */ | 52 | */ |
diff --git a/drivers/net/ehea/ehea.h b/drivers/net/ehea/ehea.h index 5524271eedca..82dd1a891ce7 100644 --- a/drivers/net/ehea/ehea.h +++ b/drivers/net/ehea/ehea.h | |||
| @@ -40,7 +40,7 @@ | |||
| 40 | #include <asm/io.h> | 40 | #include <asm/io.h> |
| 41 | 41 | ||
| 42 | #define DRV_NAME "ehea" | 42 | #define DRV_NAME "ehea" |
| 43 | #define DRV_VERSION "EHEA_0093" | 43 | #define DRV_VERSION "EHEA_0094" |
| 44 | 44 | ||
| 45 | /* eHEA capability flags */ | 45 | /* eHEA capability flags */ |
| 46 | #define DLPAR_PORT_ADD_REM 1 | 46 | #define DLPAR_PORT_ADD_REM 1 |
diff --git a/drivers/net/ehea/ehea_main.c b/drivers/net/ehea/ehea_main.c index b70c5314f537..422fcb93e2c3 100644 --- a/drivers/net/ehea/ehea_main.c +++ b/drivers/net/ehea/ehea_main.c | |||
| @@ -2863,7 +2863,7 @@ static void ehea_rereg_mrs(struct work_struct *work) | |||
| 2863 | struct ehea_adapter *adapter; | 2863 | struct ehea_adapter *adapter; |
| 2864 | 2864 | ||
| 2865 | mutex_lock(&dlpar_mem_lock); | 2865 | mutex_lock(&dlpar_mem_lock); |
| 2866 | ehea_info("LPAR memory enlarged - re-initializing driver"); | 2866 | ehea_info("LPAR memory changed - re-initializing driver"); |
| 2867 | 2867 | ||
| 2868 | list_for_each_entry(adapter, &adapter_list, list) | 2868 | list_for_each_entry(adapter, &adapter_list, list) |
| 2869 | if (adapter->active_ports) { | 2869 | if (adapter->active_ports) { |
| @@ -2900,13 +2900,6 @@ static void ehea_rereg_mrs(struct work_struct *work) | |||
| 2900 | } | 2900 | } |
| 2901 | } | 2901 | } |
| 2902 | 2902 | ||
| 2903 | ehea_destroy_busmap(); | ||
| 2904 | ret = ehea_create_busmap(); | ||
| 2905 | if (ret) { | ||
| 2906 | ehea_error("creating ehea busmap failed"); | ||
| 2907 | goto out; | ||
| 2908 | } | ||
| 2909 | |||
| 2910 | clear_bit(__EHEA_STOP_XFER, &ehea_driver_flags); | 2903 | clear_bit(__EHEA_STOP_XFER, &ehea_driver_flags); |
| 2911 | 2904 | ||
| 2912 | list_for_each_entry(adapter, &adapter_list, list) | 2905 | list_for_each_entry(adapter, &adapter_list, list) |
| @@ -3519,9 +3512,21 @@ void ehea_crash_handler(void) | |||
| 3519 | static int ehea_mem_notifier(struct notifier_block *nb, | 3512 | static int ehea_mem_notifier(struct notifier_block *nb, |
| 3520 | unsigned long action, void *data) | 3513 | unsigned long action, void *data) |
| 3521 | { | 3514 | { |
| 3515 | struct memory_notify *arg = data; | ||
| 3522 | switch (action) { | 3516 | switch (action) { |
| 3523 | case MEM_OFFLINE: | 3517 | case MEM_CANCEL_OFFLINE: |
| 3524 | ehea_info("memory has been removed"); | 3518 | ehea_info("memory offlining canceled"); |
| 3519 | /* Readd canceled memory block */ | ||
| 3520 | case MEM_ONLINE: | ||
| 3521 | ehea_info("memory is going online"); | ||
| 3522 | if (ehea_add_sect_bmap(arg->start_pfn, arg->nr_pages)) | ||
| 3523 | return NOTIFY_BAD; | ||
| 3524 | ehea_rereg_mrs(NULL); | ||
| 3525 | break; | ||
| 3526 | case MEM_GOING_OFFLINE: | ||
| 3527 | ehea_info("memory is going offline"); | ||
| 3528 | if (ehea_rem_sect_bmap(arg->start_pfn, arg->nr_pages)) | ||
| 3529 | return NOTIFY_BAD; | ||
| 3525 | ehea_rereg_mrs(NULL); | 3530 | ehea_rereg_mrs(NULL); |
| 3526 | break; | 3531 | break; |
| 3527 | default: | 3532 | default: |
diff --git a/drivers/net/ehea/ehea_qmr.c b/drivers/net/ehea/ehea_qmr.c index db8a9257e680..9b61dc9865d1 100644 --- a/drivers/net/ehea/ehea_qmr.c +++ b/drivers/net/ehea/ehea_qmr.c | |||
| @@ -567,7 +567,7 @@ static inline int ehea_calc_index(unsigned long i, unsigned long s) | |||
| 567 | static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, | 567 | static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, |
| 568 | int dir) | 568 | int dir) |
| 569 | { | 569 | { |
| 570 | if(!ehea_top_bmap->dir[dir]) { | 570 | if (!ehea_top_bmap->dir[dir]) { |
| 571 | ehea_top_bmap->dir[dir] = | 571 | ehea_top_bmap->dir[dir] = |
| 572 | kzalloc(sizeof(struct ehea_dir_bmap), GFP_KERNEL); | 572 | kzalloc(sizeof(struct ehea_dir_bmap), GFP_KERNEL); |
| 573 | if (!ehea_top_bmap->dir[dir]) | 573 | if (!ehea_top_bmap->dir[dir]) |
| @@ -578,7 +578,7 @@ static inline int ehea_init_top_bmap(struct ehea_top_bmap *ehea_top_bmap, | |||
| 578 | 578 | ||
| 579 | static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) | 579 | static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) |
| 580 | { | 580 | { |
| 581 | if(!ehea_bmap->top[top]) { | 581 | if (!ehea_bmap->top[top]) { |
| 582 | ehea_bmap->top[top] = | 582 | ehea_bmap->top[top] = |
| 583 | kzalloc(sizeof(struct ehea_top_bmap), GFP_KERNEL); | 583 | kzalloc(sizeof(struct ehea_top_bmap), GFP_KERNEL); |
| 584 | if (!ehea_bmap->top[top]) | 584 | if (!ehea_bmap->top[top]) |
| @@ -587,53 +587,124 @@ static inline int ehea_init_bmap(struct ehea_bmap *ehea_bmap, int top, int dir) | |||
| 587 | return ehea_init_top_bmap(ehea_bmap->top[top], dir); | 587 | return ehea_init_top_bmap(ehea_bmap->top[top], dir); |
| 588 | } | 588 | } |
| 589 | 589 | ||
| 590 | static int ehea_create_busmap_callback(unsigned long pfn, | 590 | static DEFINE_MUTEX(ehea_busmap_mutex); |
| 591 | unsigned long nr_pages, void *arg) | 591 | static unsigned long ehea_mr_len; |
| 592 | { | ||
| 593 | unsigned long i, mr_len, start_section, end_section; | ||
| 594 | start_section = (pfn * PAGE_SIZE) / EHEA_SECTSIZE; | ||
| 595 | end_section = start_section + ((nr_pages * PAGE_SIZE) / EHEA_SECTSIZE); | ||
| 596 | mr_len = *(unsigned long *)arg; | ||
| 597 | 592 | ||
| 598 | if (!ehea_bmap) | 593 | #define EHEA_BUSMAP_ADD_SECT 1 |
| 599 | ehea_bmap = kzalloc(sizeof(struct ehea_bmap), GFP_KERNEL); | 594 | #define EHEA_BUSMAP_REM_SECT 0 |
| 600 | if (!ehea_bmap) | ||
| 601 | return -ENOMEM; | ||
| 602 | 595 | ||
| 603 | for (i = start_section; i < end_section; i++) { | 596 | static void ehea_rebuild_busmap(void) |
| 604 | int ret; | 597 | { |
| 605 | int top, dir, idx; | 598 | u64 vaddr = EHEA_BUSMAP_START; |
| 606 | u64 vaddr; | 599 | int top, dir, idx; |
| 600 | |||
| 601 | for (top = 0; top < EHEA_MAP_ENTRIES; top++) { | ||
| 602 | struct ehea_top_bmap *ehea_top; | ||
| 603 | int valid_dir_entries = 0; | ||
| 607 | 604 | ||
| 608 | top = ehea_calc_index(i, EHEA_TOP_INDEX_SHIFT); | 605 | if (!ehea_bmap->top[top]) |
| 609 | dir = ehea_calc_index(i, EHEA_DIR_INDEX_SHIFT); | 606 | continue; |
| 607 | ehea_top = ehea_bmap->top[top]; | ||
| 608 | for (dir = 0; dir < EHEA_MAP_ENTRIES; dir++) { | ||
| 609 | struct ehea_dir_bmap *ehea_dir; | ||
| 610 | int valid_entries = 0; | ||
| 610 | 611 | ||
| 611 | ret = ehea_init_bmap(ehea_bmap, top, dir); | 612 | if (!ehea_top->dir[dir]) |
| 612 | if(ret) | 613 | continue; |
| 613 | return ret; | 614 | valid_dir_entries++; |
| 615 | ehea_dir = ehea_top->dir[dir]; | ||
| 616 | for (idx = 0; idx < EHEA_MAP_ENTRIES; idx++) { | ||
| 617 | if (!ehea_dir->ent[idx]) | ||
| 618 | continue; | ||
| 619 | valid_entries++; | ||
| 620 | ehea_dir->ent[idx] = vaddr; | ||
| 621 | vaddr += EHEA_SECTSIZE; | ||
| 622 | } | ||
| 623 | if (!valid_entries) { | ||
| 624 | ehea_top->dir[dir] = NULL; | ||
| 625 | kfree(ehea_dir); | ||
| 626 | } | ||
| 627 | } | ||
| 628 | if (!valid_dir_entries) { | ||
| 629 | ehea_bmap->top[top] = NULL; | ||
| 630 | kfree(ehea_top); | ||
| 631 | } | ||
| 632 | } | ||
| 633 | } | ||
| 614 | 634 | ||
| 615 | idx = i & EHEA_INDEX_MASK; | 635 | static int ehea_update_busmap(unsigned long pfn, unsigned long pgnum, int add) |
| 616 | vaddr = EHEA_BUSMAP_START + mr_len + i * EHEA_SECTSIZE; | 636 | { |
| 637 | unsigned long i, start_section, end_section; | ||
| 617 | 638 | ||
| 618 | ehea_bmap->top[top]->dir[dir]->ent[idx] = vaddr; | 639 | if (!ehea_bmap) { |
| 640 | ehea_bmap = kzalloc(sizeof(struct ehea_bmap), GFP_KERNEL); | ||
| 641 | if (!ehea_bmap) | ||
| 642 | return -ENOMEM; | ||
| 619 | } | 643 | } |
| 620 | 644 | ||
| 621 | mr_len += nr_pages * PAGE_SIZE; | 645 | start_section = (pfn * PAGE_SIZE) / EHEA_SECTSIZE; |
| 622 | *(unsigned long *)arg = mr_len; | 646 | end_section = start_section + ((pgnum * PAGE_SIZE) / EHEA_SECTSIZE); |
| 647 | /* Mark entries as valid or invalid only; address is assigned later */ | ||
| 648 | for (i = start_section; i < end_section; i++) { | ||
| 649 | u64 flag; | ||
| 650 | int top = ehea_calc_index(i, EHEA_TOP_INDEX_SHIFT); | ||
| 651 | int dir = ehea_calc_index(i, EHEA_DIR_INDEX_SHIFT); | ||
| 652 | int idx = i & EHEA_INDEX_MASK; | ||
| 653 | |||
| 654 | if (add) { | ||
| 655 | int ret = ehea_init_bmap(ehea_bmap, top, dir); | ||
| 656 | if (ret) | ||
| 657 | return ret; | ||
| 658 | flag = 1; /* valid */ | ||
| 659 | ehea_mr_len += EHEA_SECTSIZE; | ||
| 660 | } else { | ||
| 661 | if (!ehea_bmap->top[top]) | ||
| 662 | continue; | ||
| 663 | if (!ehea_bmap->top[top]->dir[dir]) | ||
| 664 | continue; | ||
| 665 | flag = 0; /* invalid */ | ||
| 666 | ehea_mr_len -= EHEA_SECTSIZE; | ||
| 667 | } | ||
| 623 | 668 | ||
| 669 | ehea_bmap->top[top]->dir[dir]->ent[idx] = flag; | ||
| 670 | } | ||
| 671 | ehea_rebuild_busmap(); /* Assign contiguous addresses for mr */ | ||
| 624 | return 0; | 672 | return 0; |
| 625 | } | 673 | } |
| 626 | 674 | ||
| 627 | static unsigned long ehea_mr_len; | 675 | int ehea_add_sect_bmap(unsigned long pfn, unsigned long nr_pages) |
| 676 | { | ||
| 677 | int ret; | ||
| 628 | 678 | ||
| 629 | static DEFINE_MUTEX(ehea_busmap_mutex); | 679 | mutex_lock(&ehea_busmap_mutex); |
| 680 | ret = ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_ADD_SECT); | ||
| 681 | mutex_unlock(&ehea_busmap_mutex); | ||
| 682 | return ret; | ||
| 683 | } | ||
| 684 | |||
| 685 | int ehea_rem_sect_bmap(unsigned long pfn, unsigned long nr_pages) | ||
| 686 | { | ||
| 687 | int ret; | ||
| 688 | |||
| 689 | mutex_lock(&ehea_busmap_mutex); | ||
| 690 | ret = ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_REM_SECT); | ||
| 691 | mutex_unlock(&ehea_busmap_mutex); | ||
| 692 | return ret; | ||
| 693 | } | ||
| 694 | |||
| 695 | static int ehea_create_busmap_callback(unsigned long pfn, | ||
| 696 | unsigned long nr_pages, void *arg) | ||
| 697 | { | ||
| 698 | return ehea_update_busmap(pfn, nr_pages, EHEA_BUSMAP_ADD_SECT); | ||
| 699 | } | ||
| 630 | 700 | ||
| 631 | int ehea_create_busmap(void) | 701 | int ehea_create_busmap(void) |
| 632 | { | 702 | { |
| 633 | int ret; | 703 | int ret; |
| 704 | |||
| 634 | mutex_lock(&ehea_busmap_mutex); | 705 | mutex_lock(&ehea_busmap_mutex); |
| 635 | ehea_mr_len = 0; | 706 | ehea_mr_len = 0; |
| 636 | ret = walk_memory_resource(0, 1ULL << MAX_PHYSMEM_BITS, &ehea_mr_len, | 707 | ret = walk_memory_resource(0, 1ULL << MAX_PHYSMEM_BITS, NULL, |
| 637 | ehea_create_busmap_callback); | 708 | ehea_create_busmap_callback); |
| 638 | mutex_unlock(&ehea_busmap_mutex); | 709 | mutex_unlock(&ehea_busmap_mutex); |
| 639 | return ret; | 710 | return ret; |
diff --git a/drivers/net/ehea/ehea_qmr.h b/drivers/net/ehea/ehea_qmr.h index 0bb6f92fa2f8..1e58dc06b7d2 100644 --- a/drivers/net/ehea/ehea_qmr.h +++ b/drivers/net/ehea/ehea_qmr.h | |||
| @@ -378,6 +378,8 @@ int ehea_rem_mr(struct ehea_mr *mr); | |||
| 378 | 378 | ||
| 379 | void ehea_error_data(struct ehea_adapter *adapter, u64 res_handle); | 379 | void ehea_error_data(struct ehea_adapter *adapter, u64 res_handle); |
| 380 | 380 | ||
| 381 | int ehea_add_sect_bmap(unsigned long pfn, unsigned long nr_pages); | ||
| 382 | int ehea_rem_sect_bmap(unsigned long pfn, unsigned long nr_pages); | ||
| 381 | int ehea_create_busmap(void); | 383 | int ehea_create_busmap(void); |
| 382 | void ehea_destroy_busmap(void); | 384 | void ehea_destroy_busmap(void); |
| 383 | u64 ehea_map_vaddr(void *caddr); | 385 | u64 ehea_map_vaddr(void *caddr); |
diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c index 4e4f68304e82..aec3b97e794d 100644 --- a/drivers/net/fec_mpc52xx.c +++ b/drivers/net/fec_mpc52xx.c | |||
| @@ -401,6 +401,21 @@ static int mpc52xx_fec_hard_start_xmit(struct sk_buff *skb, struct net_device *d | |||
| 401 | return 0; | 401 | return 0; |
| 402 | } | 402 | } |
| 403 | 403 | ||
| 404 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
| 405 | static void mpc52xx_fec_poll_controller(struct net_device *dev) | ||
| 406 | { | ||
| 407 | struct mpc52xx_fec_priv *priv = netdev_priv(dev); | ||
| 408 | |||
| 409 | disable_irq(priv->t_irq); | ||
| 410 | mpc52xx_fec_tx_interrupt(priv->t_irq, dev); | ||
| 411 | enable_irq(priv->t_irq); | ||
| 412 | disable_irq(priv->r_irq); | ||
| 413 | mpc52xx_fec_rx_interrupt(priv->r_irq, dev); | ||
| 414 | enable_irq(priv->r_irq); | ||
| 415 | } | ||
| 416 | #endif | ||
| 417 | |||
| 418 | |||
| 404 | /* This handles BestComm transmit task interrupts | 419 | /* This handles BestComm transmit task interrupts |
| 405 | */ | 420 | */ |
| 406 | static irqreturn_t mpc52xx_fec_tx_interrupt(int irq, void *dev_id) | 421 | static irqreturn_t mpc52xx_fec_tx_interrupt(int irq, void *dev_id) |
| @@ -926,6 +941,9 @@ mpc52xx_fec_probe(struct of_device *op, const struct of_device_id *match) | |||
| 926 | ndev->tx_timeout = mpc52xx_fec_tx_timeout; | 941 | ndev->tx_timeout = mpc52xx_fec_tx_timeout; |
| 927 | ndev->watchdog_timeo = FEC_WATCHDOG_TIMEOUT; | 942 | ndev->watchdog_timeo = FEC_WATCHDOG_TIMEOUT; |
| 928 | ndev->base_addr = mem.start; | 943 | ndev->base_addr = mem.start; |
| 944 | #ifdef CONFIG_NET_POLL_CONTROLLER | ||
| 945 | ndev->poll_controller = mpc52xx_fec_poll_controller; | ||
| 946 | #endif | ||
| 929 | 947 | ||
| 930 | priv->t_irq = priv->r_irq = ndev->irq = NO_IRQ; /* IRQ are free for now */ | 948 | priv->t_irq = priv->r_irq = ndev->irq = NO_IRQ; /* IRQ are free for now */ |
| 931 | 949 | ||
diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c index b5bb7ae2817f..64b201134fdb 100644 --- a/drivers/net/gianfar.c +++ b/drivers/net/gianfar.c | |||
| @@ -161,7 +161,7 @@ static int gfar_probe(struct platform_device *pdev) | |||
| 161 | struct gfar_private *priv = NULL; | 161 | struct gfar_private *priv = NULL; |
| 162 | struct gianfar_platform_data *einfo; | 162 | struct gianfar_platform_data *einfo; |
| 163 | struct resource *r; | 163 | struct resource *r; |
| 164 | int err = 0; | 164 | int err = 0, irq; |
| 165 | DECLARE_MAC_BUF(mac); | 165 | DECLARE_MAC_BUF(mac); |
| 166 | 166 | ||
| 167 | einfo = (struct gianfar_platform_data *) pdev->dev.platform_data; | 167 | einfo = (struct gianfar_platform_data *) pdev->dev.platform_data; |
| @@ -187,15 +187,25 @@ static int gfar_probe(struct platform_device *pdev) | |||
| 187 | 187 | ||
| 188 | /* fill out IRQ fields */ | 188 | /* fill out IRQ fields */ |
| 189 | if (einfo->device_flags & FSL_GIANFAR_DEV_HAS_MULTI_INTR) { | 189 | if (einfo->device_flags & FSL_GIANFAR_DEV_HAS_MULTI_INTR) { |
| 190 | priv->interruptTransmit = platform_get_irq_byname(pdev, "tx"); | 190 | irq = platform_get_irq_byname(pdev, "tx"); |
| 191 | priv->interruptReceive = platform_get_irq_byname(pdev, "rx"); | 191 | if (irq < 0) |
| 192 | priv->interruptError = platform_get_irq_byname(pdev, "error"); | 192 | goto regs_fail; |
| 193 | if (priv->interruptTransmit < 0 || priv->interruptReceive < 0 || priv->interruptError < 0) | 193 | priv->interruptTransmit = irq; |
| 194 | |||
| 195 | irq = platform_get_irq_byname(pdev, "rx"); | ||
| 196 | if (irq < 0) | ||
| 197 | goto regs_fail; | ||
| 198 | priv->interruptReceive = irq; | ||
| 199 | |||
| 200 | irq = platform_get_irq_byname(pdev, "error"); | ||
| 201 | if (irq < 0) | ||
| 194 | goto regs_fail; | 202 | goto regs_fail; |
| 203 | priv->interruptError = irq; | ||
| 195 | } else { | 204 | } else { |
| 196 | priv->interruptTransmit = platform_get_irq(pdev, 0); | 205 | irq = platform_get_irq(pdev, 0); |
| 197 | if (priv->interruptTransmit < 0) | 206 | if (irq < 0) |
| 198 | goto regs_fail; | 207 | goto regs_fail; |
| 208 | priv->interruptTransmit = irq; | ||
| 199 | } | 209 | } |
| 200 | 210 | ||
| 201 | /* get a pointer to the register memory */ | 211 | /* get a pointer to the register memory */ |
diff --git a/drivers/net/igb/igb_main.c b/drivers/net/igb/igb_main.c index 93d02efa9a0a..1f397cd99414 100644 --- a/drivers/net/igb/igb_main.c +++ b/drivers/net/igb/igb_main.c | |||
| @@ -38,10 +38,11 @@ | |||
| 38 | #include <linux/ethtool.h> | 38 | #include <linux/ethtool.h> |
| 39 | #include <linux/if_vlan.h> | 39 | #include <linux/if_vlan.h> |
| 40 | #include <linux/pci.h> | 40 | #include <linux/pci.h> |
| 41 | #include <linux/pci-aspm.h> | ||
| 41 | #include <linux/delay.h> | 42 | #include <linux/delay.h> |
| 42 | #include <linux/interrupt.h> | 43 | #include <linux/interrupt.h> |
| 43 | #include <linux/if_ether.h> | 44 | #include <linux/if_ether.h> |
| 44 | #ifdef CONFIG_DCA | 45 | #ifdef CONFIG_IGB_DCA |
| 45 | #include <linux/dca.h> | 46 | #include <linux/dca.h> |
| 46 | #endif | 47 | #endif |
| 47 | #include "igb.h" | 48 | #include "igb.h" |
| @@ -106,11 +107,11 @@ static irqreturn_t igb_msix_other(int irq, void *); | |||
| 106 | static irqreturn_t igb_msix_rx(int irq, void *); | 107 | static irqreturn_t igb_msix_rx(int irq, void *); |
| 107 | static irqreturn_t igb_msix_tx(int irq, void *); | 108 | static irqreturn_t igb_msix_tx(int irq, void *); |
| 108 | static int igb_clean_rx_ring_msix(struct napi_struct *, int); | 109 | static int igb_clean_rx_ring_msix(struct napi_struct *, int); |
| 109 | #ifdef CONFIG_DCA | 110 | #ifdef CONFIG_IGB_DCA |
| 110 | static void igb_update_rx_dca(struct igb_ring *); | 111 | static void igb_update_rx_dca(struct igb_ring *); |
| 111 | static void igb_update_tx_dca(struct igb_ring *); | 112 | static void igb_update_tx_dca(struct igb_ring *); |
| 112 | static void igb_setup_dca(struct igb_adapter *); | 113 | static void igb_setup_dca(struct igb_adapter *); |
| 113 | #endif /* CONFIG_DCA */ | 114 | #endif /* CONFIG_IGB_DCA */ |
| 114 | static bool igb_clean_tx_irq(struct igb_ring *); | 115 | static bool igb_clean_tx_irq(struct igb_ring *); |
| 115 | static int igb_poll(struct napi_struct *, int); | 116 | static int igb_poll(struct napi_struct *, int); |
| 116 | static bool igb_clean_rx_irq_adv(struct igb_ring *, int *, int); | 117 | static bool igb_clean_rx_irq_adv(struct igb_ring *, int *, int); |
| @@ -131,7 +132,7 @@ static int igb_suspend(struct pci_dev *, pm_message_t); | |||
| 131 | static int igb_resume(struct pci_dev *); | 132 | static int igb_resume(struct pci_dev *); |
| 132 | #endif | 133 | #endif |
| 133 | static void igb_shutdown(struct pci_dev *); | 134 | static void igb_shutdown(struct pci_dev *); |
| 134 | #ifdef CONFIG_DCA | 135 | #ifdef CONFIG_IGB_DCA |
| 135 | static int igb_notify_dca(struct notifier_block *, unsigned long, void *); | 136 | static int igb_notify_dca(struct notifier_block *, unsigned long, void *); |
| 136 | static struct notifier_block dca_notifier = { | 137 | static struct notifier_block dca_notifier = { |
| 137 | .notifier_call = igb_notify_dca, | 138 | .notifier_call = igb_notify_dca, |
| @@ -207,7 +208,7 @@ static int __init igb_init_module(void) | |||
| 207 | global_quad_port_a = 0; | 208 | global_quad_port_a = 0; |
| 208 | 209 | ||
| 209 | ret = pci_register_driver(&igb_driver); | 210 | ret = pci_register_driver(&igb_driver); |
| 210 | #ifdef CONFIG_DCA | 211 | #ifdef CONFIG_IGB_DCA |
| 211 | dca_register_notify(&dca_notifier); | 212 | dca_register_notify(&dca_notifier); |
| 212 | #endif | 213 | #endif |
| 213 | return ret; | 214 | return ret; |
| @@ -223,7 +224,7 @@ module_init(igb_init_module); | |||
| 223 | **/ | 224 | **/ |
| 224 | static void __exit igb_exit_module(void) | 225 | static void __exit igb_exit_module(void) |
| 225 | { | 226 | { |
| 226 | #ifdef CONFIG_DCA | 227 | #ifdef CONFIG_IGB_DCA |
| 227 | dca_unregister_notify(&dca_notifier); | 228 | dca_unregister_notify(&dca_notifier); |
| 228 | #endif | 229 | #endif |
| 229 | pci_unregister_driver(&igb_driver); | 230 | pci_unregister_driver(&igb_driver); |
| @@ -966,10 +967,11 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
| 966 | struct net_device *netdev; | 967 | struct net_device *netdev; |
| 967 | struct igb_adapter *adapter; | 968 | struct igb_adapter *adapter; |
| 968 | struct e1000_hw *hw; | 969 | struct e1000_hw *hw; |
| 970 | struct pci_dev *us_dev; | ||
| 969 | const struct e1000_info *ei = igb_info_tbl[ent->driver_data]; | 971 | const struct e1000_info *ei = igb_info_tbl[ent->driver_data]; |
| 970 | unsigned long mmio_start, mmio_len; | 972 | unsigned long mmio_start, mmio_len; |
| 971 | int i, err, pci_using_dac; | 973 | int i, err, pci_using_dac, pos; |
| 972 | u16 eeprom_data = 0; | 974 | u16 eeprom_data = 0, state = 0; |
| 973 | u16 eeprom_apme_mask = IGB_EEPROM_APME; | 975 | u16 eeprom_apme_mask = IGB_EEPROM_APME; |
| 974 | u32 part_num; | 976 | u32 part_num; |
| 975 | int bars, need_ioport; | 977 | int bars, need_ioport; |
| @@ -1004,6 +1006,28 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
| 1004 | } | 1006 | } |
| 1005 | } | 1007 | } |
| 1006 | 1008 | ||
| 1009 | /* 82575 requires that the pci-e link partner disable the L0s state */ | ||
| 1010 | switch (pdev->device) { | ||
| 1011 | case E1000_DEV_ID_82575EB_COPPER: | ||
| 1012 | case E1000_DEV_ID_82575EB_FIBER_SERDES: | ||
| 1013 | case E1000_DEV_ID_82575GB_QUAD_COPPER: | ||
| 1014 | us_dev = pdev->bus->self; | ||
| 1015 | pos = pci_find_capability(us_dev, PCI_CAP_ID_EXP); | ||
| 1016 | if (pos) { | ||
| 1017 | pci_read_config_word(us_dev, pos + PCI_EXP_LNKCTL, | ||
| 1018 | &state); | ||
| 1019 | state &= ~PCIE_LINK_STATE_L0S; | ||
| 1020 | pci_write_config_word(us_dev, pos + PCI_EXP_LNKCTL, | ||
| 1021 | state); | ||
| 1022 | printk(KERN_INFO "Disabling ASPM L0s upstream switch " | ||
| 1023 | "port %x:%x.%x\n", us_dev->bus->number, | ||
| 1024 | PCI_SLOT(us_dev->devfn), | ||
| 1025 | PCI_FUNC(us_dev->devfn)); | ||
| 1026 | } | ||
| 1027 | default: | ||
| 1028 | break; | ||
| 1029 | } | ||
| 1030 | |||
| 1007 | err = pci_request_selected_regions(pdev, bars, igb_driver_name); | 1031 | err = pci_request_selected_regions(pdev, bars, igb_driver_name); |
| 1008 | if (err) | 1032 | if (err) |
| 1009 | goto err_pci_reg; | 1033 | goto err_pci_reg; |
| @@ -1237,7 +1261,7 @@ static int __devinit igb_probe(struct pci_dev *pdev, | |||
| 1237 | if (err) | 1261 | if (err) |
| 1238 | goto err_register; | 1262 | goto err_register; |
| 1239 | 1263 | ||
| 1240 | #ifdef CONFIG_DCA | 1264 | #ifdef CONFIG_IGB_DCA |
| 1241 | if ((adapter->flags & IGB_FLAG_HAS_DCA) && | 1265 | if ((adapter->flags & IGB_FLAG_HAS_DCA) && |
| 1242 | (dca_add_requester(&pdev->dev) == 0)) { | 1266 | (dca_add_requester(&pdev->dev) == 0)) { |
| 1243 | adapter->flags |= IGB_FLAG_DCA_ENABLED; | 1267 | adapter->flags |= IGB_FLAG_DCA_ENABLED; |
| @@ -1311,7 +1335,7 @@ static void __devexit igb_remove(struct pci_dev *pdev) | |||
| 1311 | { | 1335 | { |
| 1312 | struct net_device *netdev = pci_get_drvdata(pdev); | 1336 | struct net_device *netdev = pci_get_drvdata(pdev); |
| 1313 | struct igb_adapter *adapter = netdev_priv(netdev); | 1337 | struct igb_adapter *adapter = netdev_priv(netdev); |
| 1314 | #ifdef CONFIG_DCA | 1338 | #ifdef CONFIG_IGB_DCA |
| 1315 | struct e1000_hw *hw = &adapter->hw; | 1339 | struct e1000_hw *hw = &adapter->hw; |
| 1316 | #endif | 1340 | #endif |
| 1317 | 1341 | ||
| @@ -1323,7 +1347,7 @@ static void __devexit igb_remove(struct pci_dev *pdev) | |||
| 1323 | 1347 | ||
| 1324 | flush_scheduled_work(); | 1348 | flush_scheduled_work(); |
| 1325 | 1349 | ||
| 1326 | #ifdef CONFIG_DCA | 1350 | #ifdef CONFIG_IGB_DCA |
| 1327 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) { | 1351 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) { |
| 1328 | dev_info(&pdev->dev, "DCA disabled\n"); | 1352 | dev_info(&pdev->dev, "DCA disabled\n"); |
| 1329 | dca_remove_requester(&pdev->dev); | 1353 | dca_remove_requester(&pdev->dev); |
| @@ -3271,7 +3295,7 @@ static irqreturn_t igb_msix_tx(int irq, void *data) | |||
| 3271 | struct igb_adapter *adapter = tx_ring->adapter; | 3295 | struct igb_adapter *adapter = tx_ring->adapter; |
| 3272 | struct e1000_hw *hw = &adapter->hw; | 3296 | struct e1000_hw *hw = &adapter->hw; |
| 3273 | 3297 | ||
| 3274 | #ifdef CONFIG_DCA | 3298 | #ifdef CONFIG_IGB_DCA |
| 3275 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3299 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
| 3276 | igb_update_tx_dca(tx_ring); | 3300 | igb_update_tx_dca(tx_ring); |
| 3277 | #endif | 3301 | #endif |
| @@ -3323,14 +3347,14 @@ static irqreturn_t igb_msix_rx(int irq, void *data) | |||
| 3323 | if (netif_rx_schedule_prep(adapter->netdev, &rx_ring->napi)) | 3347 | if (netif_rx_schedule_prep(adapter->netdev, &rx_ring->napi)) |
| 3324 | __netif_rx_schedule(adapter->netdev, &rx_ring->napi); | 3348 | __netif_rx_schedule(adapter->netdev, &rx_ring->napi); |
| 3325 | 3349 | ||
| 3326 | #ifdef CONFIG_DCA | 3350 | #ifdef CONFIG_IGB_DCA |
| 3327 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3351 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
| 3328 | igb_update_rx_dca(rx_ring); | 3352 | igb_update_rx_dca(rx_ring); |
| 3329 | #endif | 3353 | #endif |
| 3330 | return IRQ_HANDLED; | 3354 | return IRQ_HANDLED; |
| 3331 | } | 3355 | } |
| 3332 | 3356 | ||
| 3333 | #ifdef CONFIG_DCA | 3357 | #ifdef CONFIG_IGB_DCA |
| 3334 | static void igb_update_rx_dca(struct igb_ring *rx_ring) | 3358 | static void igb_update_rx_dca(struct igb_ring *rx_ring) |
| 3335 | { | 3359 | { |
| 3336 | u32 dca_rxctrl; | 3360 | u32 dca_rxctrl; |
| @@ -3450,7 +3474,7 @@ static int igb_notify_dca(struct notifier_block *nb, unsigned long event, | |||
| 3450 | 3474 | ||
| 3451 | return ret_val ? NOTIFY_BAD : NOTIFY_DONE; | 3475 | return ret_val ? NOTIFY_BAD : NOTIFY_DONE; |
| 3452 | } | 3476 | } |
| 3453 | #endif /* CONFIG_DCA */ | 3477 | #endif /* CONFIG_IGB_DCA */ |
| 3454 | 3478 | ||
| 3455 | /** | 3479 | /** |
| 3456 | * igb_intr_msi - Interrupt Handler | 3480 | * igb_intr_msi - Interrupt Handler |
| @@ -3529,13 +3553,13 @@ static int igb_poll(struct napi_struct *napi, int budget) | |||
| 3529 | int tx_clean_complete, work_done = 0; | 3553 | int tx_clean_complete, work_done = 0; |
| 3530 | 3554 | ||
| 3531 | /* this poll routine only supports one tx and one rx queue */ | 3555 | /* this poll routine only supports one tx and one rx queue */ |
| 3532 | #ifdef CONFIG_DCA | 3556 | #ifdef CONFIG_IGB_DCA |
| 3533 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3557 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
| 3534 | igb_update_tx_dca(&adapter->tx_ring[0]); | 3558 | igb_update_tx_dca(&adapter->tx_ring[0]); |
| 3535 | #endif | 3559 | #endif |
| 3536 | tx_clean_complete = igb_clean_tx_irq(&adapter->tx_ring[0]); | 3560 | tx_clean_complete = igb_clean_tx_irq(&adapter->tx_ring[0]); |
| 3537 | 3561 | ||
| 3538 | #ifdef CONFIG_DCA | 3562 | #ifdef CONFIG_IGB_DCA |
| 3539 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3563 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
| 3540 | igb_update_rx_dca(&adapter->rx_ring[0]); | 3564 | igb_update_rx_dca(&adapter->rx_ring[0]); |
| 3541 | #endif | 3565 | #endif |
| @@ -3563,7 +3587,7 @@ static int igb_clean_rx_ring_msix(struct napi_struct *napi, int budget) | |||
| 3563 | struct net_device *netdev = adapter->netdev; | 3587 | struct net_device *netdev = adapter->netdev; |
| 3564 | int work_done = 0; | 3588 | int work_done = 0; |
| 3565 | 3589 | ||
| 3566 | #ifdef CONFIG_DCA | 3590 | #ifdef CONFIG_IGB_DCA |
| 3567 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) | 3591 | if (adapter->flags & IGB_FLAG_DCA_ENABLED) |
| 3568 | igb_update_rx_dca(rx_ring); | 3592 | igb_update_rx_dca(rx_ring); |
| 3569 | #endif | 3593 | #endif |
diff --git a/drivers/net/myri10ge/myri10ge.c b/drivers/net/myri10ge/myri10ge.c index a9aebad52652..b1556b2e404c 100644 --- a/drivers/net/myri10ge/myri10ge.c +++ b/drivers/net/myri10ge/myri10ge.c | |||
| @@ -75,7 +75,7 @@ | |||
| 75 | #include "myri10ge_mcp.h" | 75 | #include "myri10ge_mcp.h" |
| 76 | #include "myri10ge_mcp_gen_header.h" | 76 | #include "myri10ge_mcp_gen_header.h" |
| 77 | 77 | ||
| 78 | #define MYRI10GE_VERSION_STR "1.4.3-1.369" | 78 | #define MYRI10GE_VERSION_STR "1.4.3-1.371" |
| 79 | 79 | ||
| 80 | MODULE_DESCRIPTION("Myricom 10G driver (10GbE)"); | 80 | MODULE_DESCRIPTION("Myricom 10G driver (10GbE)"); |
| 81 | MODULE_AUTHOR("Maintainer: help@myri.com"); | 81 | MODULE_AUTHOR("Maintainer: help@myri.com"); |
| @@ -2497,6 +2497,10 @@ static int myri10ge_open(struct net_device *dev) | |||
| 2497 | return 0; | 2497 | return 0; |
| 2498 | 2498 | ||
| 2499 | abort_with_rings: | 2499 | abort_with_rings: |
| 2500 | while (slice) { | ||
| 2501 | slice--; | ||
| 2502 | napi_disable(&mgp->ss[slice].napi); | ||
| 2503 | } | ||
| 2500 | for (i = 0; i < mgp->num_slices; i++) | 2504 | for (i = 0; i < mgp->num_slices; i++) |
| 2501 | myri10ge_free_rings(&mgp->ss[i]); | 2505 | myri10ge_free_rings(&mgp->ss[i]); |
| 2502 | 2506 | ||
diff --git a/drivers/net/qlge/qlge.h b/drivers/net/qlge/qlge.h index 38116f9d4163..ba2e1c5b6bcf 100644 --- a/drivers/net/qlge/qlge.h +++ b/drivers/net/qlge/qlge.h | |||
| @@ -1375,7 +1375,6 @@ struct ql_adapter { | |||
| 1375 | spinlock_t adapter_lock; | 1375 | spinlock_t adapter_lock; |
| 1376 | spinlock_t hw_lock; | 1376 | spinlock_t hw_lock; |
| 1377 | spinlock_t stats_lock; | 1377 | spinlock_t stats_lock; |
| 1378 | spinlock_t legacy_lock; /* used for maintaining legacy intr sync */ | ||
| 1379 | 1378 | ||
| 1380 | /* PCI Bus Relative Register Addresses */ | 1379 | /* PCI Bus Relative Register Addresses */ |
| 1381 | void __iomem *reg_base; | 1380 | void __iomem *reg_base; |
| @@ -1399,8 +1398,6 @@ struct ql_adapter { | |||
| 1399 | struct msix_entry *msi_x_entry; | 1398 | struct msix_entry *msi_x_entry; |
| 1400 | struct intr_context intr_context[MAX_RX_RINGS]; | 1399 | struct intr_context intr_context[MAX_RX_RINGS]; |
| 1401 | 1400 | ||
| 1402 | int (*legacy_check) (struct ql_adapter *); | ||
| 1403 | |||
| 1404 | int tx_ring_count; /* One per online CPU. */ | 1401 | int tx_ring_count; /* One per online CPU. */ |
| 1405 | u32 rss_ring_first_cq_id;/* index of first inbound (rss) rx_ring */ | 1402 | u32 rss_ring_first_cq_id;/* index of first inbound (rss) rx_ring */ |
| 1406 | u32 rss_ring_count; /* One per online CPU. */ | 1403 | u32 rss_ring_count; /* One per online CPU. */ |
| @@ -1502,7 +1499,7 @@ void ql_mpi_work(struct work_struct *work); | |||
| 1502 | void ql_mpi_reset_work(struct work_struct *work); | 1499 | void ql_mpi_reset_work(struct work_struct *work); |
| 1503 | int ql_wait_reg_rdy(struct ql_adapter *qdev, u32 reg, u32 bit, u32 ebit); | 1500 | int ql_wait_reg_rdy(struct ql_adapter *qdev, u32 reg, u32 bit, u32 ebit); |
| 1504 | void ql_queue_asic_error(struct ql_adapter *qdev); | 1501 | void ql_queue_asic_error(struct ql_adapter *qdev); |
| 1505 | void ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr); | 1502 | u32 ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr); |
| 1506 | void ql_set_ethtool_ops(struct net_device *ndev); | 1503 | void ql_set_ethtool_ops(struct net_device *ndev); |
| 1507 | int ql_read_xgmac_reg64(struct ql_adapter *qdev, u32 reg, u64 *data); | 1504 | int ql_read_xgmac_reg64(struct ql_adapter *qdev, u32 reg, u64 *data); |
| 1508 | 1505 | ||
diff --git a/drivers/net/qlge/qlge_main.c b/drivers/net/qlge/qlge_main.c index 4b2caa6b7ac5..b83a9c9b6a97 100644 --- a/drivers/net/qlge/qlge_main.c +++ b/drivers/net/qlge/qlge_main.c | |||
| @@ -577,41 +577,53 @@ static void ql_disable_interrupts(struct ql_adapter *qdev) | |||
| 577 | * incremented everytime we queue a worker and decremented everytime | 577 | * incremented everytime we queue a worker and decremented everytime |
| 578 | * a worker finishes. Once it hits zero we enable the interrupt. | 578 | * a worker finishes. Once it hits zero we enable the interrupt. |
| 579 | */ | 579 | */ |
| 580 | void ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr) | 580 | u32 ql_enable_completion_interrupt(struct ql_adapter *qdev, u32 intr) |
| 581 | { | 581 | { |
| 582 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags))) | 582 | u32 var = 0; |
| 583 | unsigned long hw_flags = 0; | ||
| 584 | struct intr_context *ctx = qdev->intr_context + intr; | ||
| 585 | |||
| 586 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags) && intr)) { | ||
| 587 | /* Always enable if we're MSIX multi interrupts and | ||
| 588 | * it's not the default (zeroeth) interrupt. | ||
| 589 | */ | ||
| 583 | ql_write32(qdev, INTR_EN, | 590 | ql_write32(qdev, INTR_EN, |
| 584 | qdev->intr_context[intr].intr_en_mask); | 591 | ctx->intr_en_mask); |
| 585 | else { | 592 | var = ql_read32(qdev, STS); |
| 586 | if (qdev->legacy_check) | 593 | return var; |
| 587 | spin_lock(&qdev->legacy_lock); | ||
| 588 | if (atomic_dec_and_test(&qdev->intr_context[intr].irq_cnt)) { | ||
| 589 | QPRINTK(qdev, INTR, ERR, "Enabling interrupt %d.\n", | ||
| 590 | intr); | ||
| 591 | ql_write32(qdev, INTR_EN, | ||
| 592 | qdev->intr_context[intr].intr_en_mask); | ||
| 593 | } else { | ||
| 594 | QPRINTK(qdev, INTR, ERR, | ||
| 595 | "Skip enable, other queue(s) are active.\n"); | ||
| 596 | } | ||
| 597 | if (qdev->legacy_check) | ||
| 598 | spin_unlock(&qdev->legacy_lock); | ||
| 599 | } | 594 | } |
| 595 | |||
| 596 | spin_lock_irqsave(&qdev->hw_lock, hw_flags); | ||
| 597 | if (atomic_dec_and_test(&ctx->irq_cnt)) { | ||
| 598 | ql_write32(qdev, INTR_EN, | ||
| 599 | ctx->intr_en_mask); | ||
| 600 | var = ql_read32(qdev, STS); | ||
| 601 | } | ||
| 602 | spin_unlock_irqrestore(&qdev->hw_lock, hw_flags); | ||
| 603 | return var; | ||
| 600 | } | 604 | } |
| 601 | 605 | ||
| 602 | static u32 ql_disable_completion_interrupt(struct ql_adapter *qdev, u32 intr) | 606 | static u32 ql_disable_completion_interrupt(struct ql_adapter *qdev, u32 intr) |
| 603 | { | 607 | { |
| 604 | u32 var = 0; | 608 | u32 var = 0; |
| 609 | unsigned long hw_flags; | ||
| 610 | struct intr_context *ctx; | ||
| 605 | 611 | ||
| 606 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags))) | 612 | /* HW disables for us if we're MSIX multi interrupts and |
| 607 | goto exit; | 613 | * it's not the default (zeroeth) interrupt. |
| 608 | else if (!atomic_read(&qdev->intr_context[intr].irq_cnt)) { | 614 | */ |
| 615 | if (likely(test_bit(QL_MSIX_ENABLED, &qdev->flags) && intr)) | ||
| 616 | return 0; | ||
| 617 | |||
| 618 | ctx = qdev->intr_context + intr; | ||
| 619 | spin_lock_irqsave(&qdev->hw_lock, hw_flags); | ||
| 620 | if (!atomic_read(&ctx->irq_cnt)) { | ||
| 609 | ql_write32(qdev, INTR_EN, | 621 | ql_write32(qdev, INTR_EN, |
| 610 | qdev->intr_context[intr].intr_dis_mask); | 622 | ctx->intr_dis_mask); |
| 611 | var = ql_read32(qdev, STS); | 623 | var = ql_read32(qdev, STS); |
| 612 | } | 624 | } |
| 613 | atomic_inc(&qdev->intr_context[intr].irq_cnt); | 625 | atomic_inc(&ctx->irq_cnt); |
| 614 | exit: | 626 | spin_unlock_irqrestore(&qdev->hw_lock, hw_flags); |
| 615 | return var; | 627 | return var; |
| 616 | } | 628 | } |
| 617 | 629 | ||
| @@ -623,7 +635,9 @@ static void ql_enable_all_completion_interrupts(struct ql_adapter *qdev) | |||
| 623 | * and enables only if the result is zero. | 635 | * and enables only if the result is zero. |
| 624 | * So we precharge it here. | 636 | * So we precharge it here. |
| 625 | */ | 637 | */ |
| 626 | atomic_set(&qdev->intr_context[i].irq_cnt, 1); | 638 | if (unlikely(!test_bit(QL_MSIX_ENABLED, &qdev->flags) || |
| 639 | i == 0)) | ||
| 640 | atomic_set(&qdev->intr_context[i].irq_cnt, 1); | ||
| 627 | ql_enable_completion_interrupt(qdev, i); | 641 | ql_enable_completion_interrupt(qdev, i); |
| 628 | } | 642 | } |
| 629 | 643 | ||
| @@ -1725,19 +1739,6 @@ static irqreturn_t qlge_msix_rx_isr(int irq, void *dev_id) | |||
| 1725 | return IRQ_HANDLED; | 1739 | return IRQ_HANDLED; |
| 1726 | } | 1740 | } |
| 1727 | 1741 | ||
| 1728 | /* We check here to see if we're already handling a legacy | ||
| 1729 | * interrupt. If we are, then it must belong to another | ||
| 1730 | * chip with which we're sharing the interrupt line. | ||
| 1731 | */ | ||
| 1732 | int ql_legacy_check(struct ql_adapter *qdev) | ||
| 1733 | { | ||
| 1734 | int err; | ||
| 1735 | spin_lock(&qdev->legacy_lock); | ||
| 1736 | err = atomic_read(&qdev->intr_context[0].irq_cnt); | ||
| 1737 | spin_unlock(&qdev->legacy_lock); | ||
| 1738 | return err; | ||
| 1739 | } | ||
| 1740 | |||
| 1741 | /* This handles a fatal error, MPI activity, and the default | 1742 | /* This handles a fatal error, MPI activity, and the default |
| 1742 | * rx_ring in an MSI-X multiple vector environment. | 1743 | * rx_ring in an MSI-X multiple vector environment. |
| 1743 | * In MSI/Legacy environment it also process the rest of | 1744 | * In MSI/Legacy environment it also process the rest of |
| @@ -1752,12 +1753,15 @@ static irqreturn_t qlge_isr(int irq, void *dev_id) | |||
| 1752 | int i; | 1753 | int i; |
| 1753 | int work_done = 0; | 1754 | int work_done = 0; |
| 1754 | 1755 | ||
| 1755 | if (qdev->legacy_check && qdev->legacy_check(qdev)) { | 1756 | spin_lock(&qdev->hw_lock); |
| 1756 | QPRINTK(qdev, INTR, INFO, "Already busy, not our interrupt.\n"); | 1757 | if (atomic_read(&qdev->intr_context[0].irq_cnt)) { |
| 1757 | return IRQ_NONE; /* Not our interrupt */ | 1758 | QPRINTK(qdev, INTR, DEBUG, "Shared Interrupt, Not ours!\n"); |
| 1759 | spin_unlock(&qdev->hw_lock); | ||
| 1760 | return IRQ_NONE; | ||
| 1758 | } | 1761 | } |
| 1762 | spin_unlock(&qdev->hw_lock); | ||
| 1759 | 1763 | ||
| 1760 | var = ql_read32(qdev, STS); | 1764 | var = ql_disable_completion_interrupt(qdev, intr_context->intr); |
| 1761 | 1765 | ||
| 1762 | /* | 1766 | /* |
| 1763 | * Check for fatal error. | 1767 | * Check for fatal error. |
| @@ -1823,6 +1827,7 @@ static irqreturn_t qlge_isr(int irq, void *dev_id) | |||
| 1823 | } | 1827 | } |
| 1824 | } | 1828 | } |
| 1825 | } | 1829 | } |
| 1830 | ql_enable_completion_interrupt(qdev, intr_context->intr); | ||
| 1826 | return work_done ? IRQ_HANDLED : IRQ_NONE; | 1831 | return work_done ? IRQ_HANDLED : IRQ_NONE; |
| 1827 | } | 1832 | } |
| 1828 | 1833 | ||
| @@ -2701,8 +2706,6 @@ msi: | |||
| 2701 | } | 2706 | } |
| 2702 | } | 2707 | } |
| 2703 | irq_type = LEG_IRQ; | 2708 | irq_type = LEG_IRQ; |
| 2704 | spin_lock_init(&qdev->legacy_lock); | ||
| 2705 | qdev->legacy_check = ql_legacy_check; | ||
| 2706 | QPRINTK(qdev, IFUP, DEBUG, "Running with legacy interrupts.\n"); | 2709 | QPRINTK(qdev, IFUP, DEBUG, "Running with legacy interrupts.\n"); |
| 2707 | } | 2710 | } |
| 2708 | 2711 | ||
diff --git a/drivers/net/r8169.c b/drivers/net/r8169.c index c821da21d8eb..2b4e975770f3 100644 --- a/drivers/net/r8169.c +++ b/drivers/net/r8169.c | |||
| @@ -81,6 +81,10 @@ static const int multicast_filter_limit = 32; | |||
| 81 | #define RTL8169_TX_TIMEOUT (6*HZ) | 81 | #define RTL8169_TX_TIMEOUT (6*HZ) |
| 82 | #define RTL8169_PHY_TIMEOUT (10*HZ) | 82 | #define RTL8169_PHY_TIMEOUT (10*HZ) |
| 83 | 83 | ||
| 84 | #define RTL_EEPROM_SIG cpu_to_le32(0x8129) | ||
| 85 | #define RTL_EEPROM_SIG_MASK cpu_to_le32(0xffff) | ||
| 86 | #define RTL_EEPROM_SIG_ADDR 0x0000 | ||
| 87 | |||
| 84 | /* write/read MMIO register */ | 88 | /* write/read MMIO register */ |
| 85 | #define RTL_W8(reg, val8) writeb ((val8), ioaddr + (reg)) | 89 | #define RTL_W8(reg, val8) writeb ((val8), ioaddr + (reg)) |
| 86 | #define RTL_W16(reg, val16) writew ((val16), ioaddr + (reg)) | 90 | #define RTL_W16(reg, val16) writew ((val16), ioaddr + (reg)) |
| @@ -1944,14 +1948,15 @@ static void rtl_init_mac_address(struct rtl8169_private *tp, | |||
| 1944 | void __iomem *ioaddr) | 1948 | void __iomem *ioaddr) |
| 1945 | { | 1949 | { |
| 1946 | struct pci_dev *pdev = tp->pci_dev; | 1950 | struct pci_dev *pdev = tp->pci_dev; |
| 1947 | u8 cfg1; | ||
| 1948 | int vpd_cap; | 1951 | int vpd_cap; |
| 1952 | __le32 sig; | ||
| 1949 | u8 mac[8]; | 1953 | u8 mac[8]; |
| 1950 | DECLARE_MAC_BUF(buf); | 1954 | u8 cfg1; |
| 1951 | 1955 | ||
| 1952 | cfg1 = RTL_R8(Config1); | 1956 | cfg1 = RTL_R8(Config1); |
| 1953 | if (!(cfg1 & VPD)) { | 1957 | if (!(cfg1 & VPD)) { |
| 1954 | dprintk("VPD access not enabled, enabling\n"); | 1958 | if (netif_msg_probe(tp)) |
| 1959 | dev_info(&pdev->dev, "VPD access disabled, enabling\n"); | ||
| 1955 | RTL_W8(Cfg9346, Cfg9346_Unlock); | 1960 | RTL_W8(Cfg9346, Cfg9346_Unlock); |
| 1956 | RTL_W8(Config1, cfg1 | VPD); | 1961 | RTL_W8(Config1, cfg1 | VPD); |
| 1957 | RTL_W8(Cfg9346, Cfg9346_Lock); | 1962 | RTL_W8(Cfg9346, Cfg9346_Lock); |
| @@ -1961,7 +1966,16 @@ static void rtl_init_mac_address(struct rtl8169_private *tp, | |||
| 1961 | if (!vpd_cap) | 1966 | if (!vpd_cap) |
| 1962 | return; | 1967 | return; |
| 1963 | 1968 | ||
| 1964 | /* MAC address is stored in EEPROM at offset 0x0e | 1969 | if (rtl_eeprom_read(pdev, vpd_cap, RTL_EEPROM_SIG_ADDR, &sig) < 0) |
| 1970 | return; | ||
| 1971 | |||
| 1972 | if ((sig & RTL_EEPROM_SIG_MASK) != RTL_EEPROM_SIG) { | ||
| 1973 | dev_info(&pdev->dev, "Missing EEPROM signature: %08x\n", sig); | ||
| 1974 | return; | ||
| 1975 | } | ||
| 1976 | |||
| 1977 | /* | ||
| 1978 | * MAC address is stored in EEPROM at offset 0x0e | ||
| 1965 | * Realtek says: "The VPD address does not have to be a DWORD-aligned | 1979 | * Realtek says: "The VPD address does not have to be a DWORD-aligned |
| 1966 | * address as defined in the PCI 2.2 Specifications, but the VPD data | 1980 | * address as defined in the PCI 2.2 Specifications, but the VPD data |
| 1967 | * is always consecutive 4-byte data starting from the VPD address | 1981 | * is always consecutive 4-byte data starting from the VPD address |
| @@ -1969,14 +1983,22 @@ static void rtl_init_mac_address(struct rtl8169_private *tp, | |||
| 1969 | */ | 1983 | */ |
| 1970 | if (rtl_eeprom_read(pdev, vpd_cap, 0x000e, (__le32*)&mac[0]) < 0 || | 1984 | if (rtl_eeprom_read(pdev, vpd_cap, 0x000e, (__le32*)&mac[0]) < 0 || |
| 1971 | rtl_eeprom_read(pdev, vpd_cap, 0x0012, (__le32*)&mac[4]) < 0) { | 1985 | rtl_eeprom_read(pdev, vpd_cap, 0x0012, (__le32*)&mac[4]) < 0) { |
| 1972 | dprintk("Reading MAC address from EEPROM failed\n"); | 1986 | if (netif_msg_probe(tp)) { |
| 1987 | dev_warn(&pdev->dev, | ||
| 1988 | "reading MAC address from EEPROM failed\n"); | ||
| 1989 | } | ||
| 1973 | return; | 1990 | return; |
| 1974 | } | 1991 | } |
| 1975 | 1992 | ||
| 1976 | dprintk("MAC address found in EEPROM: %s\n", print_mac(buf, mac)); | 1993 | if (netif_msg_probe(tp)) { |
| 1994 | DECLARE_MAC_BUF(buf); | ||
| 1995 | |||
| 1996 | dev_info(&pdev->dev, "MAC address found in EEPROM: %s\n", | ||
| 1997 | print_mac(buf, mac)); | ||
| 1998 | } | ||
| 1977 | 1999 | ||
| 1978 | /* Write MAC address */ | 2000 | if (is_valid_ether_addr(mac)) |
| 1979 | rtl_rar_set(tp, mac); | 2001 | rtl_rar_set(tp, mac); |
| 1980 | } | 2002 | } |
| 1981 | 2003 | ||
| 1982 | static int __devinit | 2004 | static int __devinit |
diff --git a/drivers/net/sis190.c b/drivers/net/sis190.c index 3fe01763760e..e6e3bf58a569 100644 --- a/drivers/net/sis190.c +++ b/drivers/net/sis190.c | |||
| @@ -317,6 +317,7 @@ static struct mii_chip_info { | |||
| 317 | unsigned int type; | 317 | unsigned int type; |
| 318 | u32 feature; | 318 | u32 feature; |
| 319 | } mii_chip_table[] = { | 319 | } mii_chip_table[] = { |
| 320 | { "Atheros PHY AR8012", { 0x004d, 0xd020 }, LAN, 0 }, | ||
| 320 | { "Broadcom PHY BCM5461", { 0x0020, 0x60c0 }, LAN, F_PHY_BCM5461 }, | 321 | { "Broadcom PHY BCM5461", { 0x0020, 0x60c0 }, LAN, F_PHY_BCM5461 }, |
| 321 | { "Broadcom PHY AC131", { 0x0143, 0xbc70 }, LAN, 0 }, | 322 | { "Broadcom PHY AC131", { 0x0143, 0xbc70 }, LAN, 0 }, |
| 322 | { "Agere PHY ET1101B", { 0x0282, 0xf010 }, LAN, 0 }, | 323 | { "Agere PHY ET1101B", { 0x0282, 0xf010 }, LAN, 0 }, |
diff --git a/drivers/net/smc911x.c b/drivers/net/smc911x.c index 8aa7460ef0e3..f59c7772f344 100644 --- a/drivers/net/smc911x.c +++ b/drivers/net/smc911x.c | |||
| @@ -155,23 +155,17 @@ static void PRINT_PKT(u_char *buf, int length) | |||
| 155 | /* this enables an interrupt in the interrupt mask register */ | 155 | /* this enables an interrupt in the interrupt mask register */ |
| 156 | #define SMC_ENABLE_INT(lp, x) do { \ | 156 | #define SMC_ENABLE_INT(lp, x) do { \ |
| 157 | unsigned int __mask; \ | 157 | unsigned int __mask; \ |
| 158 | unsigned long __flags; \ | ||
| 159 | spin_lock_irqsave(&lp->lock, __flags); \ | ||
| 160 | __mask = SMC_GET_INT_EN((lp)); \ | 158 | __mask = SMC_GET_INT_EN((lp)); \ |
| 161 | __mask |= (x); \ | 159 | __mask |= (x); \ |
| 162 | SMC_SET_INT_EN((lp), __mask); \ | 160 | SMC_SET_INT_EN((lp), __mask); \ |
| 163 | spin_unlock_irqrestore(&lp->lock, __flags); \ | ||
| 164 | } while (0) | 161 | } while (0) |
| 165 | 162 | ||
| 166 | /* this disables an interrupt from the interrupt mask register */ | 163 | /* this disables an interrupt from the interrupt mask register */ |
| 167 | #define SMC_DISABLE_INT(lp, x) do { \ | 164 | #define SMC_DISABLE_INT(lp, x) do { \ |
| 168 | unsigned int __mask; \ | 165 | unsigned int __mask; \ |
| 169 | unsigned long __flags; \ | ||
| 170 | spin_lock_irqsave(&lp->lock, __flags); \ | ||
| 171 | __mask = SMC_GET_INT_EN((lp)); \ | 166 | __mask = SMC_GET_INT_EN((lp)); \ |
| 172 | __mask &= ~(x); \ | 167 | __mask &= ~(x); \ |
| 173 | SMC_SET_INT_EN((lp), __mask); \ | 168 | SMC_SET_INT_EN((lp), __mask); \ |
| 174 | spin_unlock_irqrestore(&lp->lock, __flags); \ | ||
| 175 | } while (0) | 169 | } while (0) |
| 176 | 170 | ||
| 177 | /* | 171 | /* |
| @@ -180,7 +174,7 @@ static void PRINT_PKT(u_char *buf, int length) | |||
| 180 | static void smc911x_reset(struct net_device *dev) | 174 | static void smc911x_reset(struct net_device *dev) |
| 181 | { | 175 | { |
| 182 | struct smc911x_local *lp = netdev_priv(dev); | 176 | struct smc911x_local *lp = netdev_priv(dev); |
| 183 | unsigned int reg, timeout=0, resets=1; | 177 | unsigned int reg, timeout=0, resets=1, irq_cfg; |
| 184 | unsigned long flags; | 178 | unsigned long flags; |
| 185 | 179 | ||
| 186 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); | 180 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); |
| @@ -252,7 +246,12 @@ static void smc911x_reset(struct net_device *dev) | |||
| 252 | * Deassert IRQ for 1*10us for edge type interrupts | 246 | * Deassert IRQ for 1*10us for edge type interrupts |
| 253 | * and drive IRQ pin push-pull | 247 | * and drive IRQ pin push-pull |
| 254 | */ | 248 | */ |
| 255 | SMC_SET_IRQ_CFG(lp, (1 << 24) | INT_CFG_IRQ_EN_ | INT_CFG_IRQ_TYPE_); | 249 | irq_cfg = (1 << 24) | INT_CFG_IRQ_EN_ | INT_CFG_IRQ_TYPE_; |
| 250 | #ifdef SMC_DYNAMIC_BUS_CONFIG | ||
| 251 | if (lp->cfg.irq_polarity) | ||
| 252 | irq_cfg |= INT_CFG_IRQ_POL_; | ||
| 253 | #endif | ||
| 254 | SMC_SET_IRQ_CFG(lp, irq_cfg); | ||
| 256 | 255 | ||
| 257 | /* clear anything saved */ | 256 | /* clear anything saved */ |
| 258 | if (lp->pending_tx_skb != NULL) { | 257 | if (lp->pending_tx_skb != NULL) { |
| @@ -274,6 +273,8 @@ static void smc911x_enable(struct net_device *dev) | |||
| 274 | 273 | ||
| 275 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); | 274 | DBG(SMC_DEBUG_FUNC, "%s: --> %s\n", dev->name, __func__); |
| 276 | 275 | ||
| 276 | spin_lock_irqsave(&lp->lock, flags); | ||
| 277 | |||
| 277 | SMC_SET_MAC_ADDR(lp, dev->dev_addr); | 278 | SMC_SET_MAC_ADDR(lp, dev->dev_addr); |
| 278 | 279 | ||
| 279 | /* Enable TX */ | 280 | /* Enable TX */ |
| @@ -286,12 +287,10 @@ static void smc911x_enable(struct net_device *dev) | |||
| 286 | SMC_SET_FIFO_TSL(lp, 64); | 287 | SMC_SET_FIFO_TSL(lp, 64); |
| 287 | SMC_SET_GPT_CFG(lp, GPT_CFG_TIMER_EN_ | 10000); | 288 | SMC_SET_GPT_CFG(lp, GPT_CFG_TIMER_EN_ | 10000); |
| 288 | 289 | ||
| 289 | spin_lock_irqsave(&lp->lock, flags); | ||
| 290 | SMC_GET_MAC_CR(lp, cr); | 290 | SMC_GET_MAC_CR(lp, cr); |
| 291 | cr |= MAC_CR_TXEN_ | MAC_CR_HBDIS_; | 291 | cr |= MAC_CR_TXEN_ | MAC_CR_HBDIS_; |
| 292 | SMC_SET_MAC_CR(lp, cr); | 292 | SMC_SET_MAC_CR(lp, cr); |
| 293 | SMC_SET_TX_CFG(lp, TX_CFG_TX_ON_); | 293 | SMC_SET_TX_CFG(lp, TX_CFG_TX_ON_); |
| 294 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 295 | 294 | ||
| 296 | /* Add 2 byte padding to start of packets */ | 295 | /* Add 2 byte padding to start of packets */ |
| 297 | SMC_SET_RX_CFG(lp, (2<<8) & RX_CFG_RXDOFF_); | 296 | SMC_SET_RX_CFG(lp, (2<<8) & RX_CFG_RXDOFF_); |
| @@ -300,9 +299,7 @@ static void smc911x_enable(struct net_device *dev) | |||
| 300 | if (cr & MAC_CR_RXEN_) | 299 | if (cr & MAC_CR_RXEN_) |
| 301 | DBG(SMC_DEBUG_RX, "%s: Receiver already enabled\n", dev->name); | 300 | DBG(SMC_DEBUG_RX, "%s: Receiver already enabled\n", dev->name); |
| 302 | 301 | ||
| 303 | spin_lock_irqsave(&lp->lock, flags); | ||
| 304 | SMC_SET_MAC_CR(lp, cr | MAC_CR_RXEN_); | 302 | SMC_SET_MAC_CR(lp, cr | MAC_CR_RXEN_); |
| 305 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 306 | 303 | ||
| 307 | /* Interrupt on every received packet */ | 304 | /* Interrupt on every received packet */ |
| 308 | SMC_SET_FIFO_RSA(lp, 0x01); | 305 | SMC_SET_FIFO_RSA(lp, 0x01); |
| @@ -318,6 +315,8 @@ static void smc911x_enable(struct net_device *dev) | |||
| 318 | mask|=INT_EN_RDFO_EN_; | 315 | mask|=INT_EN_RDFO_EN_; |
| 319 | } | 316 | } |
| 320 | SMC_ENABLE_INT(lp, mask); | 317 | SMC_ENABLE_INT(lp, mask); |
| 318 | |||
| 319 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 321 | } | 320 | } |
| 322 | 321 | ||
| 323 | /* | 322 | /* |
| @@ -458,7 +457,6 @@ static void smc911x_hardware_send_pkt(struct net_device *dev) | |||
| 458 | struct sk_buff *skb; | 457 | struct sk_buff *skb; |
| 459 | unsigned int cmdA, cmdB, len; | 458 | unsigned int cmdA, cmdB, len; |
| 460 | unsigned char *buf; | 459 | unsigned char *buf; |
| 461 | unsigned long flags; | ||
| 462 | 460 | ||
| 463 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", dev->name, __func__); | 461 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", dev->name, __func__); |
| 464 | BUG_ON(lp->pending_tx_skb == NULL); | 462 | BUG_ON(lp->pending_tx_skb == NULL); |
| @@ -503,11 +501,9 @@ static void smc911x_hardware_send_pkt(struct net_device *dev) | |||
| 503 | dev->trans_start = jiffies; | 501 | dev->trans_start = jiffies; |
| 504 | dev_kfree_skb(skb); | 502 | dev_kfree_skb(skb); |
| 505 | #endif | 503 | #endif |
| 506 | spin_lock_irqsave(&lp->lock, flags); | ||
| 507 | if (!lp->tx_throttle) { | 504 | if (!lp->tx_throttle) { |
| 508 | netif_wake_queue(dev); | 505 | netif_wake_queue(dev); |
| 509 | } | 506 | } |
| 510 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 511 | SMC_ENABLE_INT(lp, INT_EN_TDFA_EN_ | INT_EN_TSFL_EN_); | 507 | SMC_ENABLE_INT(lp, INT_EN_TDFA_EN_ | INT_EN_TSFL_EN_); |
| 512 | } | 508 | } |
| 513 | 509 | ||
| @@ -526,6 +522,8 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
| 526 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", | 522 | DBG(SMC_DEBUG_FUNC | SMC_DEBUG_TX, "%s: --> %s\n", |
| 527 | dev->name, __func__); | 523 | dev->name, __func__); |
| 528 | 524 | ||
| 525 | spin_lock_irqsave(&lp->lock, flags); | ||
| 526 | |||
| 529 | BUG_ON(lp->pending_tx_skb != NULL); | 527 | BUG_ON(lp->pending_tx_skb != NULL); |
| 530 | 528 | ||
| 531 | free = SMC_GET_TX_FIFO_INF(lp) & TX_FIFO_INF_TDFREE_; | 529 | free = SMC_GET_TX_FIFO_INF(lp) & TX_FIFO_INF_TDFREE_; |
| @@ -535,12 +533,10 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
| 535 | if (free <= SMC911X_TX_FIFO_LOW_THRESHOLD) { | 533 | if (free <= SMC911X_TX_FIFO_LOW_THRESHOLD) { |
| 536 | DBG(SMC_DEBUG_TX, "%s: Disabling data flow due to low FIFO space (%d)\n", | 534 | DBG(SMC_DEBUG_TX, "%s: Disabling data flow due to low FIFO space (%d)\n", |
| 537 | dev->name, free); | 535 | dev->name, free); |
| 538 | spin_lock_irqsave(&lp->lock, flags); | ||
| 539 | /* Reenable when at least 1 packet of size MTU present */ | 536 | /* Reenable when at least 1 packet of size MTU present */ |
| 540 | SMC_SET_FIFO_TDA(lp, (SMC911X_TX_FIFO_LOW_THRESHOLD)/64); | 537 | SMC_SET_FIFO_TDA(lp, (SMC911X_TX_FIFO_LOW_THRESHOLD)/64); |
| 541 | lp->tx_throttle = 1; | 538 | lp->tx_throttle = 1; |
| 542 | netif_stop_queue(dev); | 539 | netif_stop_queue(dev); |
| 543 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 544 | } | 540 | } |
| 545 | 541 | ||
| 546 | /* Drop packets when we run out of space in TX FIFO | 542 | /* Drop packets when we run out of space in TX FIFO |
| @@ -556,6 +552,7 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
| 556 | lp->pending_tx_skb = NULL; | 552 | lp->pending_tx_skb = NULL; |
| 557 | dev->stats.tx_errors++; | 553 | dev->stats.tx_errors++; |
| 558 | dev->stats.tx_dropped++; | 554 | dev->stats.tx_dropped++; |
| 555 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 559 | dev_kfree_skb(skb); | 556 | dev_kfree_skb(skb); |
| 560 | return 0; | 557 | return 0; |
| 561 | } | 558 | } |
| @@ -565,7 +562,6 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
| 565 | /* If the DMA is already running then defer this packet Tx until | 562 | /* If the DMA is already running then defer this packet Tx until |
| 566 | * the DMA IRQ starts it | 563 | * the DMA IRQ starts it |
| 567 | */ | 564 | */ |
| 568 | spin_lock_irqsave(&lp->lock, flags); | ||
| 569 | if (lp->txdma_active) { | 565 | if (lp->txdma_active) { |
| 570 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Tx DMA running, deferring packet\n", dev->name); | 566 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Tx DMA running, deferring packet\n", dev->name); |
| 571 | lp->pending_tx_skb = skb; | 567 | lp->pending_tx_skb = skb; |
| @@ -576,11 +572,11 @@ static int smc911x_hard_start_xmit(struct sk_buff *skb, struct net_device *dev) | |||
| 576 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Activating Tx DMA\n", dev->name); | 572 | DBG(SMC_DEBUG_TX | SMC_DEBUG_DMA, "%s: Activating Tx DMA\n", dev->name); |
| 577 | lp->txdma_active = 1; | 573 | lp->txdma_active = 1; |
| 578 | } | 574 | } |
| 579 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 580 | } | 575 | } |
| 581 | #endif | 576 | #endif |
| 582 | lp->pending_tx_skb = skb; | 577 | lp->pending_tx_skb = skb; |
| 583 | smc911x_hardware_send_pkt(dev); | 578 | smc911x_hardware_send_pkt(dev); |
| 579 | spin_unlock_irqrestore(&lp->lock, flags); | ||
| 584 | 580 | ||
| 585 | return 0; | 581 | return 0; |
| 586 | } | 582 | } |
| @@ -1242,7 +1238,7 @@ smc911x_rx_dma_irq(int dma, void *data) | |||
| 1242 | netif_rx(skb); | 1238 | netif_rx(skb); |
| 1243 | 1239 | ||
| 1244 | spin_lock_irqsave(&lp->lock, flags); | 1240 | spin_lock_irqsave(&lp->lock, flags); |
| 1245 | pkts = (SMC_GET_RX_FIFO_INF() & RX_FIFO_INF_RXSUSED_) >> 16; | 1241 | pkts = (SMC_GET_RX_FIFO_INF(lp) & RX_FIFO_INF_RXSUSED_) >> 16; |
| 1246 | if (pkts != 0) { | 1242 | if (pkts != 0) { |
| 1247 | smc911x_rcv(dev); | 1243 | smc911x_rcv(dev); |
| 1248 | }else { | 1244 | }else { |
| @@ -2054,7 +2050,7 @@ err_out: | |||
| 2054 | */ | 2050 | */ |
| 2055 | static int smc911x_drv_probe(struct platform_device *pdev) | 2051 | static int smc911x_drv_probe(struct platform_device *pdev) |
| 2056 | { | 2052 | { |
| 2057 | struct smc91x_platdata *pd = pdev->dev.platform_data; | 2053 | struct smc911x_platdata *pd = pdev->dev.platform_data; |
| 2058 | struct net_device *ndev; | 2054 | struct net_device *ndev; |
| 2059 | struct resource *res; | 2055 | struct resource *res; |
| 2060 | struct smc911x_local *lp; | 2056 | struct smc911x_local *lp; |
diff --git a/drivers/net/smc911x.h b/drivers/net/smc911x.h index bf6240f23f5d..cc7d85bdfb3e 100644 --- a/drivers/net/smc911x.h +++ b/drivers/net/smc911x.h | |||
| @@ -50,6 +50,10 @@ | |||
| 50 | #define SMC_DYNAMIC_BUS_CONFIG | 50 | #define SMC_DYNAMIC_BUS_CONFIG |
| 51 | #endif | 51 | #endif |
| 52 | 52 | ||
| 53 | #ifdef SMC_USE_PXA_DMA | ||
| 54 | #define SMC_USE_DMA | ||
| 55 | #endif | ||
| 56 | |||
| 53 | /* store this information for the driver.. */ | 57 | /* store this information for the driver.. */ |
| 54 | struct smc911x_local { | 58 | struct smc911x_local { |
| 55 | /* | 59 | /* |
| @@ -196,8 +200,6 @@ static inline void SMC_outsl(struct smc911x_local *lp, int reg, | |||
| 196 | 200 | ||
| 197 | 201 | ||
| 198 | #ifdef SMC_USE_PXA_DMA | 202 | #ifdef SMC_USE_PXA_DMA |
| 199 | #define SMC_USE_DMA | ||
| 200 | |||
| 201 | /* | 203 | /* |
| 202 | * Define the request and free functions | 204 | * Define the request and free functions |
| 203 | * These are unfortunately architecture specific as no generic allocation | 205 | * These are unfortunately architecture specific as no generic allocation |
diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c index 9b95c4049b31..0f1d6bdd51a2 100644 --- a/drivers/net/wireless/ath5k/base.c +++ b/drivers/net/wireless/ath5k/base.c | |||
| @@ -340,9 +340,9 @@ static inline u64 ath5k_extend_tsf(struct ath5k_hw *ah, u32 rstamp) | |||
| 340 | } | 340 | } |
| 341 | 341 | ||
| 342 | /* Interrupt handling */ | 342 | /* Interrupt handling */ |
| 343 | static int ath5k_init(struct ath5k_softc *sc); | 343 | static int ath5k_init(struct ath5k_softc *sc, bool is_resume); |
| 344 | static int ath5k_stop_locked(struct ath5k_softc *sc); | 344 | static int ath5k_stop_locked(struct ath5k_softc *sc); |
| 345 | static int ath5k_stop_hw(struct ath5k_softc *sc); | 345 | static int ath5k_stop_hw(struct ath5k_softc *sc, bool is_suspend); |
| 346 | static irqreturn_t ath5k_intr(int irq, void *dev_id); | 346 | static irqreturn_t ath5k_intr(int irq, void *dev_id); |
| 347 | static void ath5k_tasklet_reset(unsigned long data); | 347 | static void ath5k_tasklet_reset(unsigned long data); |
| 348 | 348 | ||
| @@ -646,7 +646,7 @@ ath5k_pci_suspend(struct pci_dev *pdev, pm_message_t state) | |||
| 646 | 646 | ||
| 647 | ath5k_led_off(sc); | 647 | ath5k_led_off(sc); |
| 648 | 648 | ||
| 649 | ath5k_stop_hw(sc); | 649 | ath5k_stop_hw(sc, true); |
| 650 | 650 | ||
| 651 | free_irq(pdev->irq, sc); | 651 | free_irq(pdev->irq, sc); |
| 652 | pci_save_state(pdev); | 652 | pci_save_state(pdev); |
| @@ -683,7 +683,7 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
| 683 | goto err_no_irq; | 683 | goto err_no_irq; |
| 684 | } | 684 | } |
| 685 | 685 | ||
| 686 | err = ath5k_init(sc); | 686 | err = ath5k_init(sc, true); |
| 687 | if (err) | 687 | if (err) |
| 688 | goto err_irq; | 688 | goto err_irq; |
| 689 | ath5k_led_enable(sc); | 689 | ath5k_led_enable(sc); |
| @@ -2200,12 +2200,17 @@ ath5k_beacon_config(struct ath5k_softc *sc) | |||
| 2200 | \********************/ | 2200 | \********************/ |
| 2201 | 2201 | ||
| 2202 | static int | 2202 | static int |
| 2203 | ath5k_init(struct ath5k_softc *sc) | 2203 | ath5k_init(struct ath5k_softc *sc, bool is_resume) |
| 2204 | { | 2204 | { |
| 2205 | int ret; | 2205 | int ret; |
| 2206 | 2206 | ||
| 2207 | mutex_lock(&sc->lock); | 2207 | mutex_lock(&sc->lock); |
| 2208 | 2208 | ||
| 2209 | if (is_resume && !test_bit(ATH_STAT_STARTED, sc->status)) | ||
| 2210 | goto out_ok; | ||
| 2211 | |||
| 2212 | __clear_bit(ATH_STAT_STARTED, sc->status); | ||
| 2213 | |||
| 2209 | ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "mode %d\n", sc->opmode); | 2214 | ATH5K_DBG(sc, ATH5K_DEBUG_RESET, "mode %d\n", sc->opmode); |
| 2210 | 2215 | ||
| 2211 | /* | 2216 | /* |
| @@ -2230,12 +2235,15 @@ ath5k_init(struct ath5k_softc *sc) | |||
| 2230 | if (ret) | 2235 | if (ret) |
| 2231 | goto done; | 2236 | goto done; |
| 2232 | 2237 | ||
| 2238 | __set_bit(ATH_STAT_STARTED, sc->status); | ||
| 2239 | |||
| 2233 | /* Set ack to be sent at low bit-rates */ | 2240 | /* Set ack to be sent at low bit-rates */ |
| 2234 | ath5k_hw_set_ack_bitrate_high(sc->ah, false); | 2241 | ath5k_hw_set_ack_bitrate_high(sc->ah, false); |
| 2235 | 2242 | ||
| 2236 | mod_timer(&sc->calib_tim, round_jiffies(jiffies + | 2243 | mod_timer(&sc->calib_tim, round_jiffies(jiffies + |
| 2237 | msecs_to_jiffies(ath5k_calinterval * 1000))); | 2244 | msecs_to_jiffies(ath5k_calinterval * 1000))); |
| 2238 | 2245 | ||
| 2246 | out_ok: | ||
| 2239 | ret = 0; | 2247 | ret = 0; |
| 2240 | done: | 2248 | done: |
| 2241 | mmiowb(); | 2249 | mmiowb(); |
| @@ -2290,7 +2298,7 @@ ath5k_stop_locked(struct ath5k_softc *sc) | |||
| 2290 | * stop is preempted). | 2298 | * stop is preempted). |
| 2291 | */ | 2299 | */ |
| 2292 | static int | 2300 | static int |
| 2293 | ath5k_stop_hw(struct ath5k_softc *sc) | 2301 | ath5k_stop_hw(struct ath5k_softc *sc, bool is_suspend) |
| 2294 | { | 2302 | { |
| 2295 | int ret; | 2303 | int ret; |
| 2296 | 2304 | ||
| @@ -2321,6 +2329,9 @@ ath5k_stop_hw(struct ath5k_softc *sc) | |||
| 2321 | } | 2329 | } |
| 2322 | } | 2330 | } |
| 2323 | ath5k_txbuf_free(sc, sc->bbuf); | 2331 | ath5k_txbuf_free(sc, sc->bbuf); |
| 2332 | if (!is_suspend) | ||
| 2333 | __clear_bit(ATH_STAT_STARTED, sc->status); | ||
| 2334 | |||
| 2324 | mmiowb(); | 2335 | mmiowb(); |
| 2325 | mutex_unlock(&sc->lock); | 2336 | mutex_unlock(&sc->lock); |
| 2326 | 2337 | ||
| @@ -2718,12 +2729,12 @@ ath5k_reset_wake(struct ath5k_softc *sc) | |||
| 2718 | 2729 | ||
| 2719 | static int ath5k_start(struct ieee80211_hw *hw) | 2730 | static int ath5k_start(struct ieee80211_hw *hw) |
| 2720 | { | 2731 | { |
| 2721 | return ath5k_init(hw->priv); | 2732 | return ath5k_init(hw->priv, false); |
| 2722 | } | 2733 | } |
| 2723 | 2734 | ||
| 2724 | static void ath5k_stop(struct ieee80211_hw *hw) | 2735 | static void ath5k_stop(struct ieee80211_hw *hw) |
| 2725 | { | 2736 | { |
| 2726 | ath5k_stop_hw(hw->priv); | 2737 | ath5k_stop_hw(hw->priv, false); |
| 2727 | } | 2738 | } |
| 2728 | 2739 | ||
| 2729 | static int ath5k_add_interface(struct ieee80211_hw *hw, | 2740 | static int ath5k_add_interface(struct ieee80211_hw *hw, |
diff --git a/drivers/net/wireless/ath5k/base.h b/drivers/net/wireless/ath5k/base.h index 9d0b728928e3..06d1054ca94b 100644 --- a/drivers/net/wireless/ath5k/base.h +++ b/drivers/net/wireless/ath5k/base.h | |||
| @@ -128,11 +128,12 @@ struct ath5k_softc { | |||
| 128 | size_t desc_len; /* size of TX/RX descriptors */ | 128 | size_t desc_len; /* size of TX/RX descriptors */ |
| 129 | u16 cachelsz; /* cache line size */ | 129 | u16 cachelsz; /* cache line size */ |
| 130 | 130 | ||
| 131 | DECLARE_BITMAP(status, 4); | 131 | DECLARE_BITMAP(status, 5); |
| 132 | #define ATH_STAT_INVALID 0 /* disable hardware accesses */ | 132 | #define ATH_STAT_INVALID 0 /* disable hardware accesses */ |
| 133 | #define ATH_STAT_MRRETRY 1 /* multi-rate retry support */ | 133 | #define ATH_STAT_MRRETRY 1 /* multi-rate retry support */ |
| 134 | #define ATH_STAT_PROMISC 2 | 134 | #define ATH_STAT_PROMISC 2 |
| 135 | #define ATH_STAT_LEDSOFT 3 /* enable LED gpio status */ | 135 | #define ATH_STAT_LEDSOFT 3 /* enable LED gpio status */ |
| 136 | #define ATH_STAT_STARTED 4 /* opened & irqs enabled */ | ||
| 136 | 137 | ||
| 137 | unsigned int filter_flags; /* HW flags, AR5K_RX_FILTER_* */ | 138 | unsigned int filter_flags; /* HW flags, AR5K_RX_FILTER_* */ |
| 138 | unsigned int curmode; /* current phy mode */ | 139 | unsigned int curmode; /* current phy mode */ |
diff --git a/drivers/net/wireless/orinoco.c b/drivers/net/wireless/orinoco.c index 50904771f291..e0512e49d6d3 100644 --- a/drivers/net/wireless/orinoco.c +++ b/drivers/net/wireless/orinoco.c | |||
| @@ -433,7 +433,7 @@ struct fw_info { | |||
| 433 | const static struct fw_info orinoco_fw[] = { | 433 | const static struct fw_info orinoco_fw[] = { |
| 434 | { "", "agere_sta_fw.bin", "agere_ap_fw.bin", 0x00390000, 1000 }, | 434 | { "", "agere_sta_fw.bin", "agere_ap_fw.bin", 0x00390000, 1000 }, |
| 435 | { "", "prism_sta_fw.bin", "prism_ap_fw.bin", 0, 1024 }, | 435 | { "", "prism_sta_fw.bin", "prism_ap_fw.bin", 0, 1024 }, |
| 436 | { "symbol_sp24t_prim_fw", "symbol_sp24t_sec_fw", "", 0x00003100, 0x100 } | 436 | { "symbol_sp24t_prim_fw", "symbol_sp24t_sec_fw", "", 0x00003100, 512 } |
| 437 | }; | 437 | }; |
| 438 | 438 | ||
| 439 | /* Structure used to access fields in FW | 439 | /* Structure used to access fields in FW |
| @@ -458,7 +458,7 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
| 458 | int ap) | 458 | int ap) |
| 459 | { | 459 | { |
| 460 | /* Plug Data Area (PDA) */ | 460 | /* Plug Data Area (PDA) */ |
| 461 | __le16 pda[512] = { 0 }; | 461 | __le16 *pda; |
| 462 | 462 | ||
| 463 | hermes_t *hw = &priv->hw; | 463 | hermes_t *hw = &priv->hw; |
| 464 | const struct firmware *fw_entry; | 464 | const struct firmware *fw_entry; |
| @@ -467,7 +467,11 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
| 467 | const unsigned char *end; | 467 | const unsigned char *end; |
| 468 | const char *firmware; | 468 | const char *firmware; |
| 469 | struct net_device *dev = priv->ndev; | 469 | struct net_device *dev = priv->ndev; |
| 470 | int err; | 470 | int err = 0; |
| 471 | |||
| 472 | pda = kzalloc(fw->pda_size, GFP_KERNEL); | ||
| 473 | if (!pda) | ||
| 474 | return -ENOMEM; | ||
| 471 | 475 | ||
| 472 | if (ap) | 476 | if (ap) |
| 473 | firmware = fw->ap_fw; | 477 | firmware = fw->ap_fw; |
| @@ -478,17 +482,17 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
| 478 | dev->name, firmware); | 482 | dev->name, firmware); |
| 479 | 483 | ||
| 480 | /* Read current plug data */ | 484 | /* Read current plug data */ |
| 481 | err = hermes_read_pda(hw, pda, fw->pda_addr, | 485 | err = hermes_read_pda(hw, pda, fw->pda_addr, fw->pda_size, 0); |
| 482 | min_t(u16, fw->pda_size, sizeof(pda)), 0); | ||
| 483 | printk(KERN_DEBUG "%s: Read PDA returned %d\n", dev->name, err); | 486 | printk(KERN_DEBUG "%s: Read PDA returned %d\n", dev->name, err); |
| 484 | if (err) | 487 | if (err) |
| 485 | return err; | 488 | goto free; |
| 486 | 489 | ||
| 487 | err = request_firmware(&fw_entry, firmware, priv->dev); | 490 | err = request_firmware(&fw_entry, firmware, priv->dev); |
| 488 | if (err) { | 491 | if (err) { |
| 489 | printk(KERN_ERR "%s: Cannot find firmware %s\n", | 492 | printk(KERN_ERR "%s: Cannot find firmware %s\n", |
| 490 | dev->name, firmware); | 493 | dev->name, firmware); |
| 491 | return -ENOENT; | 494 | err = -ENOENT; |
| 495 | goto free; | ||
| 492 | } | 496 | } |
| 493 | 497 | ||
| 494 | hdr = (const struct orinoco_fw_header *) fw_entry->data; | 498 | hdr = (const struct orinoco_fw_header *) fw_entry->data; |
| @@ -532,6 +536,9 @@ orinoco_dl_firmware(struct orinoco_private *priv, | |||
| 532 | 536 | ||
| 533 | abort: | 537 | abort: |
| 534 | release_firmware(fw_entry); | 538 | release_firmware(fw_entry); |
| 539 | |||
| 540 | free: | ||
| 541 | kfree(pda); | ||
| 535 | return err; | 542 | return err; |
| 536 | } | 543 | } |
| 537 | 544 | ||
| @@ -549,12 +556,12 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
| 549 | int secondary) | 556 | int secondary) |
| 550 | { | 557 | { |
| 551 | hermes_t *hw = &priv->hw; | 558 | hermes_t *hw = &priv->hw; |
| 552 | int ret; | 559 | int ret = 0; |
| 553 | const unsigned char *ptr; | 560 | const unsigned char *ptr; |
| 554 | const unsigned char *first_block; | 561 | const unsigned char *first_block; |
| 555 | 562 | ||
| 556 | /* Plug Data Area (PDA) */ | 563 | /* Plug Data Area (PDA) */ |
| 557 | __le16 pda[256]; | 564 | __le16 *pda = NULL; |
| 558 | 565 | ||
| 559 | /* Binary block begins after the 0x1A marker */ | 566 | /* Binary block begins after the 0x1A marker */ |
| 560 | ptr = image; | 567 | ptr = image; |
| @@ -563,28 +570,33 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
| 563 | 570 | ||
| 564 | /* Read the PDA from EEPROM */ | 571 | /* Read the PDA from EEPROM */ |
| 565 | if (secondary) { | 572 | if (secondary) { |
| 566 | ret = hermes_read_pda(hw, pda, fw->pda_addr, sizeof(pda), 1); | 573 | pda = kzalloc(fw->pda_size, GFP_KERNEL); |
| 574 | if (!pda) | ||
| 575 | return -ENOMEM; | ||
| 576 | |||
| 577 | ret = hermes_read_pda(hw, pda, fw->pda_addr, fw->pda_size, 1); | ||
| 567 | if (ret) | 578 | if (ret) |
| 568 | return ret; | 579 | goto free; |
| 569 | } | 580 | } |
| 570 | 581 | ||
| 571 | /* Stop the firmware, so that it can be safely rewritten */ | 582 | /* Stop the firmware, so that it can be safely rewritten */ |
| 572 | if (priv->stop_fw) { | 583 | if (priv->stop_fw) { |
| 573 | ret = priv->stop_fw(priv, 1); | 584 | ret = priv->stop_fw(priv, 1); |
| 574 | if (ret) | 585 | if (ret) |
| 575 | return ret; | 586 | goto free; |
| 576 | } | 587 | } |
| 577 | 588 | ||
| 578 | /* Program the adapter with new firmware */ | 589 | /* Program the adapter with new firmware */ |
| 579 | ret = hermes_program(hw, first_block, end); | 590 | ret = hermes_program(hw, first_block, end); |
| 580 | if (ret) | 591 | if (ret) |
| 581 | return ret; | 592 | goto free; |
| 582 | 593 | ||
| 583 | /* Write the PDA to the adapter */ | 594 | /* Write the PDA to the adapter */ |
| 584 | if (secondary) { | 595 | if (secondary) { |
| 585 | size_t len = hermes_blocks_length(first_block); | 596 | size_t len = hermes_blocks_length(first_block); |
| 586 | ptr = first_block + len; | 597 | ptr = first_block + len; |
| 587 | ret = hermes_apply_pda(hw, ptr, pda); | 598 | ret = hermes_apply_pda(hw, ptr, pda); |
| 599 | kfree(pda); | ||
| 588 | if (ret) | 600 | if (ret) |
| 589 | return ret; | 601 | return ret; |
| 590 | } | 602 | } |
| @@ -608,6 +620,10 @@ symbol_dl_image(struct orinoco_private *priv, const struct fw_info *fw, | |||
| 608 | return -ENODEV; | 620 | return -ENODEV; |
| 609 | 621 | ||
| 610 | return 0; | 622 | return 0; |
| 623 | |||
| 624 | free: | ||
| 625 | kfree(pda); | ||
| 626 | return ret; | ||
| 611 | } | 627 | } |
| 612 | 628 | ||
| 613 | 629 | ||
diff --git a/drivers/net/wireless/p54/p54common.c b/drivers/net/wireless/p54/p54common.c index 117c7d3a52b0..2d022f83774c 100644 --- a/drivers/net/wireless/p54/p54common.c +++ b/drivers/net/wireless/p54/p54common.c | |||
| @@ -306,8 +306,8 @@ static int p54_convert_rev1(struct ieee80211_hw *dev, | |||
| 306 | return 0; | 306 | return 0; |
| 307 | } | 307 | } |
| 308 | 308 | ||
| 309 | static const char *p54_rf_chips[] = { "NULL", "Indigo?", "Duette", | 309 | static const char *p54_rf_chips[] = { "NULL", "Duette3", "Duette2", |
| 310 | "Frisbee", "Xbow", "Longbow" }; | 310 | "Frisbee", "Xbow", "Longbow", "NULL", "NULL" }; |
| 311 | static int p54_init_xbow_synth(struct ieee80211_hw *dev); | 311 | static int p54_init_xbow_synth(struct ieee80211_hw *dev); |
| 312 | 312 | ||
| 313 | static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | 313 | static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) |
| @@ -319,6 +319,7 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
| 319 | void *tmp; | 319 | void *tmp; |
| 320 | int err; | 320 | int err; |
| 321 | u8 *end = (u8 *)eeprom + len; | 321 | u8 *end = (u8 *)eeprom + len; |
| 322 | u16 synth; | ||
| 322 | DECLARE_MAC_BUF(mac); | 323 | DECLARE_MAC_BUF(mac); |
| 323 | 324 | ||
| 324 | wrap = (struct eeprom_pda_wrap *) eeprom; | 325 | wrap = (struct eeprom_pda_wrap *) eeprom; |
| @@ -400,8 +401,8 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
| 400 | tmp = entry->data; | 401 | tmp = entry->data; |
| 401 | while ((u8 *)tmp < entry->data + data_len) { | 402 | while ((u8 *)tmp < entry->data + data_len) { |
| 402 | struct bootrec_exp_if *exp_if = tmp; | 403 | struct bootrec_exp_if *exp_if = tmp; |
| 403 | if (le16_to_cpu(exp_if->if_id) == 0xF) | 404 | if (le16_to_cpu(exp_if->if_id) == 0xf) |
| 404 | priv->rxhw = le16_to_cpu(exp_if->variant) & 0x07; | 405 | synth = le16_to_cpu(exp_if->variant); |
| 405 | tmp += sizeof(struct bootrec_exp_if); | 406 | tmp += sizeof(struct bootrec_exp_if); |
| 406 | } | 407 | } |
| 407 | break; | 408 | break; |
| @@ -427,22 +428,13 @@ static int p54_parse_eeprom(struct ieee80211_hw *dev, void *eeprom, int len) | |||
| 427 | goto err; | 428 | goto err; |
| 428 | } | 429 | } |
| 429 | 430 | ||
| 430 | switch (priv->rxhw) { | 431 | priv->rxhw = synth & 0x07; |
| 431 | case 4: /* XBow */ | 432 | if (priv->rxhw == 4) |
| 432 | p54_init_xbow_synth(dev); | 433 | p54_init_xbow_synth(dev); |
| 433 | case 1: /* Indigo? */ | 434 | if (!(synth & 0x40)) |
| 434 | case 2: /* Duette */ | ||
| 435 | dev->wiphy->bands[IEEE80211_BAND_5GHZ] = &band_5GHz; | ||
| 436 | case 3: /* Frisbee */ | ||
| 437 | case 5: /* Longbow */ | ||
| 438 | dev->wiphy->bands[IEEE80211_BAND_2GHZ] = &band_2GHz; | 435 | dev->wiphy->bands[IEEE80211_BAND_2GHZ] = &band_2GHz; |
| 439 | break; | 436 | if (!(synth & 0x80)) |
| 440 | default: | 437 | dev->wiphy->bands[IEEE80211_BAND_5GHZ] = &band_5GHz; |
| 441 | printk(KERN_ERR "%s: unsupported RF-Chip\n", | ||
| 442 | wiphy_name(dev->wiphy)); | ||
| 443 | err = -EINVAL; | ||
| 444 | goto err; | ||
| 445 | } | ||
| 446 | 438 | ||
| 447 | if (!is_valid_ether_addr(dev->wiphy->perm_addr)) { | 439 | if (!is_valid_ether_addr(dev->wiphy->perm_addr)) { |
| 448 | u8 perm_addr[ETH_ALEN]; | 440 | u8 perm_addr[ETH_ALEN]; |
diff --git a/drivers/s390/crypto/ap_bus.c b/drivers/s390/crypto/ap_bus.c index 326db1e827c4..e3fe6838293a 100644 --- a/drivers/s390/crypto/ap_bus.c +++ b/drivers/s390/crypto/ap_bus.c | |||
| @@ -659,9 +659,9 @@ static ssize_t poll_timeout_store(struct bus_type *bus, const char *buf, | |||
| 659 | hr_time = ktime_set(0, poll_timeout); | 659 | hr_time = ktime_set(0, poll_timeout); |
| 660 | 660 | ||
| 661 | if (!hrtimer_is_queued(&ap_poll_timer) || | 661 | if (!hrtimer_is_queued(&ap_poll_timer) || |
| 662 | !hrtimer_forward(&ap_poll_timer, ap_poll_timer.expires, hr_time)) { | 662 | !hrtimer_forward(&ap_poll_timer, hrtimer_get_expires(&ap_poll_timer), hr_time)) { |
| 663 | ap_poll_timer.expires = hr_time; | 663 | hrtimer_set_expires(&ap_poll_timer, hr_time); |
| 664 | hrtimer_start(&ap_poll_timer, hr_time, HRTIMER_MODE_ABS); | 664 | hrtimer_start_expires(&ap_poll_timer, HRTIMER_MODE_ABS); |
| 665 | } | 665 | } |
| 666 | return count; | 666 | return count; |
| 667 | } | 667 | } |
diff --git a/drivers/scsi/3w-9xxx.c b/drivers/scsi/3w-9xxx.c index b92c19bb6876..5311317c2e4c 100644 --- a/drivers/scsi/3w-9xxx.c +++ b/drivers/scsi/3w-9xxx.c | |||
| @@ -1924,12 +1924,9 @@ static void twa_scsiop_execute_scsi_complete(TW_Device_Extension *tw_dev, int re | |||
| 1924 | (cmd->sc_data_direction == DMA_FROM_DEVICE || | 1924 | (cmd->sc_data_direction == DMA_FROM_DEVICE || |
| 1925 | cmd->sc_data_direction == DMA_BIDIRECTIONAL)) { | 1925 | cmd->sc_data_direction == DMA_BIDIRECTIONAL)) { |
| 1926 | if (scsi_sg_count(cmd) == 1) { | 1926 | if (scsi_sg_count(cmd) == 1) { |
| 1927 | unsigned long flags; | ||
| 1928 | void *buf = tw_dev->generic_buffer_virt[request_id]; | 1927 | void *buf = tw_dev->generic_buffer_virt[request_id]; |
| 1929 | 1928 | ||
| 1930 | local_irq_save(flags); | ||
| 1931 | scsi_sg_copy_from_buffer(cmd, buf, TW_SECTOR_SIZE); | 1929 | scsi_sg_copy_from_buffer(cmd, buf, TW_SECTOR_SIZE); |
| 1932 | local_irq_restore(flags); | ||
| 1933 | } | 1930 | } |
| 1934 | } | 1931 | } |
| 1935 | } /* End twa_scsiop_execute_scsi_complete() */ | 1932 | } /* End twa_scsiop_execute_scsi_complete() */ |
diff --git a/drivers/scsi/3w-xxxx.c b/drivers/scsi/3w-xxxx.c index a0537f09aa21..c03f1d2c9e2e 100644 --- a/drivers/scsi/3w-xxxx.c +++ b/drivers/scsi/3w-xxxx.c | |||
| @@ -1466,12 +1466,7 @@ static int tw_scsiop_inquiry(TW_Device_Extension *tw_dev, int request_id) | |||
| 1466 | static void tw_transfer_internal(TW_Device_Extension *tw_dev, int request_id, | 1466 | static void tw_transfer_internal(TW_Device_Extension *tw_dev, int request_id, |
| 1467 | void *data, unsigned int len) | 1467 | void *data, unsigned int len) |
| 1468 | { | 1468 | { |
| 1469 | struct scsi_cmnd *cmd = tw_dev->srb[request_id]; | 1469 | scsi_sg_copy_from_buffer(tw_dev->srb[request_id], data, len); |
| 1470 | unsigned long flags; | ||
| 1471 | |||
| 1472 | local_irq_save(flags); | ||
| 1473 | scsi_sg_copy_from_buffer(cmd, data, len); | ||
| 1474 | local_irq_restore(flags); | ||
| 1475 | } | 1470 | } |
| 1476 | 1471 | ||
| 1477 | /* This function is called by the isr to complete an inquiry command */ | 1472 | /* This function is called by the isr to complete an inquiry command */ |
diff --git a/drivers/scsi/aic7xxx/aic79xx.reg b/drivers/scsi/aic7xxx/aic79xx.reg index cca16fc5b4ad..0666c22ab55b 100644 --- a/drivers/scsi/aic7xxx/aic79xx.reg +++ b/drivers/scsi/aic7xxx/aic79xx.reg | |||
| @@ -80,6 +80,17 @@ VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic79xx.reg#77 $" | |||
| 80 | } | 80 | } |
| 81 | 81 | ||
| 82 | /* | 82 | /* |
| 83 | * Registers marked "dont_generate_debug_code" are not (yet) referenced | ||
| 84 | * from the driver code, and this keyword inhibit generation | ||
| 85 | * of debug code for them. | ||
| 86 | * | ||
| 87 | * REG_PRETTY_PRINT config will complain if dont_generate_debug_code | ||
| 88 | * is added to the register which is referenced in the driver. | ||
| 89 | * Unreferenced register with no dont_generate_debug_code will result | ||
| 90 | * in dead code. No warning is issued. | ||
| 91 | */ | ||
| 92 | |||
| 93 | /* | ||
| 83 | * Mode Pointer | 94 | * Mode Pointer |
| 84 | * Controls which of the 5, 512byte, address spaces should be used | 95 | * Controls which of the 5, 512byte, address spaces should be used |
| 85 | * as the source and destination of any register accesses in our | 96 | * as the source and destination of any register accesses in our |
| @@ -91,6 +102,7 @@ register MODE_PTR { | |||
| 91 | field DST_MODE 0x70 | 102 | field DST_MODE 0x70 |
| 92 | field SRC_MODE 0x07 | 103 | field SRC_MODE 0x07 |
| 93 | mode_pointer | 104 | mode_pointer |
| 105 | dont_generate_debug_code | ||
| 94 | } | 106 | } |
| 95 | 107 | ||
| 96 | const SRC_MODE_SHIFT 0 | 108 | const SRC_MODE_SHIFT 0 |
| @@ -190,6 +202,7 @@ register SEQINTCODE { | |||
| 190 | SAW_HWERR, | 202 | SAW_HWERR, |
| 191 | BAD_SCB_STATUS | 203 | BAD_SCB_STATUS |
| 192 | } | 204 | } |
| 205 | dont_generate_debug_code | ||
| 193 | } | 206 | } |
| 194 | 207 | ||
| 195 | /* | 208 | /* |
| @@ -207,6 +220,7 @@ register CLRINT { | |||
| 207 | field CLRSEQINT 0x04 | 220 | field CLRSEQINT 0x04 |
| 208 | field CLRCMDINT 0x02 | 221 | field CLRCMDINT 0x02 |
| 209 | field CLRSPLTINT 0x01 | 222 | field CLRSPLTINT 0x01 |
| 223 | dont_generate_debug_code | ||
| 210 | } | 224 | } |
| 211 | 225 | ||
| 212 | /* | 226 | /* |
| @@ -222,6 +236,7 @@ register ERROR { | |||
| 222 | field SQPARERR 0x08 | 236 | field SQPARERR 0x08 |
| 223 | field ILLOPCODE 0x04 | 237 | field ILLOPCODE 0x04 |
| 224 | field DSCTMOUT 0x02 | 238 | field DSCTMOUT 0x02 |
| 239 | dont_generate_debug_code | ||
| 225 | } | 240 | } |
| 226 | 241 | ||
| 227 | /* | 242 | /* |
| @@ -255,6 +270,7 @@ register HCNTRL { | |||
| 255 | field INTEN 0x02 | 270 | field INTEN 0x02 |
| 256 | field CHIPRST 0x01 | 271 | field CHIPRST 0x01 |
| 257 | field CHIPRSTACK 0x01 | 272 | field CHIPRSTACK 0x01 |
| 273 | dont_generate_debug_code | ||
| 258 | } | 274 | } |
| 259 | 275 | ||
| 260 | /* | 276 | /* |
| @@ -265,6 +281,7 @@ register HNSCB_QOFF { | |||
| 265 | access_mode RW | 281 | access_mode RW |
| 266 | size 2 | 282 | size 2 |
| 267 | count 2 | 283 | count 2 |
| 284 | dont_generate_debug_code | ||
| 268 | } | 285 | } |
| 269 | 286 | ||
| 270 | /* | 287 | /* |
| @@ -274,6 +291,7 @@ register HESCB_QOFF { | |||
| 274 | address 0x008 | 291 | address 0x008 |
| 275 | access_mode RW | 292 | access_mode RW |
| 276 | count 2 | 293 | count 2 |
| 294 | dont_generate_debug_code | ||
| 277 | } | 295 | } |
| 278 | 296 | ||
| 279 | /* | 297 | /* |
| @@ -311,6 +329,7 @@ register CLRSEQINTSTAT { | |||
| 311 | field CLRSEQ_SCSIINT 0x04 | 329 | field CLRSEQ_SCSIINT 0x04 |
| 312 | field CLRSEQ_PCIINT 0x02 | 330 | field CLRSEQ_PCIINT 0x02 |
| 313 | field CLRSEQ_SPLTINT 0x01 | 331 | field CLRSEQ_SPLTINT 0x01 |
| 332 | dont_generate_debug_code | ||
| 314 | } | 333 | } |
| 315 | 334 | ||
| 316 | /* | 335 | /* |
| @@ -320,6 +339,7 @@ register SWTIMER { | |||
| 320 | address 0x00E | 339 | address 0x00E |
| 321 | access_mode RW | 340 | access_mode RW |
| 322 | size 2 | 341 | size 2 |
| 342 | dont_generate_debug_code | ||
| 323 | } | 343 | } |
| 324 | 344 | ||
| 325 | /* | 345 | /* |
| @@ -330,6 +350,7 @@ register SNSCB_QOFF { | |||
| 330 | access_mode RW | 350 | access_mode RW |
| 331 | size 2 | 351 | size 2 |
| 332 | modes M_CCHAN | 352 | modes M_CCHAN |
| 353 | dont_generate_debug_code | ||
| 333 | } | 354 | } |
| 334 | 355 | ||
| 335 | /* | 356 | /* |
| @@ -340,6 +361,7 @@ register SESCB_QOFF { | |||
| 340 | count 2 | 361 | count 2 |
| 341 | access_mode RW | 362 | access_mode RW |
| 342 | modes M_CCHAN | 363 | modes M_CCHAN |
| 364 | dont_generate_debug_code | ||
| 343 | } | 365 | } |
| 344 | 366 | ||
| 345 | /* | 367 | /* |
| @@ -350,6 +372,7 @@ register SDSCB_QOFF { | |||
| 350 | access_mode RW | 372 | access_mode RW |
| 351 | modes M_CCHAN | 373 | modes M_CCHAN |
| 352 | size 2 | 374 | size 2 |
| 375 | dont_generate_debug_code | ||
| 353 | } | 376 | } |
| 354 | 377 | ||
| 355 | /* | 378 | /* |
| @@ -378,6 +401,7 @@ register QOFF_CTLSTA { | |||
| 378 | SCB_QSIZE_8192, | 401 | SCB_QSIZE_8192, |
| 379 | SCB_QSIZE_16384 | 402 | SCB_QSIZE_16384 |
| 380 | } | 403 | } |
| 404 | dont_generate_debug_code | ||
| 381 | } | 405 | } |
| 382 | 406 | ||
| 383 | /* | 407 | /* |
| @@ -431,6 +455,7 @@ register DSCOMMAND0 { | |||
| 431 | field EXTREQLCK 0x10 /* External Request Lock */ | 455 | field EXTREQLCK 0x10 /* External Request Lock */ |
| 432 | field DISABLE_TWATE 0x02 /* Rev B or greater */ | 456 | field DISABLE_TWATE 0x02 /* Rev B or greater */ |
| 433 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ | 457 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ |
| 458 | dont_generate_debug_code | ||
| 434 | } | 459 | } |
| 435 | 460 | ||
| 436 | /* | 461 | /* |
| @@ -459,6 +484,7 @@ register SG_CACHE_PRE { | |||
| 459 | field SG_ADDR_MASK 0xf8 | 484 | field SG_ADDR_MASK 0xf8 |
| 460 | field ODD_SEG 0x04 | 485 | field ODD_SEG 0x04 |
| 461 | field LAST_SEG 0x02 | 486 | field LAST_SEG 0x02 |
| 487 | dont_generate_debug_code | ||
| 462 | } | 488 | } |
| 463 | 489 | ||
| 464 | register SG_CACHE_SHADOW { | 490 | register SG_CACHE_SHADOW { |
| @@ -491,6 +517,7 @@ register HADDR { | |||
| 491 | access_mode RW | 517 | access_mode RW |
| 492 | size 8 | 518 | size 8 |
| 493 | modes M_DFF0, M_DFF1 | 519 | modes M_DFF0, M_DFF1 |
| 520 | dont_generate_debug_code | ||
| 494 | } | 521 | } |
| 495 | 522 | ||
| 496 | /* | 523 | /* |
| @@ -522,6 +549,7 @@ register HCNT { | |||
| 522 | access_mode RW | 549 | access_mode RW |
| 523 | size 3 | 550 | size 3 |
| 524 | modes M_DFF0, M_DFF1 | 551 | modes M_DFF0, M_DFF1 |
| 552 | dont_generate_debug_code | ||
| 525 | } | 553 | } |
| 526 | 554 | ||
| 527 | /* | 555 | /* |
| @@ -551,6 +579,7 @@ register SGHADDR { | |||
| 551 | access_mode RW | 579 | access_mode RW |
| 552 | size 8 | 580 | size 8 |
| 553 | modes M_DFF0, M_DFF1 | 581 | modes M_DFF0, M_DFF1 |
| 582 | dont_generate_debug_code | ||
| 554 | } | 583 | } |
| 555 | 584 | ||
| 556 | /* | 585 | /* |
| @@ -561,6 +590,7 @@ register SCBHADDR { | |||
| 561 | access_mode RW | 590 | access_mode RW |
| 562 | size 8 | 591 | size 8 |
| 563 | modes M_CCHAN | 592 | modes M_CCHAN |
| 593 | dont_generate_debug_code | ||
| 564 | } | 594 | } |
| 565 | 595 | ||
| 566 | /* | 596 | /* |
| @@ -570,6 +600,7 @@ register SGHCNT { | |||
| 570 | address 0x084 | 600 | address 0x084 |
| 571 | access_mode RW | 601 | access_mode RW |
| 572 | modes M_DFF0, M_DFF1 | 602 | modes M_DFF0, M_DFF1 |
| 603 | dont_generate_debug_code | ||
| 573 | } | 604 | } |
| 574 | 605 | ||
| 575 | /* | 606 | /* |
| @@ -579,6 +610,7 @@ register SCBHCNT { | |||
| 579 | address 0x084 | 610 | address 0x084 |
| 580 | access_mode RW | 611 | access_mode RW |
| 581 | modes M_CCHAN | 612 | modes M_CCHAN |
| 613 | dont_generate_debug_code | ||
| 582 | } | 614 | } |
| 583 | 615 | ||
| 584 | /* | 616 | /* |
| @@ -609,6 +641,7 @@ register DFF_THRSH { | |||
| 609 | RD_DFTHRSH_90, | 641 | RD_DFTHRSH_90, |
| 610 | RD_DFTHRSH_MAX | 642 | RD_DFTHRSH_MAX |
| 611 | } | 643 | } |
| 644 | dont_generate_debug_code | ||
| 612 | } | 645 | } |
| 613 | 646 | ||
| 614 | /* | 647 | /* |
| @@ -817,6 +850,7 @@ register PCIXCTL { | |||
| 817 | field SRSPDPEEN 0x04 | 850 | field SRSPDPEEN 0x04 |
| 818 | field TSCSERREN 0x02 | 851 | field TSCSERREN 0x02 |
| 819 | field CMPABCDIS 0x01 | 852 | field CMPABCDIS 0x01 |
| 853 | dont_generate_debug_code | ||
| 820 | } | 854 | } |
| 821 | 855 | ||
| 822 | /* | 856 | /* |
| @@ -863,6 +897,7 @@ register DCHSPLTSTAT0 { | |||
| 863 | field RXOVRUN 0x04 | 897 | field RXOVRUN 0x04 |
| 864 | field RXSCEMSG 0x02 | 898 | field RXSCEMSG 0x02 |
| 865 | field RXSPLTRSP 0x01 | 899 | field RXSPLTRSP 0x01 |
| 900 | dont_generate_debug_code | ||
| 866 | } | 901 | } |
| 867 | 902 | ||
| 868 | /* | 903 | /* |
| @@ -908,6 +943,7 @@ register DCHSPLTSTAT1 { | |||
| 908 | modes M_DFF0, M_DFF1 | 943 | modes M_DFF0, M_DFF1 |
| 909 | count 2 | 944 | count 2 |
| 910 | field RXDATABUCKET 0x01 | 945 | field RXDATABUCKET 0x01 |
| 946 | dont_generate_debug_code | ||
| 911 | } | 947 | } |
| 912 | 948 | ||
| 913 | /* | 949 | /* |
| @@ -1069,6 +1105,7 @@ register SGSPLTSTAT0 { | |||
| 1069 | field RXOVRUN 0x04 | 1105 | field RXOVRUN 0x04 |
| 1070 | field RXSCEMSG 0x02 | 1106 | field RXSCEMSG 0x02 |
| 1071 | field RXSPLTRSP 0x01 | 1107 | field RXSPLTRSP 0x01 |
| 1108 | dont_generate_debug_code | ||
| 1072 | } | 1109 | } |
| 1073 | 1110 | ||
| 1074 | /* | 1111 | /* |
| @@ -1080,6 +1117,7 @@ register SGSPLTSTAT1 { | |||
| 1080 | modes M_DFF0, M_DFF1 | 1117 | modes M_DFF0, M_DFF1 |
| 1081 | count 2 | 1118 | count 2 |
| 1082 | field RXDATABUCKET 0x01 | 1119 | field RXDATABUCKET 0x01 |
| 1120 | dont_generate_debug_code | ||
| 1083 | } | 1121 | } |
| 1084 | 1122 | ||
| 1085 | /* | 1123 | /* |
| @@ -1091,6 +1129,7 @@ register SFUNCT { | |||
| 1091 | modes M_CFG | 1129 | modes M_CFG |
| 1092 | field TEST_GROUP 0xF0 | 1130 | field TEST_GROUP 0xF0 |
| 1093 | field TEST_NUM 0x0F | 1131 | field TEST_NUM 0x0F |
| 1132 | dont_generate_debug_code | ||
| 1094 | } | 1133 | } |
| 1095 | 1134 | ||
| 1096 | /* | 1135 | /* |
| @@ -1109,6 +1148,7 @@ register DF0PCISTAT { | |||
| 1109 | field RDPERR 0x04 | 1148 | field RDPERR 0x04 |
| 1110 | field TWATERR 0x02 | 1149 | field TWATERR 0x02 |
| 1111 | field DPR 0x01 | 1150 | field DPR 0x01 |
| 1151 | dont_generate_debug_code | ||
| 1112 | } | 1152 | } |
| 1113 | 1153 | ||
| 1114 | /* | 1154 | /* |
| @@ -1204,6 +1244,7 @@ register TARGPCISTAT { | |||
| 1204 | field SSE 0x40 | 1244 | field SSE 0x40 |
| 1205 | field STA 0x08 | 1245 | field STA 0x08 |
| 1206 | field TWATERR 0x02 | 1246 | field TWATERR 0x02 |
| 1247 | dont_generate_debug_code | ||
| 1207 | } | 1248 | } |
| 1208 | 1249 | ||
| 1209 | /* | 1250 | /* |
| @@ -1216,6 +1257,7 @@ register LQIN { | |||
| 1216 | size 20 | 1257 | size 20 |
| 1217 | count 2 | 1258 | count 2 |
| 1218 | modes M_DFF0, M_DFF1, M_SCSI | 1259 | modes M_DFF0, M_DFF1, M_SCSI |
| 1260 | dont_generate_debug_code | ||
| 1219 | } | 1261 | } |
| 1220 | 1262 | ||
| 1221 | /* | 1263 | /* |
| @@ -1247,6 +1289,7 @@ register LUNPTR { | |||
| 1247 | access_mode RW | 1289 | access_mode RW |
| 1248 | modes M_CFG | 1290 | modes M_CFG |
| 1249 | count 2 | 1291 | count 2 |
| 1292 | dont_generate_debug_code | ||
| 1250 | } | 1293 | } |
| 1251 | 1294 | ||
| 1252 | /* | 1295 | /* |
| @@ -1278,6 +1321,7 @@ register CMDLENPTR { | |||
| 1278 | access_mode RW | 1321 | access_mode RW |
| 1279 | modes M_CFG | 1322 | modes M_CFG |
| 1280 | count 1 | 1323 | count 1 |
| 1324 | dont_generate_debug_code | ||
| 1281 | } | 1325 | } |
| 1282 | 1326 | ||
| 1283 | /* | 1327 | /* |
| @@ -1290,6 +1334,7 @@ register ATTRPTR { | |||
| 1290 | access_mode RW | 1334 | access_mode RW |
| 1291 | modes M_CFG | 1335 | modes M_CFG |
| 1292 | count 1 | 1336 | count 1 |
| 1337 | dont_generate_debug_code | ||
| 1293 | } | 1338 | } |
| 1294 | 1339 | ||
| 1295 | /* | 1340 | /* |
| @@ -1302,6 +1347,7 @@ register FLAGPTR { | |||
| 1302 | access_mode RW | 1347 | access_mode RW |
| 1303 | modes M_CFG | 1348 | modes M_CFG |
| 1304 | count 1 | 1349 | count 1 |
| 1350 | dont_generate_debug_code | ||
| 1305 | } | 1351 | } |
| 1306 | 1352 | ||
| 1307 | /* | 1353 | /* |
| @@ -1313,6 +1359,7 @@ register CMDPTR { | |||
| 1313 | access_mode RW | 1359 | access_mode RW |
| 1314 | modes M_CFG | 1360 | modes M_CFG |
| 1315 | count 1 | 1361 | count 1 |
| 1362 | dont_generate_debug_code | ||
| 1316 | } | 1363 | } |
| 1317 | 1364 | ||
| 1318 | /* | 1365 | /* |
| @@ -1324,6 +1371,7 @@ register QNEXTPTR { | |||
| 1324 | access_mode RW | 1371 | access_mode RW |
| 1325 | modes M_CFG | 1372 | modes M_CFG |
| 1326 | count 1 | 1373 | count 1 |
| 1374 | dont_generate_debug_code | ||
| 1327 | } | 1375 | } |
| 1328 | 1376 | ||
| 1329 | /* | 1377 | /* |
| @@ -1347,6 +1395,7 @@ register ABRTBYTEPTR { | |||
| 1347 | access_mode RW | 1395 | access_mode RW |
| 1348 | modes M_CFG | 1396 | modes M_CFG |
| 1349 | count 1 | 1397 | count 1 |
| 1398 | dont_generate_debug_code | ||
| 1350 | } | 1399 | } |
| 1351 | 1400 | ||
| 1352 | /* | 1401 | /* |
| @@ -1358,6 +1407,7 @@ register ABRTBITPTR { | |||
| 1358 | access_mode RW | 1407 | access_mode RW |
| 1359 | modes M_CFG | 1408 | modes M_CFG |
| 1360 | count 1 | 1409 | count 1 |
| 1410 | dont_generate_debug_code | ||
| 1361 | } | 1411 | } |
| 1362 | 1412 | ||
| 1363 | /* | 1413 | /* |
| @@ -1398,6 +1448,7 @@ register LUNLEN { | |||
| 1398 | count 2 | 1448 | count 2 |
| 1399 | mask ILUNLEN 0x0F | 1449 | mask ILUNLEN 0x0F |
| 1400 | mask TLUNLEN 0xF0 | 1450 | mask TLUNLEN 0xF0 |
| 1451 | dont_generate_debug_code | ||
| 1401 | } | 1452 | } |
| 1402 | const LUNLEN_SINGLE_LEVEL_LUN 0xF | 1453 | const LUNLEN_SINGLE_LEVEL_LUN 0xF |
| 1403 | 1454 | ||
| @@ -1410,6 +1461,7 @@ register CDBLIMIT { | |||
| 1410 | access_mode RW | 1461 | access_mode RW |
| 1411 | modes M_CFG | 1462 | modes M_CFG |
| 1412 | count 1 | 1463 | count 1 |
| 1464 | dont_generate_debug_code | ||
| 1413 | } | 1465 | } |
| 1414 | 1466 | ||
| 1415 | /* | 1467 | /* |
| @@ -1422,6 +1474,7 @@ register MAXCMD { | |||
| 1422 | access_mode RW | 1474 | access_mode RW |
| 1423 | modes M_CFG | 1475 | modes M_CFG |
| 1424 | count 9 | 1476 | count 9 |
| 1477 | dont_generate_debug_code | ||
| 1425 | } | 1478 | } |
| 1426 | 1479 | ||
| 1427 | /* | 1480 | /* |
| @@ -1432,6 +1485,7 @@ register MAXCMDCNT { | |||
| 1432 | address 0x033 | 1485 | address 0x033 |
| 1433 | access_mode RW | 1486 | access_mode RW |
| 1434 | modes M_CFG | 1487 | modes M_CFG |
| 1488 | dont_generate_debug_code | ||
| 1435 | } | 1489 | } |
| 1436 | 1490 | ||
| 1437 | /* | 1491 | /* |
| @@ -1490,6 +1544,7 @@ register LQCTL1 { | |||
| 1490 | field PCI2PCI 0x04 | 1544 | field PCI2PCI 0x04 |
| 1491 | field SINGLECMD 0x02 | 1545 | field SINGLECMD 0x02 |
| 1492 | field ABORTPENDING 0x01 | 1546 | field ABORTPENDING 0x01 |
| 1547 | dont_generate_debug_code | ||
| 1493 | } | 1548 | } |
| 1494 | 1549 | ||
| 1495 | /* | 1550 | /* |
| @@ -1508,6 +1563,7 @@ register LQCTL2 { | |||
| 1508 | field LQOCONTINUE 0x04 | 1563 | field LQOCONTINUE 0x04 |
| 1509 | field LQOTOIDLE 0x02 | 1564 | field LQOTOIDLE 0x02 |
| 1510 | field LQOPAUSE 0x01 | 1565 | field LQOPAUSE 0x01 |
| 1566 | dont_generate_debug_code | ||
| 1511 | } | 1567 | } |
| 1512 | 1568 | ||
| 1513 | /* | 1569 | /* |
| @@ -1578,6 +1634,7 @@ register SXFRCTL0 { | |||
| 1578 | field DFPEXP 0x40 | 1634 | field DFPEXP 0x40 |
| 1579 | field BIOSCANCELEN 0x10 | 1635 | field BIOSCANCELEN 0x10 |
| 1580 | field SPIOEN 0x08 | 1636 | field SPIOEN 0x08 |
| 1637 | dont_generate_debug_code | ||
| 1581 | } | 1638 | } |
| 1582 | 1639 | ||
| 1583 | /* | 1640 | /* |
| @@ -1594,6 +1651,7 @@ register SXFRCTL1 { | |||
| 1594 | field ENSTIMER 0x04 | 1651 | field ENSTIMER 0x04 |
| 1595 | field ACTNEGEN 0x02 | 1652 | field ACTNEGEN 0x02 |
| 1596 | field STPWEN 0x01 | 1653 | field STPWEN 0x01 |
| 1654 | dont_generate_debug_code | ||
| 1597 | } | 1655 | } |
| 1598 | 1656 | ||
| 1599 | /* | 1657 | /* |
| @@ -1696,6 +1754,7 @@ register SCSISIGO { | |||
| 1696 | P_STATUS CDO|IOO, | 1754 | P_STATUS CDO|IOO, |
| 1697 | P_MESGIN CDO|IOO|MSGO | 1755 | P_MESGIN CDO|IOO|MSGO |
| 1698 | } | 1756 | } |
| 1757 | dont_generate_debug_code | ||
| 1699 | } | 1758 | } |
| 1700 | 1759 | ||
| 1701 | /* | 1760 | /* |
| @@ -1738,6 +1797,7 @@ register MULTARGID { | |||
| 1738 | modes M_CFG | 1797 | modes M_CFG |
| 1739 | size 2 | 1798 | size 2 |
| 1740 | count 2 | 1799 | count 2 |
| 1800 | dont_generate_debug_code | ||
| 1741 | } | 1801 | } |
| 1742 | 1802 | ||
| 1743 | /* | 1803 | /* |
| @@ -1774,6 +1834,7 @@ register SCSIDAT { | |||
| 1774 | access_mode RW | 1834 | access_mode RW |
| 1775 | modes M_DFF0, M_DFF1, M_SCSI | 1835 | modes M_DFF0, M_DFF1, M_SCSI |
| 1776 | size 2 | 1836 | size 2 |
| 1837 | dont_generate_debug_code | ||
| 1777 | } | 1838 | } |
| 1778 | 1839 | ||
| 1779 | /* | 1840 | /* |
| @@ -1796,6 +1857,7 @@ register TARGIDIN { | |||
| 1796 | count 2 | 1857 | count 2 |
| 1797 | field CLKOUT 0x80 | 1858 | field CLKOUT 0x80 |
| 1798 | field TARGID 0x0F | 1859 | field TARGID 0x0F |
| 1860 | dont_generate_debug_code | ||
| 1799 | } | 1861 | } |
| 1800 | 1862 | ||
| 1801 | /* | 1863 | /* |
| @@ -1825,6 +1887,7 @@ register SBLKCTL { | |||
| 1825 | field ENAB40 0x08 /* LVD transceiver active */ | 1887 | field ENAB40 0x08 /* LVD transceiver active */ |
| 1826 | field ENAB20 0x04 /* SE/HVD transceiver active */ | 1888 | field ENAB20 0x04 /* SE/HVD transceiver active */ |
| 1827 | field SELWIDE 0x02 | 1889 | field SELWIDE 0x02 |
| 1890 | dont_generate_debug_code | ||
| 1828 | } | 1891 | } |
| 1829 | 1892 | ||
| 1830 | /* | 1893 | /* |
| @@ -1842,6 +1905,7 @@ register OPTIONMODE { | |||
| 1842 | field ENDGFORMCHK 0x04 | 1905 | field ENDGFORMCHK 0x04 |
| 1843 | field AUTO_MSGOUT_DE 0x02 | 1906 | field AUTO_MSGOUT_DE 0x02 |
| 1844 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE | 1907 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE |
| 1908 | dont_generate_debug_code | ||
| 1845 | } | 1909 | } |
| 1846 | 1910 | ||
| 1847 | /* | 1911 | /* |
| @@ -1876,6 +1940,7 @@ register CLRSINT0 { | |||
| 1876 | field CLROVERRUN 0x04 | 1940 | field CLROVERRUN 0x04 |
| 1877 | field CLRSPIORDY 0x02 | 1941 | field CLRSPIORDY 0x02 |
| 1878 | field CLRARBDO 0x01 | 1942 | field CLRARBDO 0x01 |
| 1943 | dont_generate_debug_code | ||
| 1879 | } | 1944 | } |
| 1880 | 1945 | ||
| 1881 | /* | 1946 | /* |
| @@ -1929,6 +1994,7 @@ register CLRSINT1 { | |||
| 1929 | field CLRSCSIPERR 0x04 | 1994 | field CLRSCSIPERR 0x04 |
| 1930 | field CLRSTRB2FAST 0x02 | 1995 | field CLRSTRB2FAST 0x02 |
| 1931 | field CLRREQINIT 0x01 | 1996 | field CLRREQINIT 0x01 |
| 1997 | dont_generate_debug_code | ||
| 1932 | } | 1998 | } |
| 1933 | 1999 | ||
| 1934 | /* | 2000 | /* |
| @@ -1962,6 +2028,7 @@ register CLRSINT2 { | |||
| 1962 | field CLRWIDE_RES 0x04 /* Modes 0 and 1 only */ | 2028 | field CLRWIDE_RES 0x04 /* Modes 0 and 1 only */ |
| 1963 | field CLRSDONE 0x02 /* Modes 0 and 1 only */ | 2029 | field CLRSDONE 0x02 /* Modes 0 and 1 only */ |
| 1964 | field CLRDMADONE 0x01 /* Modes 0 and 1 only */ | 2030 | field CLRDMADONE 0x01 /* Modes 0 and 1 only */ |
| 2031 | dont_generate_debug_code | ||
| 1965 | } | 2032 | } |
| 1966 | 2033 | ||
| 1967 | /* | 2034 | /* |
| @@ -2002,6 +2069,7 @@ register LQISTATE { | |||
| 2002 | access_mode RO | 2069 | access_mode RO |
| 2003 | modes M_CFG | 2070 | modes M_CFG |
| 2004 | count 6 | 2071 | count 6 |
| 2072 | dont_generate_debug_code | ||
| 2005 | } | 2073 | } |
| 2006 | 2074 | ||
| 2007 | /* | 2075 | /* |
| @@ -2022,6 +2090,7 @@ register LQOSTATE { | |||
| 2022 | access_mode RO | 2090 | access_mode RO |
| 2023 | modes M_CFG | 2091 | modes M_CFG |
| 2024 | count 2 | 2092 | count 2 |
| 2093 | dont_generate_debug_code | ||
| 2025 | } | 2094 | } |
| 2026 | 2095 | ||
| 2027 | /* | 2096 | /* |
| @@ -2054,6 +2123,7 @@ register CLRLQIINT0 { | |||
| 2054 | field CLRLQIBADLQT 0x04 | 2123 | field CLRLQIBADLQT 0x04 |
| 2055 | field CLRLQIATNLQ 0x02 | 2124 | field CLRLQIATNLQ 0x02 |
| 2056 | field CLRLQIATNCMD 0x01 | 2125 | field CLRLQIATNCMD 0x01 |
| 2126 | dont_generate_debug_code | ||
| 2057 | } | 2127 | } |
| 2058 | 2128 | ||
| 2059 | /* | 2129 | /* |
| @@ -2070,6 +2140,7 @@ register LQIMODE0 { | |||
| 2070 | field ENLQIBADLQT 0x04 | 2140 | field ENLQIBADLQT 0x04 |
| 2071 | field ENLQIATNLQ 0x02 | 2141 | field ENLQIATNLQ 0x02 |
| 2072 | field ENLQIATNCMD 0x01 | 2142 | field ENLQIATNCMD 0x01 |
| 2143 | dont_generate_debug_code | ||
| 2073 | } | 2144 | } |
| 2074 | 2145 | ||
| 2075 | /* | 2146 | /* |
| @@ -2106,6 +2177,7 @@ register CLRLQIINT1 { | |||
| 2106 | field CLRLQIBADLQI 0x04 | 2177 | field CLRLQIBADLQI 0x04 |
| 2107 | field CLRLQIOVERI_LQ 0x02 | 2178 | field CLRLQIOVERI_LQ 0x02 |
| 2108 | field CLRLQIOVERI_NLQ 0x01 | 2179 | field CLRLQIOVERI_NLQ 0x01 |
| 2180 | dont_generate_debug_code | ||
| 2109 | } | 2181 | } |
| 2110 | 2182 | ||
| 2111 | /* | 2183 | /* |
| @@ -2124,6 +2196,7 @@ register LQIMODE1 { | |||
| 2124 | field ENLQIBADLQI 0x04 | 2196 | field ENLQIBADLQI 0x04 |
| 2125 | field ENLQIOVERI_LQ 0x02 /* LQIOVERI1 */ | 2197 | field ENLQIOVERI_LQ 0x02 /* LQIOVERI1 */ |
| 2126 | field ENLQIOVERI_NLQ 0x01 /* LQIOVERI2 */ | 2198 | field ENLQIOVERI_NLQ 0x01 /* LQIOVERI2 */ |
| 2199 | dont_generate_debug_code | ||
| 2127 | } | 2200 | } |
| 2128 | 2201 | ||
| 2129 | /* | 2202 | /* |
| @@ -2165,6 +2238,7 @@ register CLRSINT3 { | |||
| 2165 | count 3 | 2238 | count 3 |
| 2166 | field CLRNTRAMPERR 0x02 | 2239 | field CLRNTRAMPERR 0x02 |
| 2167 | field CLROSRAMPERR 0x01 | 2240 | field CLROSRAMPERR 0x01 |
| 2241 | dont_generate_debug_code | ||
| 2168 | } | 2242 | } |
| 2169 | 2243 | ||
| 2170 | /* | 2244 | /* |
| @@ -2177,6 +2251,7 @@ register SIMODE3 { | |||
| 2177 | count 4 | 2251 | count 4 |
| 2178 | field ENNTRAMPERR 0x02 | 2252 | field ENNTRAMPERR 0x02 |
| 2179 | field ENOSRAMPERR 0x01 | 2253 | field ENOSRAMPERR 0x01 |
| 2254 | dont_generate_debug_code | ||
| 2180 | } | 2255 | } |
| 2181 | 2256 | ||
| 2182 | /* | 2257 | /* |
| @@ -2207,6 +2282,7 @@ register CLRLQOINT0 { | |||
| 2207 | field CLRLQOATNLQ 0x04 | 2282 | field CLRLQOATNLQ 0x04 |
| 2208 | field CLRLQOATNPKT 0x02 | 2283 | field CLRLQOATNPKT 0x02 |
| 2209 | field CLRLQOTCRC 0x01 | 2284 | field CLRLQOTCRC 0x01 |
| 2285 | dont_generate_debug_code | ||
| 2210 | } | 2286 | } |
| 2211 | 2287 | ||
| 2212 | /* | 2288 | /* |
| @@ -2222,6 +2298,7 @@ register LQOMODE0 { | |||
| 2222 | field ENLQOATNLQ 0x04 | 2298 | field ENLQOATNLQ 0x04 |
| 2223 | field ENLQOATNPKT 0x02 | 2299 | field ENLQOATNPKT 0x02 |
| 2224 | field ENLQOTCRC 0x01 | 2300 | field ENLQOTCRC 0x01 |
| 2301 | dont_generate_debug_code | ||
| 2225 | } | 2302 | } |
| 2226 | 2303 | ||
| 2227 | /* | 2304 | /* |
| @@ -2251,6 +2328,7 @@ register CLRLQOINT1 { | |||
| 2251 | field CLRLQOBADQAS 0x04 | 2328 | field CLRLQOBADQAS 0x04 |
| 2252 | field CLRLQOBUSFREE 0x02 | 2329 | field CLRLQOBUSFREE 0x02 |
| 2253 | field CLRLQOPHACHGINPKT 0x01 | 2330 | field CLRLQOPHACHGINPKT 0x01 |
| 2331 | dont_generate_debug_code | ||
| 2254 | } | 2332 | } |
| 2255 | 2333 | ||
| 2256 | /* | 2334 | /* |
| @@ -2266,6 +2344,7 @@ register LQOMODE1 { | |||
| 2266 | field ENLQOBADQAS 0x04 | 2344 | field ENLQOBADQAS 0x04 |
| 2267 | field ENLQOBUSFREE 0x02 | 2345 | field ENLQOBUSFREE 0x02 |
| 2268 | field ENLQOPHACHGINPKT 0x01 | 2346 | field ENLQOPHACHGINPKT 0x01 |
| 2347 | dont_generate_debug_code | ||
| 2269 | } | 2348 | } |
| 2270 | 2349 | ||
| 2271 | /* | 2350 | /* |
| @@ -2289,6 +2368,7 @@ register OS_SPACE_CNT { | |||
| 2289 | access_mode RO | 2368 | access_mode RO |
| 2290 | modes M_CFG | 2369 | modes M_CFG |
| 2291 | count 2 | 2370 | count 2 |
| 2371 | dont_generate_debug_code | ||
| 2292 | } | 2372 | } |
| 2293 | 2373 | ||
| 2294 | /* | 2374 | /* |
| @@ -2318,6 +2398,7 @@ register GSFIFO { | |||
| 2318 | access_mode RO | 2398 | access_mode RO |
| 2319 | size 2 | 2399 | size 2 |
| 2320 | modes M_DFF0, M_DFF1, M_SCSI | 2400 | modes M_DFF0, M_DFF1, M_SCSI |
| 2401 | dont_generate_debug_code | ||
| 2321 | } | 2402 | } |
| 2322 | 2403 | ||
| 2323 | /* | 2404 | /* |
| @@ -2341,6 +2422,7 @@ register NEXTSCB { | |||
| 2341 | access_mode RW | 2422 | access_mode RW |
| 2342 | size 2 | 2423 | size 2 |
| 2343 | modes M_SCSI | 2424 | modes M_SCSI |
| 2425 | dont_generate_debug_code | ||
| 2344 | } | 2426 | } |
| 2345 | 2427 | ||
| 2346 | /* | 2428 | /* |
| @@ -2357,6 +2439,7 @@ register LQOSCSCTL { | |||
| 2357 | field LQOBUSETDLY 0x40 | 2439 | field LQOBUSETDLY 0x40 |
| 2358 | field LQONOHOLDLACK 0x02 | 2440 | field LQONOHOLDLACK 0x02 |
| 2359 | field LQONOCHKOVER 0x01 | 2441 | field LQONOCHKOVER 0x01 |
| 2442 | dont_generate_debug_code | ||
| 2360 | } | 2443 | } |
| 2361 | 2444 | ||
| 2362 | /* | 2445 | /* |
| @@ -2389,6 +2472,7 @@ register CLRSEQINTSRC { | |||
| 2389 | field CLRCFG4TSTAT 0x04 | 2472 | field CLRCFG4TSTAT 0x04 |
| 2390 | field CLRCFG4ICMD 0x02 | 2473 | field CLRCFG4ICMD 0x02 |
| 2391 | field CLRCFG4TCMD 0x01 | 2474 | field CLRCFG4TCMD 0x01 |
| 2475 | dont_generate_debug_code | ||
| 2392 | } | 2476 | } |
| 2393 | 2477 | ||
| 2394 | /* | 2478 | /* |
| @@ -2415,6 +2499,7 @@ register CURRSCB { | |||
| 2415 | access_mode RW | 2499 | access_mode RW |
| 2416 | size 2 | 2500 | size 2 |
| 2417 | modes M_SCSI | 2501 | modes M_SCSI |
| 2502 | dont_generate_debug_code | ||
| 2418 | } | 2503 | } |
| 2419 | 2504 | ||
| 2420 | /* | 2505 | /* |
| @@ -2472,6 +2557,7 @@ register LASTSCB { | |||
| 2472 | access_mode RW | 2557 | access_mode RW |
| 2473 | size 2 | 2558 | size 2 |
| 2474 | modes M_SCSI | 2559 | modes M_SCSI |
| 2560 | dont_generate_debug_code | ||
| 2475 | } | 2561 | } |
| 2476 | 2562 | ||
| 2477 | /* | 2563 | /* |
| @@ -2494,6 +2580,7 @@ register SHADDR { | |||
| 2494 | access_mode RO | 2580 | access_mode RO |
| 2495 | size 8 | 2581 | size 8 |
| 2496 | modes M_DFF0, M_DFF1 | 2582 | modes M_DFF0, M_DFF1 |
| 2583 | dont_generate_debug_code | ||
| 2497 | } | 2584 | } |
| 2498 | 2585 | ||
| 2499 | /* | 2586 | /* |
| @@ -2513,6 +2600,7 @@ register NEGOADDR { | |||
| 2513 | address 0x060 | 2600 | address 0x060 |
| 2514 | access_mode RW | 2601 | access_mode RW |
| 2515 | modes M_SCSI | 2602 | modes M_SCSI |
| 2603 | dont_generate_debug_code | ||
| 2516 | } | 2604 | } |
| 2517 | 2605 | ||
| 2518 | /* | 2606 | /* |
| @@ -2523,6 +2611,7 @@ register NEGPERIOD { | |||
| 2523 | access_mode RW | 2611 | access_mode RW |
| 2524 | modes M_SCSI | 2612 | modes M_SCSI |
| 2525 | count 1 | 2613 | count 1 |
| 2614 | dont_generate_debug_code | ||
| 2526 | } | 2615 | } |
| 2527 | 2616 | ||
| 2528 | /* | 2617 | /* |
| @@ -2543,6 +2632,7 @@ register NEGOFFSET { | |||
| 2543 | access_mode RW | 2632 | access_mode RW |
| 2544 | modes M_SCSI | 2633 | modes M_SCSI |
| 2545 | count 1 | 2634 | count 1 |
| 2635 | dont_generate_debug_code | ||
| 2546 | } | 2636 | } |
| 2547 | 2637 | ||
| 2548 | /* | 2638 | /* |
| @@ -2557,6 +2647,7 @@ register NEGPPROPTS { | |||
| 2557 | field PPROPT_QAS 0x04 | 2647 | field PPROPT_QAS 0x04 |
| 2558 | field PPROPT_DT 0x02 | 2648 | field PPROPT_DT 0x02 |
| 2559 | field PPROPT_IUT 0x01 | 2649 | field PPROPT_IUT 0x01 |
| 2650 | dont_generate_debug_code | ||
| 2560 | } | 2651 | } |
| 2561 | 2652 | ||
| 2562 | /* | 2653 | /* |
| @@ -2573,6 +2664,7 @@ register NEGCONOPTS { | |||
| 2573 | field ENAUTOATNI 0x04 | 2664 | field ENAUTOATNI 0x04 |
| 2574 | field ENAUTOATNO 0x02 | 2665 | field ENAUTOATNO 0x02 |
| 2575 | field WIDEXFER 0x01 | 2666 | field WIDEXFER 0x01 |
| 2667 | dont_generate_debug_code | ||
| 2576 | } | 2668 | } |
| 2577 | 2669 | ||
| 2578 | /* | 2670 | /* |
| @@ -2583,6 +2675,7 @@ register ANNEXCOL { | |||
| 2583 | access_mode RW | 2675 | access_mode RW |
| 2584 | modes M_SCSI | 2676 | modes M_SCSI |
| 2585 | count 7 | 2677 | count 7 |
| 2678 | dont_generate_debug_code | ||
| 2586 | } | 2679 | } |
| 2587 | 2680 | ||
| 2588 | /* | 2681 | /* |
| @@ -2602,6 +2695,7 @@ register SCSCHKN { | |||
| 2602 | field DFFACTCLR 0x04 | 2695 | field DFFACTCLR 0x04 |
| 2603 | field SHVALIDSTDIS 0x02 | 2696 | field SHVALIDSTDIS 0x02 |
| 2604 | field LSTSGCLRDIS 0x01 | 2697 | field LSTSGCLRDIS 0x01 |
| 2698 | dont_generate_debug_code | ||
| 2605 | } | 2699 | } |
| 2606 | 2700 | ||
| 2607 | const AHD_ANNEXCOL_PER_DEV0 4 | 2701 | const AHD_ANNEXCOL_PER_DEV0 4 |
| @@ -2635,6 +2729,7 @@ register ANNEXDAT { | |||
| 2635 | access_mode RW | 2729 | access_mode RW |
| 2636 | modes M_SCSI | 2730 | modes M_SCSI |
| 2637 | count 3 | 2731 | count 3 |
| 2732 | dont_generate_debug_code | ||
| 2638 | } | 2733 | } |
| 2639 | 2734 | ||
| 2640 | /* | 2735 | /* |
| @@ -2645,6 +2740,7 @@ register IOWNID { | |||
| 2645 | address 0x067 | 2740 | address 0x067 |
| 2646 | access_mode RW | 2741 | access_mode RW |
| 2647 | modes M_SCSI | 2742 | modes M_SCSI |
| 2743 | dont_generate_debug_code | ||
| 2648 | } | 2744 | } |
| 2649 | 2745 | ||
| 2650 | /* | 2746 | /* |
| @@ -2671,6 +2767,7 @@ register TOWNID { | |||
| 2671 | access_mode RW | 2767 | access_mode RW |
| 2672 | modes M_SCSI | 2768 | modes M_SCSI |
| 2673 | count 2 | 2769 | count 2 |
| 2770 | dont_generate_debug_code | ||
| 2674 | } | 2771 | } |
| 2675 | 2772 | ||
| 2676 | /* | 2773 | /* |
| @@ -2702,6 +2799,7 @@ register SHCNT { | |||
| 2702 | access_mode RW | 2799 | access_mode RW |
| 2703 | size 3 | 2800 | size 3 |
| 2704 | modes M_DFF0, M_DFF1 | 2801 | modes M_DFF0, M_DFF1 |
| 2802 | dont_generate_debug_code | ||
| 2705 | } | 2803 | } |
| 2706 | 2804 | ||
| 2707 | /* | 2805 | /* |
| @@ -2789,6 +2887,7 @@ register SCBPTR { | |||
| 2789 | access_mode RW | 2887 | access_mode RW |
| 2790 | size 2 | 2888 | size 2 |
| 2791 | modes M_DFF0, M_DFF1, M_CCHAN, M_SCSI | 2889 | modes M_DFF0, M_DFF1, M_CCHAN, M_SCSI |
| 2890 | dont_generate_debug_code | ||
| 2792 | } | 2891 | } |
| 2793 | 2892 | ||
| 2794 | /* | 2893 | /* |
| @@ -2816,6 +2915,7 @@ register SCBAUTOPTR { | |||
| 2816 | field AUSCBPTR_EN 0x80 | 2915 | field AUSCBPTR_EN 0x80 |
| 2817 | field SCBPTR_ADDR 0x38 | 2916 | field SCBPTR_ADDR 0x38 |
| 2818 | field SCBPTR_OFF 0x07 | 2917 | field SCBPTR_OFF 0x07 |
| 2918 | dont_generate_debug_code | ||
| 2819 | } | 2919 | } |
| 2820 | 2920 | ||
| 2821 | /* | 2921 | /* |
| @@ -2825,6 +2925,7 @@ register CCSGADDR { | |||
| 2825 | address 0x0AC | 2925 | address 0x0AC |
| 2826 | access_mode RW | 2926 | access_mode RW |
| 2827 | modes M_DFF0, M_DFF1 | 2927 | modes M_DFF0, M_DFF1 |
| 2928 | dont_generate_debug_code | ||
| 2828 | } | 2929 | } |
| 2829 | 2930 | ||
| 2830 | /* | 2931 | /* |
| @@ -2834,6 +2935,7 @@ register CCSCBADDR { | |||
| 2834 | address 0x0AC | 2935 | address 0x0AC |
| 2835 | access_mode RW | 2936 | access_mode RW |
| 2836 | modes M_CCHAN | 2937 | modes M_CCHAN |
| 2938 | dont_generate_debug_code | ||
| 2837 | } | 2939 | } |
| 2838 | 2940 | ||
| 2839 | /* | 2941 | /* |
| @@ -2899,6 +3001,7 @@ register CCSGRAM { | |||
| 2899 | address 0x0B0 | 3001 | address 0x0B0 |
| 2900 | access_mode RW | 3002 | access_mode RW |
| 2901 | modes M_DFF0, M_DFF1 | 3003 | modes M_DFF0, M_DFF1 |
| 3004 | dont_generate_debug_code | ||
| 2902 | } | 3005 | } |
| 2903 | 3006 | ||
| 2904 | /* | 3007 | /* |
| @@ -2908,6 +3011,7 @@ register CCSCBRAM { | |||
| 2908 | address 0x0B0 | 3011 | address 0x0B0 |
| 2909 | access_mode RW | 3012 | access_mode RW |
| 2910 | modes M_CCHAN | 3013 | modes M_CCHAN |
| 3014 | dont_generate_debug_code | ||
| 2911 | } | 3015 | } |
| 2912 | 3016 | ||
| 2913 | /* | 3017 | /* |
| @@ -2958,6 +3062,7 @@ register BRDDAT { | |||
| 2958 | access_mode RW | 3062 | access_mode RW |
| 2959 | modes M_SCSI | 3063 | modes M_SCSI |
| 2960 | count 2 | 3064 | count 2 |
| 3065 | dont_generate_debug_code | ||
| 2961 | } | 3066 | } |
| 2962 | 3067 | ||
| 2963 | /* | 3068 | /* |
| @@ -2974,6 +3079,7 @@ register BRDCTL { | |||
| 2974 | field BRDEN 0x04 | 3079 | field BRDEN 0x04 |
| 2975 | field BRDRW 0x02 | 3080 | field BRDRW 0x02 |
| 2976 | field BRDSTB 0x01 | 3081 | field BRDSTB 0x01 |
| 3082 | dont_generate_debug_code | ||
| 2977 | } | 3083 | } |
| 2978 | 3084 | ||
| 2979 | /* | 3085 | /* |
| @@ -2984,6 +3090,7 @@ register SEEADR { | |||
| 2984 | access_mode RW | 3090 | access_mode RW |
| 2985 | modes M_SCSI | 3091 | modes M_SCSI |
| 2986 | count 4 | 3092 | count 4 |
| 3093 | dont_generate_debug_code | ||
| 2987 | } | 3094 | } |
| 2988 | 3095 | ||
| 2989 | /* | 3096 | /* |
| @@ -2995,6 +3102,7 @@ register SEEDAT { | |||
| 2995 | size 2 | 3102 | size 2 |
| 2996 | modes M_SCSI | 3103 | modes M_SCSI |
| 2997 | count 4 | 3104 | count 4 |
| 3105 | dont_generate_debug_code | ||
| 2998 | } | 3106 | } |
| 2999 | 3107 | ||
| 3000 | /* | 3108 | /* |
| @@ -3011,6 +3119,7 @@ register SEESTAT { | |||
| 3011 | field SEEARBACK 0x04 | 3119 | field SEEARBACK 0x04 |
| 3012 | field SEEBUSY 0x02 | 3120 | field SEEBUSY 0x02 |
| 3013 | field SEESTART 0x01 | 3121 | field SEESTART 0x01 |
| 3122 | dont_generate_debug_code | ||
| 3014 | } | 3123 | } |
| 3015 | 3124 | ||
| 3016 | /* | 3125 | /* |
| @@ -3036,6 +3145,7 @@ register SEECTL { | |||
| 3036 | mask SEEOP_EWDS 0x40 | 3145 | mask SEEOP_EWDS 0x40 |
| 3037 | field SEERST 0x02 | 3146 | field SEERST 0x02 |
| 3038 | field SEESTART 0x01 | 3147 | field SEESTART 0x01 |
| 3148 | dont_generate_debug_code | ||
| 3039 | } | 3149 | } |
| 3040 | 3150 | ||
| 3041 | const SEEOP_ERAL_ADDR 0x80 | 3151 | const SEEOP_ERAL_ADDR 0x80 |
| @@ -3050,6 +3160,7 @@ register SCBCNT { | |||
| 3050 | address 0x0BF | 3160 | address 0x0BF |
| 3051 | access_mode RW | 3161 | access_mode RW |
| 3052 | modes M_SCSI | 3162 | modes M_SCSI |
| 3163 | dont_generate_debug_code | ||
| 3053 | } | 3164 | } |
| 3054 | 3165 | ||
| 3055 | /* | 3166 | /* |
| @@ -3061,6 +3172,7 @@ register DFWADDR { | |||
| 3061 | access_mode RW | 3172 | access_mode RW |
| 3062 | size 2 | 3173 | size 2 |
| 3063 | modes M_DFF0, M_DFF1 | 3174 | modes M_DFF0, M_DFF1 |
| 3175 | dont_generate_debug_code | ||
| 3064 | } | 3176 | } |
| 3065 | 3177 | ||
| 3066 | /* | 3178 | /* |
| @@ -3087,6 +3199,7 @@ register DSPDATACTL { | |||
| 3087 | field DESQDIS 0x10 | 3199 | field DESQDIS 0x10 |
| 3088 | field RCVROFFSTDIS 0x04 | 3200 | field RCVROFFSTDIS 0x04 |
| 3089 | field XMITOFFSTDIS 0x02 | 3201 | field XMITOFFSTDIS 0x02 |
| 3202 | dont_generate_debug_code | ||
| 3090 | } | 3203 | } |
| 3091 | 3204 | ||
| 3092 | /* | 3205 | /* |
| @@ -3132,6 +3245,7 @@ register DFDAT { | |||
| 3132 | address 0x0C4 | 3245 | address 0x0C4 |
| 3133 | access_mode RW | 3246 | access_mode RW |
| 3134 | modes M_DFF0, M_DFF1 | 3247 | modes M_DFF0, M_DFF1 |
| 3248 | dont_generate_debug_code | ||
| 3135 | } | 3249 | } |
| 3136 | 3250 | ||
| 3137 | /* | 3251 | /* |
| @@ -3144,6 +3258,7 @@ register DSPSELECT { | |||
| 3144 | count 1 | 3258 | count 1 |
| 3145 | field AUTOINCEN 0x80 | 3259 | field AUTOINCEN 0x80 |
| 3146 | field DSPSEL 0x1F | 3260 | field DSPSEL 0x1F |
| 3261 | dont_generate_debug_code | ||
| 3147 | } | 3262 | } |
| 3148 | 3263 | ||
| 3149 | const NUMDSPS 0x14 | 3264 | const NUMDSPS 0x14 |
| @@ -3158,6 +3273,7 @@ register WRTBIASCTL { | |||
| 3158 | count 3 | 3273 | count 3 |
| 3159 | field AUTOXBCDIS 0x80 | 3274 | field AUTOXBCDIS 0x80 |
| 3160 | field XMITMANVAL 0x3F | 3275 | field XMITMANVAL 0x3F |
| 3276 | dont_generate_debug_code | ||
| 3161 | } | 3277 | } |
| 3162 | 3278 | ||
| 3163 | /* | 3279 | /* |
| @@ -3316,6 +3432,7 @@ register FLAGS { | |||
| 3316 | count 23 | 3432 | count 23 |
| 3317 | field ZERO 0x02 | 3433 | field ZERO 0x02 |
| 3318 | field CARRY 0x01 | 3434 | field CARRY 0x01 |
| 3435 | dont_generate_debug_code | ||
| 3319 | } | 3436 | } |
| 3320 | 3437 | ||
| 3321 | /* | 3438 | /* |
| @@ -3344,6 +3461,7 @@ register SEQRAM { | |||
| 3344 | address 0x0DA | 3461 | address 0x0DA |
| 3345 | access_mode RW | 3462 | access_mode RW |
| 3346 | count 2 | 3463 | count 2 |
| 3464 | dont_generate_debug_code | ||
| 3347 | } | 3465 | } |
| 3348 | 3466 | ||
| 3349 | /* | 3467 | /* |
| @@ -3355,6 +3473,7 @@ register PRGMCNT { | |||
| 3355 | access_mode RW | 3473 | access_mode RW |
| 3356 | size 2 | 3474 | size 2 |
| 3357 | count 5 | 3475 | count 5 |
| 3476 | dont_generate_debug_code | ||
| 3358 | } | 3477 | } |
| 3359 | 3478 | ||
| 3360 | /* | 3479 | /* |
| @@ -3364,6 +3483,7 @@ register ACCUM { | |||
| 3364 | address 0x0E0 | 3483 | address 0x0E0 |
| 3365 | access_mode RW | 3484 | access_mode RW |
| 3366 | accumulator | 3485 | accumulator |
| 3486 | dont_generate_debug_code | ||
| 3367 | } | 3487 | } |
| 3368 | 3488 | ||
| 3369 | /* | 3489 | /* |
| @@ -3380,6 +3500,7 @@ register SINDEX { | |||
| 3380 | access_mode RW | 3500 | access_mode RW |
| 3381 | size 2 | 3501 | size 2 |
| 3382 | sindex | 3502 | sindex |
| 3503 | dont_generate_debug_code | ||
| 3383 | } | 3504 | } |
| 3384 | 3505 | ||
| 3385 | /* | 3506 | /* |
| @@ -3390,6 +3511,7 @@ register DINDEX { | |||
| 3390 | address 0x0E4 | 3511 | address 0x0E4 |
| 3391 | access_mode RW | 3512 | access_mode RW |
| 3392 | size 2 | 3513 | size 2 |
| 3514 | dont_generate_debug_code | ||
| 3393 | } | 3515 | } |
| 3394 | 3516 | ||
| 3395 | /* | 3517 | /* |
| @@ -3415,6 +3537,7 @@ register ALLONES { | |||
| 3415 | address 0x0E8 | 3537 | address 0x0E8 |
| 3416 | access_mode RO | 3538 | access_mode RO |
| 3417 | allones | 3539 | allones |
| 3540 | dont_generate_debug_code | ||
| 3418 | } | 3541 | } |
| 3419 | 3542 | ||
| 3420 | /* | 3543 | /* |
| @@ -3425,6 +3548,7 @@ register ALLZEROS { | |||
| 3425 | address 0x0EA | 3548 | address 0x0EA |
| 3426 | access_mode RO | 3549 | access_mode RO |
| 3427 | allzeros | 3550 | allzeros |
| 3551 | dont_generate_debug_code | ||
| 3428 | } | 3552 | } |
| 3429 | 3553 | ||
| 3430 | /* | 3554 | /* |
| @@ -3435,6 +3559,7 @@ register NONE { | |||
| 3435 | address 0x0EA | 3559 | address 0x0EA |
| 3436 | access_mode WO | 3560 | access_mode WO |
| 3437 | none | 3561 | none |
| 3562 | dont_generate_debug_code | ||
| 3438 | } | 3563 | } |
| 3439 | 3564 | ||
| 3440 | /* | 3565 | /* |
| @@ -3445,6 +3570,7 @@ register NONE { | |||
| 3445 | register SINDIR { | 3570 | register SINDIR { |
| 3446 | address 0x0EC | 3571 | address 0x0EC |
| 3447 | access_mode RO | 3572 | access_mode RO |
| 3573 | dont_generate_debug_code | ||
| 3448 | } | 3574 | } |
| 3449 | 3575 | ||
| 3450 | /* | 3576 | /* |
| @@ -3455,6 +3581,7 @@ register SINDIR { | |||
| 3455 | register DINDIR { | 3581 | register DINDIR { |
| 3456 | address 0x0ED | 3582 | address 0x0ED |
| 3457 | access_mode WO | 3583 | access_mode WO |
| 3584 | dont_generate_debug_code | ||
| 3458 | } | 3585 | } |
| 3459 | 3586 | ||
| 3460 | /* | 3587 | /* |
| @@ -3479,6 +3606,7 @@ register FUNCTION1 { | |||
| 3479 | register STACK { | 3606 | register STACK { |
| 3480 | address 0x0F2 | 3607 | address 0x0F2 |
| 3481 | access_mode RW | 3608 | access_mode RW |
| 3609 | dont_generate_debug_code | ||
| 3482 | } | 3610 | } |
| 3483 | 3611 | ||
| 3484 | /* | 3612 | /* |
| @@ -3491,6 +3619,7 @@ register INTVEC1_ADDR { | |||
| 3491 | size 2 | 3619 | size 2 |
| 3492 | modes M_CFG | 3620 | modes M_CFG |
| 3493 | count 1 | 3621 | count 1 |
| 3622 | dont_generate_debug_code | ||
| 3494 | } | 3623 | } |
| 3495 | 3624 | ||
| 3496 | /* | 3625 | /* |
| @@ -3503,6 +3632,7 @@ register CURADDR { | |||
| 3503 | size 2 | 3632 | size 2 |
| 3504 | modes M_SCSI | 3633 | modes M_SCSI |
| 3505 | count 2 | 3634 | count 2 |
| 3635 | dont_generate_debug_code | ||
| 3506 | } | 3636 | } |
| 3507 | 3637 | ||
| 3508 | /* | 3638 | /* |
| @@ -3515,6 +3645,7 @@ register INTVEC2_ADDR { | |||
| 3515 | size 2 | 3645 | size 2 |
| 3516 | modes M_CFG | 3646 | modes M_CFG |
| 3517 | count 1 | 3647 | count 1 |
| 3648 | dont_generate_debug_code | ||
| 3518 | } | 3649 | } |
| 3519 | 3650 | ||
| 3520 | /* | 3651 | /* |
| @@ -3543,12 +3674,14 @@ scratch_ram { | |||
| 3543 | modes 0, 1, 2, 3 | 3674 | modes 0, 1, 2, 3 |
| 3544 | REG0 { | 3675 | REG0 { |
| 3545 | size 2 | 3676 | size 2 |
| 3677 | dont_generate_debug_code | ||
| 3546 | } | 3678 | } |
| 3547 | REG1 { | 3679 | REG1 { |
| 3548 | size 2 | 3680 | size 2 |
| 3549 | } | 3681 | } |
| 3550 | REG_ISR { | 3682 | REG_ISR { |
| 3551 | size 2 | 3683 | size 2 |
| 3684 | dont_generate_debug_code | ||
| 3552 | } | 3685 | } |
| 3553 | SG_STATE { | 3686 | SG_STATE { |
| 3554 | size 1 | 3687 | size 1 |
| @@ -3572,9 +3705,11 @@ scratch_ram { | |||
| 3572 | modes 0, 1, 2, 3 | 3705 | modes 0, 1, 2, 3 |
| 3573 | LONGJMP_ADDR { | 3706 | LONGJMP_ADDR { |
| 3574 | size 2 | 3707 | size 2 |
| 3708 | dont_generate_debug_code | ||
| 3575 | } | 3709 | } |
| 3576 | ACCUM_SAVE { | 3710 | ACCUM_SAVE { |
| 3577 | size 1 | 3711 | size 1 |
| 3712 | dont_generate_debug_code | ||
| 3578 | } | 3713 | } |
| 3579 | } | 3714 | } |
| 3580 | 3715 | ||
| @@ -3591,18 +3726,22 @@ scratch_ram { | |||
| 3591 | */ | 3726 | */ |
| 3592 | WAITING_SCB_TAILS { | 3727 | WAITING_SCB_TAILS { |
| 3593 | size 32 | 3728 | size 32 |
| 3729 | dont_generate_debug_code | ||
| 3594 | } | 3730 | } |
| 3595 | WAITING_TID_HEAD { | 3731 | WAITING_TID_HEAD { |
| 3596 | size 2 | 3732 | size 2 |
| 3733 | dont_generate_debug_code | ||
| 3597 | } | 3734 | } |
| 3598 | WAITING_TID_TAIL { | 3735 | WAITING_TID_TAIL { |
| 3599 | size 2 | 3736 | size 2 |
| 3737 | dont_generate_debug_code | ||
| 3600 | } | 3738 | } |
| 3601 | /* | 3739 | /* |
| 3602 | * SCBID of the next SCB in the new SCB queue. | 3740 | * SCBID of the next SCB in the new SCB queue. |
| 3603 | */ | 3741 | */ |
| 3604 | NEXT_QUEUED_SCB_ADDR { | 3742 | NEXT_QUEUED_SCB_ADDR { |
| 3605 | size 4 | 3743 | size 4 |
| 3744 | dont_generate_debug_code | ||
| 3606 | } | 3745 | } |
| 3607 | /* | 3746 | /* |
| 3608 | * head of list of SCBs that have | 3747 | * head of list of SCBs that have |
| @@ -3611,6 +3750,7 @@ scratch_ram { | |||
| 3611 | */ | 3750 | */ |
| 3612 | COMPLETE_SCB_HEAD { | 3751 | COMPLETE_SCB_HEAD { |
| 3613 | size 2 | 3752 | size 2 |
| 3753 | dont_generate_debug_code | ||
| 3614 | } | 3754 | } |
| 3615 | /* | 3755 | /* |
| 3616 | * The list of completed SCBs in | 3756 | * The list of completed SCBs in |
| @@ -3618,6 +3758,7 @@ scratch_ram { | |||
| 3618 | */ | 3758 | */ |
| 3619 | COMPLETE_SCB_DMAINPROG_HEAD { | 3759 | COMPLETE_SCB_DMAINPROG_HEAD { |
| 3620 | size 2 | 3760 | size 2 |
| 3761 | dont_generate_debug_code | ||
| 3621 | } | 3762 | } |
| 3622 | /* | 3763 | /* |
| 3623 | * head of list of SCBs that have | 3764 | * head of list of SCBs that have |
| @@ -3626,6 +3767,7 @@ scratch_ram { | |||
| 3626 | */ | 3767 | */ |
| 3627 | COMPLETE_DMA_SCB_HEAD { | 3768 | COMPLETE_DMA_SCB_HEAD { |
| 3628 | size 2 | 3769 | size 2 |
| 3770 | dont_generate_debug_code | ||
| 3629 | } | 3771 | } |
| 3630 | /* | 3772 | /* |
| 3631 | * tail of list of SCBs that have | 3773 | * tail of list of SCBs that have |
| @@ -3634,6 +3776,7 @@ scratch_ram { | |||
| 3634 | */ | 3776 | */ |
| 3635 | COMPLETE_DMA_SCB_TAIL { | 3777 | COMPLETE_DMA_SCB_TAIL { |
| 3636 | size 2 | 3778 | size 2 |
| 3779 | dont_generate_debug_code | ||
| 3637 | } | 3780 | } |
| 3638 | /* | 3781 | /* |
| 3639 | * head of list of SCBs that have | 3782 | * head of list of SCBs that have |
| @@ -3643,6 +3786,7 @@ scratch_ram { | |||
| 3643 | */ | 3786 | */ |
| 3644 | COMPLETE_ON_QFREEZE_HEAD { | 3787 | COMPLETE_ON_QFREEZE_HEAD { |
| 3645 | size 2 | 3788 | size 2 |
| 3789 | dont_generate_debug_code | ||
| 3646 | } | 3790 | } |
| 3647 | /* | 3791 | /* |
| 3648 | * Counting semaphore to prevent new select-outs | 3792 | * Counting semaphore to prevent new select-outs |
| @@ -3667,6 +3811,7 @@ scratch_ram { | |||
| 3667 | */ | 3811 | */ |
| 3668 | MSG_OUT { | 3812 | MSG_OUT { |
| 3669 | size 1 | 3813 | size 1 |
| 3814 | dont_generate_debug_code | ||
| 3670 | } | 3815 | } |
| 3671 | /* Parameters for DMA Logic */ | 3816 | /* Parameters for DMA Logic */ |
| 3672 | DMAPARAMS { | 3817 | DMAPARAMS { |
| @@ -3682,6 +3827,7 @@ scratch_ram { | |||
| 3682 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ | 3827 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ |
| 3683 | field FIFOFLUSH 0x02 | 3828 | field FIFOFLUSH 0x02 |
| 3684 | field FIFORESET 0x01 | 3829 | field FIFORESET 0x01 |
| 3830 | dont_generate_debug_code | ||
| 3685 | } | 3831 | } |
| 3686 | SEQ_FLAGS { | 3832 | SEQ_FLAGS { |
| 3687 | size 1 | 3833 | size 1 |
| @@ -3703,9 +3849,11 @@ scratch_ram { | |||
| 3703 | */ | 3849 | */ |
| 3704 | SAVED_SCSIID { | 3850 | SAVED_SCSIID { |
| 3705 | size 1 | 3851 | size 1 |
| 3852 | dont_generate_debug_code | ||
| 3706 | } | 3853 | } |
| 3707 | SAVED_LUN { | 3854 | SAVED_LUN { |
| 3708 | size 1 | 3855 | size 1 |
| 3856 | dont_generate_debug_code | ||
| 3709 | } | 3857 | } |
| 3710 | /* | 3858 | /* |
| 3711 | * The last bus phase as seen by the sequencer. | 3859 | * The last bus phase as seen by the sequencer. |
| @@ -3733,6 +3881,7 @@ scratch_ram { | |||
| 3733 | */ | 3881 | */ |
| 3734 | QOUTFIFO_ENTRY_VALID_TAG { | 3882 | QOUTFIFO_ENTRY_VALID_TAG { |
| 3735 | size 1 | 3883 | size 1 |
| 3884 | dont_generate_debug_code | ||
| 3736 | } | 3885 | } |
| 3737 | /* | 3886 | /* |
| 3738 | * Kernel and sequencer offsets into the queue of | 3887 | * Kernel and sequencer offsets into the queue of |
| @@ -3742,10 +3891,12 @@ scratch_ram { | |||
| 3742 | KERNEL_TQINPOS { | 3891 | KERNEL_TQINPOS { |
| 3743 | size 1 | 3892 | size 1 |
| 3744 | count 1 | 3893 | count 1 |
| 3894 | dont_generate_debug_code | ||
| 3745 | } | 3895 | } |
| 3746 | TQINPOS { | 3896 | TQINPOS { |
| 3747 | size 1 | 3897 | size 1 |
| 3748 | count 8 | 3898 | count 8 |
| 3899 | dont_generate_debug_code | ||
| 3749 | } | 3900 | } |
| 3750 | /* | 3901 | /* |
| 3751 | * Base address of our shared data with the kernel driver in host | 3902 | * Base address of our shared data with the kernel driver in host |
| @@ -3754,6 +3905,7 @@ scratch_ram { | |||
| 3754 | */ | 3905 | */ |
| 3755 | SHARED_DATA_ADDR { | 3906 | SHARED_DATA_ADDR { |
| 3756 | size 4 | 3907 | size 4 |
| 3908 | dont_generate_debug_code | ||
| 3757 | } | 3909 | } |
| 3758 | /* | 3910 | /* |
| 3759 | * Pointer to location in host memory for next | 3911 | * Pointer to location in host memory for next |
| @@ -3761,6 +3913,7 @@ scratch_ram { | |||
| 3761 | */ | 3913 | */ |
| 3762 | QOUTFIFO_NEXT_ADDR { | 3914 | QOUTFIFO_NEXT_ADDR { |
| 3763 | size 4 | 3915 | size 4 |
| 3916 | dont_generate_debug_code | ||
| 3764 | } | 3917 | } |
| 3765 | ARG_1 { | 3918 | ARG_1 { |
| 3766 | size 1 | 3919 | size 1 |
| @@ -3773,11 +3926,13 @@ scratch_ram { | |||
| 3773 | mask CONT_MSG_LOOP_READ 0x03 | 3926 | mask CONT_MSG_LOOP_READ 0x03 |
| 3774 | mask CONT_MSG_LOOP_TARG 0x02 | 3927 | mask CONT_MSG_LOOP_TARG 0x02 |
| 3775 | alias RETURN_1 | 3928 | alias RETURN_1 |
| 3929 | dont_generate_debug_code | ||
| 3776 | } | 3930 | } |
| 3777 | ARG_2 { | 3931 | ARG_2 { |
| 3778 | size 1 | 3932 | size 1 |
| 3779 | count 1 | 3933 | count 1 |
| 3780 | alias RETURN_2 | 3934 | alias RETURN_2 |
| 3935 | dont_generate_debug_code | ||
| 3781 | } | 3936 | } |
| 3782 | 3937 | ||
| 3783 | /* | 3938 | /* |
| @@ -3785,6 +3940,7 @@ scratch_ram { | |||
| 3785 | */ | 3940 | */ |
| 3786 | LAST_MSG { | 3941 | LAST_MSG { |
| 3787 | size 1 | 3942 | size 1 |
| 3943 | dont_generate_debug_code | ||
| 3788 | } | 3944 | } |
| 3789 | 3945 | ||
| 3790 | /* | 3946 | /* |
| @@ -3801,6 +3957,7 @@ scratch_ram { | |||
| 3801 | field MANUALP 0x0C | 3957 | field MANUALP 0x0C |
| 3802 | field ENAUTOATNP 0x02 | 3958 | field ENAUTOATNP 0x02 |
| 3803 | field ALTSTIM 0x01 | 3959 | field ALTSTIM 0x01 |
| 3960 | dont_generate_debug_code | ||
| 3804 | } | 3961 | } |
| 3805 | 3962 | ||
| 3806 | /* | 3963 | /* |
| @@ -3809,6 +3966,7 @@ scratch_ram { | |||
| 3809 | INITIATOR_TAG { | 3966 | INITIATOR_TAG { |
| 3810 | size 1 | 3967 | size 1 |
| 3811 | count 1 | 3968 | count 1 |
| 3969 | dont_generate_debug_code | ||
| 3812 | } | 3970 | } |
| 3813 | 3971 | ||
| 3814 | SEQ_FLAGS2 { | 3972 | SEQ_FLAGS2 { |
| @@ -3820,6 +3978,7 @@ scratch_ram { | |||
| 3820 | 3978 | ||
| 3821 | ALLOCFIFO_SCBPTR { | 3979 | ALLOCFIFO_SCBPTR { |
| 3822 | size 2 | 3980 | size 2 |
| 3981 | dont_generate_debug_code | ||
| 3823 | } | 3982 | } |
| 3824 | 3983 | ||
| 3825 | /* | 3984 | /* |
| @@ -3829,6 +3988,7 @@ scratch_ram { | |||
| 3829 | */ | 3988 | */ |
| 3830 | INT_COALESCING_TIMER { | 3989 | INT_COALESCING_TIMER { |
| 3831 | size 2 | 3990 | size 2 |
| 3991 | dont_generate_debug_code | ||
| 3832 | } | 3992 | } |
| 3833 | 3993 | ||
| 3834 | /* | 3994 | /* |
| @@ -3838,6 +3998,7 @@ scratch_ram { | |||
| 3838 | */ | 3998 | */ |
| 3839 | INT_COALESCING_MAXCMDS { | 3999 | INT_COALESCING_MAXCMDS { |
| 3840 | size 1 | 4000 | size 1 |
| 4001 | dont_generate_debug_code | ||
| 3841 | } | 4002 | } |
| 3842 | 4003 | ||
| 3843 | /* | 4004 | /* |
| @@ -3846,6 +4007,7 @@ scratch_ram { | |||
| 3846 | */ | 4007 | */ |
| 3847 | INT_COALESCING_MINCMDS { | 4008 | INT_COALESCING_MINCMDS { |
| 3848 | size 1 | 4009 | size 1 |
| 4010 | dont_generate_debug_code | ||
| 3849 | } | 4011 | } |
| 3850 | 4012 | ||
| 3851 | /* | 4013 | /* |
| @@ -3853,6 +4015,7 @@ scratch_ram { | |||
| 3853 | */ | 4015 | */ |
| 3854 | CMDS_PENDING { | 4016 | CMDS_PENDING { |
| 3855 | size 2 | 4017 | size 2 |
| 4018 | dont_generate_debug_code | ||
| 3856 | } | 4019 | } |
| 3857 | 4020 | ||
| 3858 | /* | 4021 | /* |
| @@ -3860,6 +4023,7 @@ scratch_ram { | |||
| 3860 | */ | 4023 | */ |
| 3861 | INT_COALESCING_CMDCOUNT { | 4024 | INT_COALESCING_CMDCOUNT { |
| 3862 | size 1 | 4025 | size 1 |
| 4026 | dont_generate_debug_code | ||
| 3863 | } | 4027 | } |
| 3864 | 4028 | ||
| 3865 | /* | 4029 | /* |
| @@ -3868,6 +4032,7 @@ scratch_ram { | |||
| 3868 | */ | 4032 | */ |
| 3869 | LOCAL_HS_MAILBOX { | 4033 | LOCAL_HS_MAILBOX { |
| 3870 | size 1 | 4034 | size 1 |
| 4035 | dont_generate_debug_code | ||
| 3871 | } | 4036 | } |
| 3872 | /* | 4037 | /* |
| 3873 | * Target-mode CDB type to CDB length table used | 4038 | * Target-mode CDB type to CDB length table used |
| @@ -3876,6 +4041,7 @@ scratch_ram { | |||
| 3876 | CMDSIZE_TABLE { | 4041 | CMDSIZE_TABLE { |
| 3877 | size 8 | 4042 | size 8 |
| 3878 | count 8 | 4043 | count 8 |
| 4044 | dont_generate_debug_code | ||
| 3879 | } | 4045 | } |
| 3880 | /* | 4046 | /* |
| 3881 | * When an SCB with the MK_MESSAGE flag is | 4047 | * When an SCB with the MK_MESSAGE flag is |
| @@ -3908,25 +4074,31 @@ scb { | |||
| 3908 | size 4 | 4074 | size 4 |
| 3909 | alias SCB_CDB_STORE | 4075 | alias SCB_CDB_STORE |
| 3910 | alias SCB_HOST_CDB_PTR | 4076 | alias SCB_HOST_CDB_PTR |
| 4077 | dont_generate_debug_code | ||
| 3911 | } | 4078 | } |
| 3912 | SCB_RESIDUAL_SGPTR { | 4079 | SCB_RESIDUAL_SGPTR { |
| 3913 | size 4 | 4080 | size 4 |
| 3914 | field SG_ADDR_MASK 0xf8 /* In the last byte */ | 4081 | field SG_ADDR_MASK 0xf8 /* In the last byte */ |
| 3915 | field SG_OVERRUN_RESID 0x02 /* In the first byte */ | 4082 | field SG_OVERRUN_RESID 0x02 /* In the first byte */ |
| 3916 | field SG_LIST_NULL 0x01 /* In the first byte */ | 4083 | field SG_LIST_NULL 0x01 /* In the first byte */ |
| 4084 | dont_generate_debug_code | ||
| 3917 | } | 4085 | } |
| 3918 | SCB_SCSI_STATUS { | 4086 | SCB_SCSI_STATUS { |
| 3919 | size 1 | 4087 | size 1 |
| 3920 | alias SCB_HOST_CDB_LEN | 4088 | alias SCB_HOST_CDB_LEN |
| 4089 | dont_generate_debug_code | ||
| 3921 | } | 4090 | } |
| 3922 | SCB_TARGET_PHASES { | 4091 | SCB_TARGET_PHASES { |
| 3923 | size 1 | 4092 | size 1 |
| 4093 | dont_generate_debug_code | ||
| 3924 | } | 4094 | } |
| 3925 | SCB_TARGET_DATA_DIR { | 4095 | SCB_TARGET_DATA_DIR { |
| 3926 | size 1 | 4096 | size 1 |
| 4097 | dont_generate_debug_code | ||
| 3927 | } | 4098 | } |
| 3928 | SCB_TARGET_ITAG { | 4099 | SCB_TARGET_ITAG { |
| 3929 | size 1 | 4100 | size 1 |
| 4101 | dont_generate_debug_code | ||
| 3930 | } | 4102 | } |
| 3931 | SCB_SENSE_BUSADDR { | 4103 | SCB_SENSE_BUSADDR { |
| 3932 | /* | 4104 | /* |
| @@ -3936,10 +4108,12 @@ scb { | |||
| 3936 | */ | 4108 | */ |
| 3937 | size 4 | 4109 | size 4 |
| 3938 | alias SCB_NEXT_COMPLETE | 4110 | alias SCB_NEXT_COMPLETE |
| 4111 | dont_generate_debug_code | ||
| 3939 | } | 4112 | } |
| 3940 | SCB_TAG { | 4113 | SCB_TAG { |
| 3941 | alias SCB_FIFO_USE_COUNT | 4114 | alias SCB_FIFO_USE_COUNT |
| 3942 | size 2 | 4115 | size 2 |
| 4116 | dont_generate_debug_code | ||
| 3943 | } | 4117 | } |
| 3944 | SCB_CONTROL { | 4118 | SCB_CONTROL { |
| 3945 | size 1 | 4119 | size 1 |
| @@ -3959,6 +4133,7 @@ scb { | |||
| 3959 | SCB_LUN { | 4133 | SCB_LUN { |
| 3960 | size 1 | 4134 | size 1 |
| 3961 | field LID 0xff | 4135 | field LID 0xff |
| 4136 | dont_generate_debug_code | ||
| 3962 | } | 4137 | } |
| 3963 | SCB_TASK_ATTRIBUTE { | 4138 | SCB_TASK_ATTRIBUTE { |
| 3964 | size 1 | 4139 | size 1 |
| @@ -3967,16 +4142,20 @@ scb { | |||
| 3967 | * ignore wide residue message handling. | 4142 | * ignore wide residue message handling. |
| 3968 | */ | 4143 | */ |
| 3969 | field SCB_XFERLEN_ODD 0x01 | 4144 | field SCB_XFERLEN_ODD 0x01 |
| 4145 | dont_generate_debug_code | ||
| 3970 | } | 4146 | } |
| 3971 | SCB_CDB_LEN { | 4147 | SCB_CDB_LEN { |
| 3972 | size 1 | 4148 | size 1 |
| 3973 | field SCB_CDB_LEN_PTR 0x80 /* CDB in host memory */ | 4149 | field SCB_CDB_LEN_PTR 0x80 /* CDB in host memory */ |
| 4150 | dont_generate_debug_code | ||
| 3974 | } | 4151 | } |
| 3975 | SCB_TASK_MANAGEMENT { | 4152 | SCB_TASK_MANAGEMENT { |
| 3976 | size 1 | 4153 | size 1 |
| 4154 | dont_generate_debug_code | ||
| 3977 | } | 4155 | } |
| 3978 | SCB_DATAPTR { | 4156 | SCB_DATAPTR { |
| 3979 | size 8 | 4157 | size 8 |
| 4158 | dont_generate_debug_code | ||
| 3980 | } | 4159 | } |
| 3981 | SCB_DATACNT { | 4160 | SCB_DATACNT { |
| 3982 | /* | 4161 | /* |
| @@ -3986,22 +4165,27 @@ scb { | |||
| 3986 | size 4 | 4165 | size 4 |
| 3987 | field SG_LAST_SEG 0x80 /* In the fourth byte */ | 4166 | field SG_LAST_SEG 0x80 /* In the fourth byte */ |
| 3988 | field SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ | 4167 | field SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ |
| 4168 | dont_generate_debug_code | ||
| 3989 | } | 4169 | } |
| 3990 | SCB_SGPTR { | 4170 | SCB_SGPTR { |
| 3991 | size 4 | 4171 | size 4 |
| 3992 | field SG_STATUS_VALID 0x04 /* In the first byte */ | 4172 | field SG_STATUS_VALID 0x04 /* In the first byte */ |
| 3993 | field SG_FULL_RESID 0x02 /* In the first byte */ | 4173 | field SG_FULL_RESID 0x02 /* In the first byte */ |
| 3994 | field SG_LIST_NULL 0x01 /* In the first byte */ | 4174 | field SG_LIST_NULL 0x01 /* In the first byte */ |
| 4175 | dont_generate_debug_code | ||
| 3995 | } | 4176 | } |
| 3996 | SCB_BUSADDR { | 4177 | SCB_BUSADDR { |
| 3997 | size 4 | 4178 | size 4 |
| 4179 | dont_generate_debug_code | ||
| 3998 | } | 4180 | } |
| 3999 | SCB_NEXT { | 4181 | SCB_NEXT { |
| 4000 | alias SCB_NEXT_SCB_BUSADDR | 4182 | alias SCB_NEXT_SCB_BUSADDR |
| 4001 | size 2 | 4183 | size 2 |
| 4184 | dont_generate_debug_code | ||
| 4002 | } | 4185 | } |
| 4003 | SCB_NEXT2 { | 4186 | SCB_NEXT2 { |
| 4004 | size 2 | 4187 | size 2 |
| 4188 | dont_generate_debug_code | ||
| 4005 | } | 4189 | } |
| 4006 | SCB_SPARE { | 4190 | SCB_SPARE { |
| 4007 | size 8 | 4191 | size 8 |
| @@ -4009,6 +4193,7 @@ scb { | |||
| 4009 | } | 4193 | } |
| 4010 | SCB_DISCONNECTED_LISTS { | 4194 | SCB_DISCONNECTED_LISTS { |
| 4011 | size 8 | 4195 | size 8 |
| 4196 | dont_generate_debug_code | ||
| 4012 | } | 4197 | } |
| 4013 | } | 4198 | } |
| 4014 | 4199 | ||
diff --git a/drivers/scsi/aic7xxx/aic79xx_core.c b/drivers/scsi/aic7xxx/aic79xx_core.c index 55508b0fcec4..bdad54ec088c 100644 --- a/drivers/scsi/aic7xxx/aic79xx_core.c +++ b/drivers/scsi/aic7xxx/aic79xx_core.c | |||
| @@ -2472,8 +2472,6 @@ ahd_handle_scsiint(struct ahd_softc *ahd, u_int intstat) | |||
| 2472 | if ((ahd->bugs & AHD_CLRLQO_AUTOCLR_BUG) != 0) | 2472 | if ((ahd->bugs & AHD_CLRLQO_AUTOCLR_BUG) != 0) |
| 2473 | ahd_outb(ahd, CLRLQOINT1, 0); | 2473 | ahd_outb(ahd, CLRLQOINT1, 0); |
| 2474 | } else if ((status & SELTO) != 0) { | 2474 | } else if ((status & SELTO) != 0) { |
| 2475 | u_int scbid; | ||
| 2476 | |||
| 2477 | /* Stop the selection */ | 2475 | /* Stop the selection */ |
| 2478 | ahd_outb(ahd, SCSISEQ0, 0); | 2476 | ahd_outb(ahd, SCSISEQ0, 0); |
| 2479 | 2477 | ||
| @@ -2583,9 +2581,6 @@ ahd_handle_scsiint(struct ahd_softc *ahd, u_int intstat) | |||
| 2583 | case BUSFREE_DFF0: | 2581 | case BUSFREE_DFF0: |
| 2584 | case BUSFREE_DFF1: | 2582 | case BUSFREE_DFF1: |
| 2585 | { | 2583 | { |
| 2586 | u_int scbid; | ||
| 2587 | struct scb *scb; | ||
| 2588 | |||
| 2589 | mode = busfreetime == BUSFREE_DFF0 | 2584 | mode = busfreetime == BUSFREE_DFF0 |
| 2590 | ? AHD_MODE_DFF0 : AHD_MODE_DFF1; | 2585 | ? AHD_MODE_DFF0 : AHD_MODE_DFF1; |
| 2591 | ahd_set_modes(ahd, mode, mode); | 2586 | ahd_set_modes(ahd, mode, mode); |
| @@ -3689,7 +3684,7 @@ ahd_free_tstate(struct ahd_softc *ahd, u_int scsi_id, char channel, int force) | |||
| 3689 | * by the capabilities of the bus connectivity of and sync settings for | 3684 | * by the capabilities of the bus connectivity of and sync settings for |
| 3690 | * the target. | 3685 | * the target. |
| 3691 | */ | 3686 | */ |
| 3692 | void | 3687 | static void |
| 3693 | ahd_devlimited_syncrate(struct ahd_softc *ahd, | 3688 | ahd_devlimited_syncrate(struct ahd_softc *ahd, |
| 3694 | struct ahd_initiator_tinfo *tinfo, | 3689 | struct ahd_initiator_tinfo *tinfo, |
| 3695 | u_int *period, u_int *ppr_options, role_t role) | 3690 | u_int *period, u_int *ppr_options, role_t role) |
| @@ -4136,7 +4131,7 @@ ahd_update_neg_table(struct ahd_softc *ahd, struct ahd_devinfo *devinfo, | |||
| 4136 | 4131 | ||
| 4137 | /* | 4132 | /* |
| 4138 | * Harpoon2A assumed that there would be a | 4133 | * Harpoon2A assumed that there would be a |
| 4139 | * fallback rate between 160MHz and 80Mhz, | 4134 | * fallback rate between 160MHz and 80MHz, |
| 4140 | * so 7 is used as the period factor rather | 4135 | * so 7 is used as the period factor rather |
| 4141 | * than 8 for 160MHz. | 4136 | * than 8 for 160MHz. |
| 4142 | */ | 4137 | */ |
| @@ -8708,7 +8703,7 @@ ahd_reset_current_bus(struct ahd_softc *ahd) | |||
| 8708 | int | 8703 | int |
| 8709 | ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | 8704 | ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) |
| 8710 | { | 8705 | { |
| 8711 | struct ahd_devinfo devinfo; | 8706 | struct ahd_devinfo caminfo; |
| 8712 | u_int initiator; | 8707 | u_int initiator; |
| 8713 | u_int target; | 8708 | u_int target; |
| 8714 | u_int max_scsiid; | 8709 | u_int max_scsiid; |
| @@ -8729,7 +8724,7 @@ ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | |||
| 8729 | 8724 | ||
| 8730 | ahd->pending_device = NULL; | 8725 | ahd->pending_device = NULL; |
| 8731 | 8726 | ||
| 8732 | ahd_compile_devinfo(&devinfo, | 8727 | ahd_compile_devinfo(&caminfo, |
| 8733 | CAM_TARGET_WILDCARD, | 8728 | CAM_TARGET_WILDCARD, |
| 8734 | CAM_TARGET_WILDCARD, | 8729 | CAM_TARGET_WILDCARD, |
| 8735 | CAM_LUN_WILDCARD, | 8730 | CAM_LUN_WILDCARD, |
| @@ -8868,7 +8863,7 @@ ahd_reset_channel(struct ahd_softc *ahd, char channel, int initiate_reset) | |||
| 8868 | } | 8863 | } |
| 8869 | 8864 | ||
| 8870 | /* Notify the XPT that a bus reset occurred */ | 8865 | /* Notify the XPT that a bus reset occurred */ |
| 8871 | ahd_send_async(ahd, devinfo.channel, CAM_TARGET_WILDCARD, | 8866 | ahd_send_async(ahd, caminfo.channel, CAM_TARGET_WILDCARD, |
| 8872 | CAM_LUN_WILDCARD, AC_BUS_RESET); | 8867 | CAM_LUN_WILDCARD, AC_BUS_RESET); |
| 8873 | 8868 | ||
| 8874 | ahd_restart(ahd); | 8869 | ahd_restart(ahd); |
diff --git a/drivers/scsi/aic7xxx/aic79xx_pci.c b/drivers/scsi/aic7xxx/aic79xx_pci.c index c25b6adffbf9..a734d77e880e 100644 --- a/drivers/scsi/aic7xxx/aic79xx_pci.c +++ b/drivers/scsi/aic7xxx/aic79xx_pci.c | |||
| @@ -223,10 +223,10 @@ static const char *pci_bus_modes[] = | |||
| 223 | "PCI bus mode unknown", | 223 | "PCI bus mode unknown", |
| 224 | "PCI bus mode unknown", | 224 | "PCI bus mode unknown", |
| 225 | "PCI bus mode unknown", | 225 | "PCI bus mode unknown", |
| 226 | "PCI-X 101-133Mhz", | 226 | "PCI-X 101-133MHz", |
| 227 | "PCI-X 67-100Mhz", | 227 | "PCI-X 67-100MHz", |
| 228 | "PCI-X 50-66Mhz", | 228 | "PCI-X 50-66MHz", |
| 229 | "PCI 33 or 66Mhz" | 229 | "PCI 33 or 66MHz" |
| 230 | }; | 230 | }; |
| 231 | 231 | ||
| 232 | #define TESTMODE 0x00000800ul | 232 | #define TESTMODE 0x00000800ul |
| @@ -337,8 +337,6 @@ ahd_pci_config(struct ahd_softc *ahd, const struct ahd_pci_identity *entry) | |||
| 337 | * 64bit bus (PCI64BIT set in devconfig). | 337 | * 64bit bus (PCI64BIT set in devconfig). |
| 338 | */ | 338 | */ |
| 339 | if ((ahd->flags & (AHD_39BIT_ADDRESSING|AHD_64BIT_ADDRESSING)) != 0) { | 339 | if ((ahd->flags & (AHD_39BIT_ADDRESSING|AHD_64BIT_ADDRESSING)) != 0) { |
| 340 | uint32_t devconfig; | ||
| 341 | |||
| 342 | if (bootverbose) | 340 | if (bootverbose) |
| 343 | printf("%s: Enabling 39Bit Addressing\n", | 341 | printf("%s: Enabling 39Bit Addressing\n", |
| 344 | ahd_name(ahd)); | 342 | ahd_name(ahd)); |
| @@ -483,8 +481,6 @@ ahd_pci_test_register_access(struct ahd_softc *ahd) | |||
| 483 | goto fail; | 481 | goto fail; |
| 484 | 482 | ||
| 485 | if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) { | 483 | if ((ahd_inb(ahd, INTSTAT) & PCIINT) != 0) { |
| 486 | u_int targpcistat; | ||
| 487 | |||
| 488 | ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG); | 484 | ahd_set_modes(ahd, AHD_MODE_CFG, AHD_MODE_CFG); |
| 489 | targpcistat = ahd_inb(ahd, TARGPCISTAT); | 485 | targpcistat = ahd_inb(ahd, TARGPCISTAT); |
| 490 | if ((targpcistat & STA) != 0) | 486 | if ((targpcistat & STA) != 0) |
diff --git a/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped b/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped index c21ceab8e913..cdcead071ef6 100644 --- a/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped +++ b/drivers/scsi/aic7xxx/aic79xx_reg.h_shipped | |||
| @@ -34,13 +34,6 @@ ahd_reg_print_t ahd_seqintcode_print; | |||
| 34 | #endif | 34 | #endif |
| 35 | 35 | ||
| 36 | #if AIC_DEBUG_REGISTERS | 36 | #if AIC_DEBUG_REGISTERS |
| 37 | ahd_reg_print_t ahd_clrint_print; | ||
| 38 | #else | ||
| 39 | #define ahd_clrint_print(regvalue, cur_col, wrap) \ | ||
| 40 | ahd_print_register(NULL, 0, "CLRINT", 0x03, regvalue, cur_col, wrap) | ||
| 41 | #endif | ||
| 42 | |||
| 43 | #if AIC_DEBUG_REGISTERS | ||
| 44 | ahd_reg_print_t ahd_error_print; | 37 | ahd_reg_print_t ahd_error_print; |
| 45 | #else | 38 | #else |
| 46 | #define ahd_error_print(regvalue, cur_col, wrap) \ | 39 | #define ahd_error_print(regvalue, cur_col, wrap) \ |
| @@ -48,20 +41,6 @@ ahd_reg_print_t ahd_error_print; | |||
| 48 | #endif | 41 | #endif |
| 49 | 42 | ||
| 50 | #if AIC_DEBUG_REGISTERS | 43 | #if AIC_DEBUG_REGISTERS |
| 51 | ahd_reg_print_t ahd_hcntrl_print; | ||
| 52 | #else | ||
| 53 | #define ahd_hcntrl_print(regvalue, cur_col, wrap) \ | ||
| 54 | ahd_print_register(NULL, 0, "HCNTRL", 0x05, regvalue, cur_col, wrap) | ||
| 55 | #endif | ||
| 56 | |||
| 57 | #if AIC_DEBUG_REGISTERS | ||
| 58 | ahd_reg_print_t ahd_hnscb_qoff_print; | ||
| 59 | #else | ||
| 60 | #define ahd_hnscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 61 | ahd_print_register(NULL, 0, "HNSCB_QOFF", 0x06, regvalue, cur_col, wrap) | ||
| 62 | #endif | ||
| 63 | |||
| 64 | #if AIC_DEBUG_REGISTERS | ||
| 65 | ahd_reg_print_t ahd_hescb_qoff_print; | 44 | ahd_reg_print_t ahd_hescb_qoff_print; |
| 66 | #else | 45 | #else |
| 67 | #define ahd_hescb_qoff_print(regvalue, cur_col, wrap) \ | 46 | #define ahd_hescb_qoff_print(regvalue, cur_col, wrap) \ |
| @@ -97,13 +76,6 @@ ahd_reg_print_t ahd_swtimer_print; | |||
| 97 | #endif | 76 | #endif |
| 98 | 77 | ||
| 99 | #if AIC_DEBUG_REGISTERS | 78 | #if AIC_DEBUG_REGISTERS |
| 100 | ahd_reg_print_t ahd_snscb_qoff_print; | ||
| 101 | #else | ||
| 102 | #define ahd_snscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 103 | ahd_print_register(NULL, 0, "SNSCB_QOFF", 0x10, regvalue, cur_col, wrap) | ||
| 104 | #endif | ||
| 105 | |||
| 106 | #if AIC_DEBUG_REGISTERS | ||
| 107 | ahd_reg_print_t ahd_sescb_qoff_print; | 79 | ahd_reg_print_t ahd_sescb_qoff_print; |
| 108 | #else | 80 | #else |
| 109 | #define ahd_sescb_qoff_print(regvalue, cur_col, wrap) \ | 81 | #define ahd_sescb_qoff_print(regvalue, cur_col, wrap) \ |
| @@ -111,20 +83,6 @@ ahd_reg_print_t ahd_sescb_qoff_print; | |||
| 111 | #endif | 83 | #endif |
| 112 | 84 | ||
| 113 | #if AIC_DEBUG_REGISTERS | 85 | #if AIC_DEBUG_REGISTERS |
| 114 | ahd_reg_print_t ahd_sdscb_qoff_print; | ||
| 115 | #else | ||
| 116 | #define ahd_sdscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 117 | ahd_print_register(NULL, 0, "SDSCB_QOFF", 0x14, regvalue, cur_col, wrap) | ||
| 118 | #endif | ||
| 119 | |||
| 120 | #if AIC_DEBUG_REGISTERS | ||
| 121 | ahd_reg_print_t ahd_qoff_ctlsta_print; | ||
| 122 | #else | ||
| 123 | #define ahd_qoff_ctlsta_print(regvalue, cur_col, wrap) \ | ||
| 124 | ahd_print_register(NULL, 0, "QOFF_CTLSTA", 0x16, regvalue, cur_col, wrap) | ||
| 125 | #endif | ||
| 126 | |||
| 127 | #if AIC_DEBUG_REGISTERS | ||
| 128 | ahd_reg_print_t ahd_intctl_print; | 86 | ahd_reg_print_t ahd_intctl_print; |
| 129 | #else | 87 | #else |
| 130 | #define ahd_intctl_print(regvalue, cur_col, wrap) \ | 88 | #define ahd_intctl_print(regvalue, cur_col, wrap) \ |
| @@ -139,13 +97,6 @@ ahd_reg_print_t ahd_dfcntrl_print; | |||
| 139 | #endif | 97 | #endif |
| 140 | 98 | ||
| 141 | #if AIC_DEBUG_REGISTERS | 99 | #if AIC_DEBUG_REGISTERS |
| 142 | ahd_reg_print_t ahd_dscommand0_print; | ||
| 143 | #else | ||
| 144 | #define ahd_dscommand0_print(regvalue, cur_col, wrap) \ | ||
| 145 | ahd_print_register(NULL, 0, "DSCOMMAND0", 0x19, regvalue, cur_col, wrap) | ||
| 146 | #endif | ||
| 147 | |||
| 148 | #if AIC_DEBUG_REGISTERS | ||
| 149 | ahd_reg_print_t ahd_dfstatus_print; | 100 | ahd_reg_print_t ahd_dfstatus_print; |
| 150 | #else | 101 | #else |
| 151 | #define ahd_dfstatus_print(regvalue, cur_col, wrap) \ | 102 | #define ahd_dfstatus_print(regvalue, cur_col, wrap) \ |
| @@ -160,13 +111,6 @@ ahd_reg_print_t ahd_sg_cache_shadow_print; | |||
| 160 | #endif | 111 | #endif |
| 161 | 112 | ||
| 162 | #if AIC_DEBUG_REGISTERS | 113 | #if AIC_DEBUG_REGISTERS |
| 163 | ahd_reg_print_t ahd_sg_cache_pre_print; | ||
| 164 | #else | ||
| 165 | #define ahd_sg_cache_pre_print(regvalue, cur_col, wrap) \ | ||
| 166 | ahd_print_register(NULL, 0, "SG_CACHE_PRE", 0x1b, regvalue, cur_col, wrap) | ||
| 167 | #endif | ||
| 168 | |||
| 169 | #if AIC_DEBUG_REGISTERS | ||
| 170 | ahd_reg_print_t ahd_lqin_print; | 114 | ahd_reg_print_t ahd_lqin_print; |
| 171 | #else | 115 | #else |
| 172 | #define ahd_lqin_print(regvalue, cur_col, wrap) \ | 116 | #define ahd_lqin_print(regvalue, cur_col, wrap) \ |
| @@ -293,13 +237,6 @@ ahd_reg_print_t ahd_sxfrctl0_print; | |||
| 293 | #endif | 237 | #endif |
| 294 | 238 | ||
| 295 | #if AIC_DEBUG_REGISTERS | 239 | #if AIC_DEBUG_REGISTERS |
| 296 | ahd_reg_print_t ahd_sxfrctl1_print; | ||
| 297 | #else | ||
| 298 | #define ahd_sxfrctl1_print(regvalue, cur_col, wrap) \ | ||
| 299 | ahd_print_register(NULL, 0, "SXFRCTL1", 0x3d, regvalue, cur_col, wrap) | ||
| 300 | #endif | ||
| 301 | |||
| 302 | #if AIC_DEBUG_REGISTERS | ||
| 303 | ahd_reg_print_t ahd_dffstat_print; | 240 | ahd_reg_print_t ahd_dffstat_print; |
| 304 | #else | 241 | #else |
| 305 | #define ahd_dffstat_print(regvalue, cur_col, wrap) \ | 242 | #define ahd_dffstat_print(regvalue, cur_col, wrap) \ |
| @@ -314,13 +251,6 @@ ahd_reg_print_t ahd_multargid_print; | |||
| 314 | #endif | 251 | #endif |
| 315 | 252 | ||
| 316 | #if AIC_DEBUG_REGISTERS | 253 | #if AIC_DEBUG_REGISTERS |
| 317 | ahd_reg_print_t ahd_scsisigo_print; | ||
| 318 | #else | ||
| 319 | #define ahd_scsisigo_print(regvalue, cur_col, wrap) \ | ||
| 320 | ahd_print_register(NULL, 0, "SCSISIGO", 0x40, regvalue, cur_col, wrap) | ||
| 321 | #endif | ||
| 322 | |||
| 323 | #if AIC_DEBUG_REGISTERS | ||
| 324 | ahd_reg_print_t ahd_scsisigi_print; | 254 | ahd_reg_print_t ahd_scsisigi_print; |
| 325 | #else | 255 | #else |
| 326 | #define ahd_scsisigi_print(regvalue, cur_col, wrap) \ | 256 | #define ahd_scsisigi_print(regvalue, cur_col, wrap) \ |
| @@ -363,13 +293,6 @@ ahd_reg_print_t ahd_selid_print; | |||
| 363 | #endif | 293 | #endif |
| 364 | 294 | ||
| 365 | #if AIC_DEBUG_REGISTERS | 295 | #if AIC_DEBUG_REGISTERS |
| 366 | ahd_reg_print_t ahd_optionmode_print; | ||
| 367 | #else | ||
| 368 | #define ahd_optionmode_print(regvalue, cur_col, wrap) \ | ||
| 369 | ahd_print_register(NULL, 0, "OPTIONMODE", 0x4a, regvalue, cur_col, wrap) | ||
| 370 | #endif | ||
| 371 | |||
| 372 | #if AIC_DEBUG_REGISTERS | ||
| 373 | ahd_reg_print_t ahd_sblkctl_print; | 296 | ahd_reg_print_t ahd_sblkctl_print; |
| 374 | #else | 297 | #else |
| 375 | #define ahd_sblkctl_print(regvalue, cur_col, wrap) \ | 298 | #define ahd_sblkctl_print(regvalue, cur_col, wrap) \ |
| @@ -391,13 +314,6 @@ ahd_reg_print_t ahd_simode0_print; | |||
| 391 | #endif | 314 | #endif |
| 392 | 315 | ||
| 393 | #if AIC_DEBUG_REGISTERS | 316 | #if AIC_DEBUG_REGISTERS |
| 394 | ahd_reg_print_t ahd_clrsint0_print; | ||
| 395 | #else | ||
| 396 | #define ahd_clrsint0_print(regvalue, cur_col, wrap) \ | ||
| 397 | ahd_print_register(NULL, 0, "CLRSINT0", 0x4b, regvalue, cur_col, wrap) | ||
| 398 | #endif | ||
| 399 | |||
| 400 | #if AIC_DEBUG_REGISTERS | ||
| 401 | ahd_reg_print_t ahd_sstat1_print; | 317 | ahd_reg_print_t ahd_sstat1_print; |
| 402 | #else | 318 | #else |
| 403 | #define ahd_sstat1_print(regvalue, cur_col, wrap) \ | 319 | #define ahd_sstat1_print(regvalue, cur_col, wrap) \ |
| @@ -405,13 +321,6 @@ ahd_reg_print_t ahd_sstat1_print; | |||
| 405 | #endif | 321 | #endif |
| 406 | 322 | ||
| 407 | #if AIC_DEBUG_REGISTERS | 323 | #if AIC_DEBUG_REGISTERS |
| 408 | ahd_reg_print_t ahd_clrsint1_print; | ||
| 409 | #else | ||
| 410 | #define ahd_clrsint1_print(regvalue, cur_col, wrap) \ | ||
| 411 | ahd_print_register(NULL, 0, "CLRSINT1", 0x4c, regvalue, cur_col, wrap) | ||
| 412 | #endif | ||
| 413 | |||
| 414 | #if AIC_DEBUG_REGISTERS | ||
| 415 | ahd_reg_print_t ahd_sstat2_print; | 324 | ahd_reg_print_t ahd_sstat2_print; |
| 416 | #else | 325 | #else |
| 417 | #define ahd_sstat2_print(regvalue, cur_col, wrap) \ | 326 | #define ahd_sstat2_print(regvalue, cur_col, wrap) \ |
| @@ -461,17 +370,17 @@ ahd_reg_print_t ahd_lqistat0_print; | |||
| 461 | #endif | 370 | #endif |
| 462 | 371 | ||
| 463 | #if AIC_DEBUG_REGISTERS | 372 | #if AIC_DEBUG_REGISTERS |
| 464 | ahd_reg_print_t ahd_lqimode0_print; | 373 | ahd_reg_print_t ahd_clrlqiint0_print; |
| 465 | #else | 374 | #else |
| 466 | #define ahd_lqimode0_print(regvalue, cur_col, wrap) \ | 375 | #define ahd_clrlqiint0_print(regvalue, cur_col, wrap) \ |
| 467 | ahd_print_register(NULL, 0, "LQIMODE0", 0x50, regvalue, cur_col, wrap) | 376 | ahd_print_register(NULL, 0, "CLRLQIINT0", 0x50, regvalue, cur_col, wrap) |
| 468 | #endif | 377 | #endif |
| 469 | 378 | ||
| 470 | #if AIC_DEBUG_REGISTERS | 379 | #if AIC_DEBUG_REGISTERS |
| 471 | ahd_reg_print_t ahd_clrlqiint0_print; | 380 | ahd_reg_print_t ahd_lqimode0_print; |
| 472 | #else | 381 | #else |
| 473 | #define ahd_clrlqiint0_print(regvalue, cur_col, wrap) \ | 382 | #define ahd_lqimode0_print(regvalue, cur_col, wrap) \ |
| 474 | ahd_print_register(NULL, 0, "CLRLQIINT0", 0x50, regvalue, cur_col, wrap) | 383 | ahd_print_register(NULL, 0, "LQIMODE0", 0x50, regvalue, cur_col, wrap) |
| 475 | #endif | 384 | #endif |
| 476 | 385 | ||
| 477 | #if AIC_DEBUG_REGISTERS | 386 | #if AIC_DEBUG_REGISTERS |
| @@ -629,17 +538,17 @@ ahd_reg_print_t ahd_seqintsrc_print; | |||
| 629 | #endif | 538 | #endif |
| 630 | 539 | ||
| 631 | #if AIC_DEBUG_REGISTERS | 540 | #if AIC_DEBUG_REGISTERS |
| 632 | ahd_reg_print_t ahd_seqimode_print; | 541 | ahd_reg_print_t ahd_currscb_print; |
| 633 | #else | 542 | #else |
| 634 | #define ahd_seqimode_print(regvalue, cur_col, wrap) \ | 543 | #define ahd_currscb_print(regvalue, cur_col, wrap) \ |
| 635 | ahd_print_register(NULL, 0, "SEQIMODE", 0x5c, regvalue, cur_col, wrap) | 544 | ahd_print_register(NULL, 0, "CURRSCB", 0x5c, regvalue, cur_col, wrap) |
| 636 | #endif | 545 | #endif |
| 637 | 546 | ||
| 638 | #if AIC_DEBUG_REGISTERS | 547 | #if AIC_DEBUG_REGISTERS |
| 639 | ahd_reg_print_t ahd_currscb_print; | 548 | ahd_reg_print_t ahd_seqimode_print; |
| 640 | #else | 549 | #else |
| 641 | #define ahd_currscb_print(regvalue, cur_col, wrap) \ | 550 | #define ahd_seqimode_print(regvalue, cur_col, wrap) \ |
| 642 | ahd_print_register(NULL, 0, "CURRSCB", 0x5c, regvalue, cur_col, wrap) | 551 | ahd_print_register(NULL, 0, "SEQIMODE", 0x5c, regvalue, cur_col, wrap) |
| 643 | #endif | 552 | #endif |
| 644 | 553 | ||
| 645 | #if AIC_DEBUG_REGISTERS | 554 | #if AIC_DEBUG_REGISTERS |
| @@ -657,13 +566,6 @@ ahd_reg_print_t ahd_lastscb_print; | |||
| 657 | #endif | 566 | #endif |
| 658 | 567 | ||
| 659 | #if AIC_DEBUG_REGISTERS | 568 | #if AIC_DEBUG_REGISTERS |
| 660 | ahd_reg_print_t ahd_shaddr_print; | ||
| 661 | #else | ||
| 662 | #define ahd_shaddr_print(regvalue, cur_col, wrap) \ | ||
| 663 | ahd_print_register(NULL, 0, "SHADDR", 0x60, regvalue, cur_col, wrap) | ||
| 664 | #endif | ||
| 665 | |||
| 666 | #if AIC_DEBUG_REGISTERS | ||
| 667 | ahd_reg_print_t ahd_negoaddr_print; | 569 | ahd_reg_print_t ahd_negoaddr_print; |
| 668 | #else | 570 | #else |
| 669 | #define ahd_negoaddr_print(regvalue, cur_col, wrap) \ | 571 | #define ahd_negoaddr_print(regvalue, cur_col, wrap) \ |
| @@ -748,27 +650,6 @@ ahd_reg_print_t ahd_seloid_print; | |||
| 748 | #endif | 650 | #endif |
| 749 | 651 | ||
| 750 | #if AIC_DEBUG_REGISTERS | 652 | #if AIC_DEBUG_REGISTERS |
| 751 | ahd_reg_print_t ahd_haddr_print; | ||
| 752 | #else | ||
| 753 | #define ahd_haddr_print(regvalue, cur_col, wrap) \ | ||
| 754 | ahd_print_register(NULL, 0, "HADDR", 0x70, regvalue, cur_col, wrap) | ||
| 755 | #endif | ||
| 756 | |||
| 757 | #if AIC_DEBUG_REGISTERS | ||
| 758 | ahd_reg_print_t ahd_hcnt_print; | ||
| 759 | #else | ||
| 760 | #define ahd_hcnt_print(regvalue, cur_col, wrap) \ | ||
| 761 | ahd_print_register(NULL, 0, "HCNT", 0x78, regvalue, cur_col, wrap) | ||
| 762 | #endif | ||
| 763 | |||
| 764 | #if AIC_DEBUG_REGISTERS | ||
| 765 | ahd_reg_print_t ahd_sghaddr_print; | ||
| 766 | #else | ||
| 767 | #define ahd_sghaddr_print(regvalue, cur_col, wrap) \ | ||
| 768 | ahd_print_register(NULL, 0, "SGHADDR", 0x7c, regvalue, cur_col, wrap) | ||
| 769 | #endif | ||
| 770 | |||
| 771 | #if AIC_DEBUG_REGISTERS | ||
| 772 | ahd_reg_print_t ahd_scbhaddr_print; | 653 | ahd_reg_print_t ahd_scbhaddr_print; |
| 773 | #else | 654 | #else |
| 774 | #define ahd_scbhaddr_print(regvalue, cur_col, wrap) \ | 655 | #define ahd_scbhaddr_print(regvalue, cur_col, wrap) \ |
| @@ -776,10 +657,10 @@ ahd_reg_print_t ahd_scbhaddr_print; | |||
| 776 | #endif | 657 | #endif |
| 777 | 658 | ||
| 778 | #if AIC_DEBUG_REGISTERS | 659 | #if AIC_DEBUG_REGISTERS |
| 779 | ahd_reg_print_t ahd_sghcnt_print; | 660 | ahd_reg_print_t ahd_sghaddr_print; |
| 780 | #else | 661 | #else |
| 781 | #define ahd_sghcnt_print(regvalue, cur_col, wrap) \ | 662 | #define ahd_sghaddr_print(regvalue, cur_col, wrap) \ |
| 782 | ahd_print_register(NULL, 0, "SGHCNT", 0x84, regvalue, cur_col, wrap) | 663 | ahd_print_register(NULL, 0, "SGHADDR", 0x7c, regvalue, cur_col, wrap) |
| 783 | #endif | 664 | #endif |
| 784 | 665 | ||
| 785 | #if AIC_DEBUG_REGISTERS | 666 | #if AIC_DEBUG_REGISTERS |
| @@ -790,10 +671,10 @@ ahd_reg_print_t ahd_scbhcnt_print; | |||
| 790 | #endif | 671 | #endif |
| 791 | 672 | ||
| 792 | #if AIC_DEBUG_REGISTERS | 673 | #if AIC_DEBUG_REGISTERS |
| 793 | ahd_reg_print_t ahd_dff_thrsh_print; | 674 | ahd_reg_print_t ahd_sghcnt_print; |
| 794 | #else | 675 | #else |
| 795 | #define ahd_dff_thrsh_print(regvalue, cur_col, wrap) \ | 676 | #define ahd_sghcnt_print(regvalue, cur_col, wrap) \ |
| 796 | ahd_print_register(NULL, 0, "DFF_THRSH", 0x88, regvalue, cur_col, wrap) | 677 | ahd_print_register(NULL, 0, "SGHCNT", 0x84, regvalue, cur_col, wrap) |
| 797 | #endif | 678 | #endif |
| 798 | 679 | ||
| 799 | #if AIC_DEBUG_REGISTERS | 680 | #if AIC_DEBUG_REGISTERS |
| @@ -867,13 +748,6 @@ ahd_reg_print_t ahd_targpcistat_print; | |||
| 867 | #endif | 748 | #endif |
| 868 | 749 | ||
| 869 | #if AIC_DEBUG_REGISTERS | 750 | #if AIC_DEBUG_REGISTERS |
| 870 | ahd_reg_print_t ahd_scbptr_print; | ||
| 871 | #else | ||
| 872 | #define ahd_scbptr_print(regvalue, cur_col, wrap) \ | ||
| 873 | ahd_print_register(NULL, 0, "SCBPTR", 0xa8, regvalue, cur_col, wrap) | ||
| 874 | #endif | ||
| 875 | |||
| 876 | #if AIC_DEBUG_REGISTERS | ||
| 877 | ahd_reg_print_t ahd_scbautoptr_print; | 751 | ahd_reg_print_t ahd_scbautoptr_print; |
| 878 | #else | 752 | #else |
| 879 | #define ahd_scbautoptr_print(regvalue, cur_col, wrap) \ | 753 | #define ahd_scbautoptr_print(regvalue, cur_col, wrap) \ |
| @@ -881,13 +755,6 @@ ahd_reg_print_t ahd_scbautoptr_print; | |||
| 881 | #endif | 755 | #endif |
| 882 | 756 | ||
| 883 | #if AIC_DEBUG_REGISTERS | 757 | #if AIC_DEBUG_REGISTERS |
| 884 | ahd_reg_print_t ahd_ccsgaddr_print; | ||
| 885 | #else | ||
| 886 | #define ahd_ccsgaddr_print(regvalue, cur_col, wrap) \ | ||
| 887 | ahd_print_register(NULL, 0, "CCSGADDR", 0xac, regvalue, cur_col, wrap) | ||
| 888 | #endif | ||
| 889 | |||
| 890 | #if AIC_DEBUG_REGISTERS | ||
| 891 | ahd_reg_print_t ahd_ccscbaddr_print; | 758 | ahd_reg_print_t ahd_ccscbaddr_print; |
| 892 | #else | 759 | #else |
| 893 | #define ahd_ccscbaddr_print(regvalue, cur_col, wrap) \ | 760 | #define ahd_ccscbaddr_print(regvalue, cur_col, wrap) \ |
| @@ -909,13 +776,6 @@ ahd_reg_print_t ahd_ccsgctl_print; | |||
| 909 | #endif | 776 | #endif |
| 910 | 777 | ||
| 911 | #if AIC_DEBUG_REGISTERS | 778 | #if AIC_DEBUG_REGISTERS |
| 912 | ahd_reg_print_t ahd_ccsgram_print; | ||
| 913 | #else | ||
| 914 | #define ahd_ccsgram_print(regvalue, cur_col, wrap) \ | ||
| 915 | ahd_print_register(NULL, 0, "CCSGRAM", 0xb0, regvalue, cur_col, wrap) | ||
| 916 | #endif | ||
| 917 | |||
| 918 | #if AIC_DEBUG_REGISTERS | ||
| 919 | ahd_reg_print_t ahd_ccscbram_print; | 779 | ahd_reg_print_t ahd_ccscbram_print; |
| 920 | #else | 780 | #else |
| 921 | #define ahd_ccscbram_print(regvalue, cur_col, wrap) \ | 781 | #define ahd_ccscbram_print(regvalue, cur_col, wrap) \ |
| @@ -930,13 +790,6 @@ ahd_reg_print_t ahd_brddat_print; | |||
| 930 | #endif | 790 | #endif |
| 931 | 791 | ||
| 932 | #if AIC_DEBUG_REGISTERS | 792 | #if AIC_DEBUG_REGISTERS |
| 933 | ahd_reg_print_t ahd_brdctl_print; | ||
| 934 | #else | ||
| 935 | #define ahd_brdctl_print(regvalue, cur_col, wrap) \ | ||
| 936 | ahd_print_register(NULL, 0, "BRDCTL", 0xb9, regvalue, cur_col, wrap) | ||
| 937 | #endif | ||
| 938 | |||
| 939 | #if AIC_DEBUG_REGISTERS | ||
| 940 | ahd_reg_print_t ahd_seeadr_print; | 793 | ahd_reg_print_t ahd_seeadr_print; |
| 941 | #else | 794 | #else |
| 942 | #define ahd_seeadr_print(regvalue, cur_col, wrap) \ | 795 | #define ahd_seeadr_print(regvalue, cur_col, wrap) \ |
| @@ -972,13 +825,6 @@ ahd_reg_print_t ahd_dspdatactl_print; | |||
| 972 | #endif | 825 | #endif |
| 973 | 826 | ||
| 974 | #if AIC_DEBUG_REGISTERS | 827 | #if AIC_DEBUG_REGISTERS |
| 975 | ahd_reg_print_t ahd_dfdat_print; | ||
| 976 | #else | ||
| 977 | #define ahd_dfdat_print(regvalue, cur_col, wrap) \ | ||
| 978 | ahd_print_register(NULL, 0, "DFDAT", 0xc4, regvalue, cur_col, wrap) | ||
| 979 | #endif | ||
| 980 | |||
| 981 | #if AIC_DEBUG_REGISTERS | ||
| 982 | ahd_reg_print_t ahd_dspselect_print; | 828 | ahd_reg_print_t ahd_dspselect_print; |
| 983 | #else | 829 | #else |
| 984 | #define ahd_dspselect_print(regvalue, cur_col, wrap) \ | 830 | #define ahd_dspselect_print(regvalue, cur_col, wrap) \ |
| @@ -1000,13 +846,6 @@ ahd_reg_print_t ahd_seqctl0_print; | |||
| 1000 | #endif | 846 | #endif |
| 1001 | 847 | ||
| 1002 | #if AIC_DEBUG_REGISTERS | 848 | #if AIC_DEBUG_REGISTERS |
| 1003 | ahd_reg_print_t ahd_flags_print; | ||
| 1004 | #else | ||
| 1005 | #define ahd_flags_print(regvalue, cur_col, wrap) \ | ||
| 1006 | ahd_print_register(NULL, 0, "FLAGS", 0xd8, regvalue, cur_col, wrap) | ||
| 1007 | #endif | ||
| 1008 | |||
| 1009 | #if AIC_DEBUG_REGISTERS | ||
| 1010 | ahd_reg_print_t ahd_seqintctl_print; | 849 | ahd_reg_print_t ahd_seqintctl_print; |
| 1011 | #else | 850 | #else |
| 1012 | #define ahd_seqintctl_print(regvalue, cur_col, wrap) \ | 851 | #define ahd_seqintctl_print(regvalue, cur_col, wrap) \ |
| @@ -1014,13 +853,6 @@ ahd_reg_print_t ahd_seqintctl_print; | |||
| 1014 | #endif | 853 | #endif |
| 1015 | 854 | ||
| 1016 | #if AIC_DEBUG_REGISTERS | 855 | #if AIC_DEBUG_REGISTERS |
| 1017 | ahd_reg_print_t ahd_seqram_print; | ||
| 1018 | #else | ||
| 1019 | #define ahd_seqram_print(regvalue, cur_col, wrap) \ | ||
| 1020 | ahd_print_register(NULL, 0, "SEQRAM", 0xda, regvalue, cur_col, wrap) | ||
| 1021 | #endif | ||
| 1022 | |||
| 1023 | #if AIC_DEBUG_REGISTERS | ||
| 1024 | ahd_reg_print_t ahd_prgmcnt_print; | 856 | ahd_reg_print_t ahd_prgmcnt_print; |
| 1025 | #else | 857 | #else |
| 1026 | #define ahd_prgmcnt_print(regvalue, cur_col, wrap) \ | 858 | #define ahd_prgmcnt_print(regvalue, cur_col, wrap) \ |
| @@ -1028,41 +860,6 @@ ahd_reg_print_t ahd_prgmcnt_print; | |||
| 1028 | #endif | 860 | #endif |
| 1029 | 861 | ||
| 1030 | #if AIC_DEBUG_REGISTERS | 862 | #if AIC_DEBUG_REGISTERS |
| 1031 | ahd_reg_print_t ahd_accum_print; | ||
| 1032 | #else | ||
| 1033 | #define ahd_accum_print(regvalue, cur_col, wrap) \ | ||
| 1034 | ahd_print_register(NULL, 0, "ACCUM", 0xe0, regvalue, cur_col, wrap) | ||
| 1035 | #endif | ||
| 1036 | |||
| 1037 | #if AIC_DEBUG_REGISTERS | ||
| 1038 | ahd_reg_print_t ahd_sindex_print; | ||
| 1039 | #else | ||
| 1040 | #define ahd_sindex_print(regvalue, cur_col, wrap) \ | ||
| 1041 | ahd_print_register(NULL, 0, "SINDEX", 0xe2, regvalue, cur_col, wrap) | ||
| 1042 | #endif | ||
| 1043 | |||
| 1044 | #if AIC_DEBUG_REGISTERS | ||
| 1045 | ahd_reg_print_t ahd_dindex_print; | ||
| 1046 | #else | ||
| 1047 | #define ahd_dindex_print(regvalue, cur_col, wrap) \ | ||
| 1048 | ahd_print_register(NULL, 0, "DINDEX", 0xe4, regvalue, cur_col, wrap) | ||
| 1049 | #endif | ||
| 1050 | |||
| 1051 | #if AIC_DEBUG_REGISTERS | ||
| 1052 | ahd_reg_print_t ahd_allones_print; | ||
| 1053 | #else | ||
| 1054 | #define ahd_allones_print(regvalue, cur_col, wrap) \ | ||
| 1055 | ahd_print_register(NULL, 0, "ALLONES", 0xe8, regvalue, cur_col, wrap) | ||
| 1056 | #endif | ||
| 1057 | |||
| 1058 | #if AIC_DEBUG_REGISTERS | ||
| 1059 | ahd_reg_print_t ahd_allzeros_print; | ||
| 1060 | #else | ||
| 1061 | #define ahd_allzeros_print(regvalue, cur_col, wrap) \ | ||
| 1062 | ahd_print_register(NULL, 0, "ALLZEROS", 0xea, regvalue, cur_col, wrap) | ||
| 1063 | #endif | ||
| 1064 | |||
| 1065 | #if AIC_DEBUG_REGISTERS | ||
| 1066 | ahd_reg_print_t ahd_none_print; | 863 | ahd_reg_print_t ahd_none_print; |
| 1067 | #else | 864 | #else |
| 1068 | #define ahd_none_print(regvalue, cur_col, wrap) \ | 865 | #define ahd_none_print(regvalue, cur_col, wrap) \ |
| @@ -1070,27 +867,6 @@ ahd_reg_print_t ahd_none_print; | |||
| 1070 | #endif | 867 | #endif |
| 1071 | 868 | ||
| 1072 | #if AIC_DEBUG_REGISTERS | 869 | #if AIC_DEBUG_REGISTERS |
| 1073 | ahd_reg_print_t ahd_sindir_print; | ||
| 1074 | #else | ||
| 1075 | #define ahd_sindir_print(regvalue, cur_col, wrap) \ | ||
| 1076 | ahd_print_register(NULL, 0, "SINDIR", 0xec, regvalue, cur_col, wrap) | ||
| 1077 | #endif | ||
| 1078 | |||
| 1079 | #if AIC_DEBUG_REGISTERS | ||
| 1080 | ahd_reg_print_t ahd_dindir_print; | ||
| 1081 | #else | ||
| 1082 | #define ahd_dindir_print(regvalue, cur_col, wrap) \ | ||
| 1083 | ahd_print_register(NULL, 0, "DINDIR", 0xed, regvalue, cur_col, wrap) | ||
| 1084 | #endif | ||
| 1085 | |||
| 1086 | #if AIC_DEBUG_REGISTERS | ||
| 1087 | ahd_reg_print_t ahd_stack_print; | ||
| 1088 | #else | ||
| 1089 | #define ahd_stack_print(regvalue, cur_col, wrap) \ | ||
| 1090 | ahd_print_register(NULL, 0, "STACK", 0xf2, regvalue, cur_col, wrap) | ||
| 1091 | #endif | ||
| 1092 | |||
| 1093 | #if AIC_DEBUG_REGISTERS | ||
| 1094 | ahd_reg_print_t ahd_intvec1_addr_print; | 870 | ahd_reg_print_t ahd_intvec1_addr_print; |
| 1095 | #else | 871 | #else |
| 1096 | #define ahd_intvec1_addr_print(regvalue, cur_col, wrap) \ | 872 | #define ahd_intvec1_addr_print(regvalue, cur_col, wrap) \ |
| @@ -1126,17 +902,17 @@ ahd_reg_print_t ahd_accum_save_print; | |||
| 1126 | #endif | 902 | #endif |
| 1127 | 903 | ||
| 1128 | #if AIC_DEBUG_REGISTERS | 904 | #if AIC_DEBUG_REGISTERS |
| 1129 | ahd_reg_print_t ahd_sram_base_print; | 905 | ahd_reg_print_t ahd_waiting_scb_tails_print; |
| 1130 | #else | 906 | #else |
| 1131 | #define ahd_sram_base_print(regvalue, cur_col, wrap) \ | 907 | #define ahd_waiting_scb_tails_print(regvalue, cur_col, wrap) \ |
| 1132 | ahd_print_register(NULL, 0, "SRAM_BASE", 0x100, regvalue, cur_col, wrap) | 908 | ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", 0x100, regvalue, cur_col, wrap) |
| 1133 | #endif | 909 | #endif |
| 1134 | 910 | ||
| 1135 | #if AIC_DEBUG_REGISTERS | 911 | #if AIC_DEBUG_REGISTERS |
| 1136 | ahd_reg_print_t ahd_waiting_scb_tails_print; | 912 | ahd_reg_print_t ahd_sram_base_print; |
| 1137 | #else | 913 | #else |
| 1138 | #define ahd_waiting_scb_tails_print(regvalue, cur_col, wrap) \ | 914 | #define ahd_sram_base_print(regvalue, cur_col, wrap) \ |
| 1139 | ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", 0x100, regvalue, cur_col, wrap) | 915 | ahd_print_register(NULL, 0, "SRAM_BASE", 0x100, regvalue, cur_col, wrap) |
| 1140 | #endif | 916 | #endif |
| 1141 | 917 | ||
| 1142 | #if AIC_DEBUG_REGISTERS | 918 | #if AIC_DEBUG_REGISTERS |
| @@ -1224,13 +1000,6 @@ ahd_reg_print_t ahd_msg_out_print; | |||
| 1224 | #endif | 1000 | #endif |
| 1225 | 1001 | ||
| 1226 | #if AIC_DEBUG_REGISTERS | 1002 | #if AIC_DEBUG_REGISTERS |
| 1227 | ahd_reg_print_t ahd_dmaparams_print; | ||
| 1228 | #else | ||
| 1229 | #define ahd_dmaparams_print(regvalue, cur_col, wrap) \ | ||
| 1230 | ahd_print_register(NULL, 0, "DMAPARAMS", 0x138, regvalue, cur_col, wrap) | ||
| 1231 | #endif | ||
| 1232 | |||
| 1233 | #if AIC_DEBUG_REGISTERS | ||
| 1234 | ahd_reg_print_t ahd_seq_flags_print; | 1003 | ahd_reg_print_t ahd_seq_flags_print; |
| 1235 | #else | 1004 | #else |
| 1236 | #define ahd_seq_flags_print(regvalue, cur_col, wrap) \ | 1005 | #define ahd_seq_flags_print(regvalue, cur_col, wrap) \ |
| @@ -1238,20 +1007,6 @@ ahd_reg_print_t ahd_seq_flags_print; | |||
| 1238 | #endif | 1007 | #endif |
| 1239 | 1008 | ||
| 1240 | #if AIC_DEBUG_REGISTERS | 1009 | #if AIC_DEBUG_REGISTERS |
| 1241 | ahd_reg_print_t ahd_saved_scsiid_print; | ||
| 1242 | #else | ||
| 1243 | #define ahd_saved_scsiid_print(regvalue, cur_col, wrap) \ | ||
| 1244 | ahd_print_register(NULL, 0, "SAVED_SCSIID", 0x13a, regvalue, cur_col, wrap) | ||
| 1245 | #endif | ||
| 1246 | |||
| 1247 | #if AIC_DEBUG_REGISTERS | ||
| 1248 | ahd_reg_print_t ahd_saved_lun_print; | ||
| 1249 | #else | ||
| 1250 | #define ahd_saved_lun_print(regvalue, cur_col, wrap) \ | ||
| 1251 | ahd_print_register(NULL, 0, "SAVED_LUN", 0x13b, regvalue, cur_col, wrap) | ||
| 1252 | #endif | ||
| 1253 | |||
| 1254 | #if AIC_DEBUG_REGISTERS | ||
| 1255 | ahd_reg_print_t ahd_lastphase_print; | 1010 | ahd_reg_print_t ahd_lastphase_print; |
| 1256 | #else | 1011 | #else |
| 1257 | #define ahd_lastphase_print(regvalue, cur_col, wrap) \ | 1012 | #define ahd_lastphase_print(regvalue, cur_col, wrap) \ |
| @@ -1273,20 +1028,6 @@ ahd_reg_print_t ahd_kernel_tqinpos_print; | |||
| 1273 | #endif | 1028 | #endif |
| 1274 | 1029 | ||
| 1275 | #if AIC_DEBUG_REGISTERS | 1030 | #if AIC_DEBUG_REGISTERS |
| 1276 | ahd_reg_print_t ahd_tqinpos_print; | ||
| 1277 | #else | ||
| 1278 | #define ahd_tqinpos_print(regvalue, cur_col, wrap) \ | ||
| 1279 | ahd_print_register(NULL, 0, "TQINPOS", 0x13f, regvalue, cur_col, wrap) | ||
| 1280 | #endif | ||
| 1281 | |||
| 1282 | #if AIC_DEBUG_REGISTERS | ||
| 1283 | ahd_reg_print_t ahd_shared_data_addr_print; | ||
| 1284 | #else | ||
| 1285 | #define ahd_shared_data_addr_print(regvalue, cur_col, wrap) \ | ||
| 1286 | ahd_print_register(NULL, 0, "SHARED_DATA_ADDR", 0x140, regvalue, cur_col, wrap) | ||
| 1287 | #endif | ||
| 1288 | |||
| 1289 | #if AIC_DEBUG_REGISTERS | ||
| 1290 | ahd_reg_print_t ahd_qoutfifo_next_addr_print; | 1031 | ahd_reg_print_t ahd_qoutfifo_next_addr_print; |
| 1291 | #else | 1032 | #else |
| 1292 | #define ahd_qoutfifo_next_addr_print(regvalue, cur_col, wrap) \ | 1033 | #define ahd_qoutfifo_next_addr_print(regvalue, cur_col, wrap) \ |
| @@ -1294,20 +1035,6 @@ ahd_reg_print_t ahd_qoutfifo_next_addr_print; | |||
| 1294 | #endif | 1035 | #endif |
| 1295 | 1036 | ||
| 1296 | #if AIC_DEBUG_REGISTERS | 1037 | #if AIC_DEBUG_REGISTERS |
| 1297 | ahd_reg_print_t ahd_arg_1_print; | ||
| 1298 | #else | ||
| 1299 | #define ahd_arg_1_print(regvalue, cur_col, wrap) \ | ||
| 1300 | ahd_print_register(NULL, 0, "ARG_1", 0x148, regvalue, cur_col, wrap) | ||
| 1301 | #endif | ||
| 1302 | |||
| 1303 | #if AIC_DEBUG_REGISTERS | ||
| 1304 | ahd_reg_print_t ahd_arg_2_print; | ||
| 1305 | #else | ||
| 1306 | #define ahd_arg_2_print(regvalue, cur_col, wrap) \ | ||
| 1307 | ahd_print_register(NULL, 0, "ARG_2", 0x149, regvalue, cur_col, wrap) | ||
| 1308 | #endif | ||
| 1309 | |||
| 1310 | #if AIC_DEBUG_REGISTERS | ||
| 1311 | ahd_reg_print_t ahd_last_msg_print; | 1038 | ahd_reg_print_t ahd_last_msg_print; |
| 1312 | #else | 1039 | #else |
| 1313 | #define ahd_last_msg_print(regvalue, cur_col, wrap) \ | 1040 | #define ahd_last_msg_print(regvalue, cur_col, wrap) \ |
| @@ -1406,13 +1133,6 @@ ahd_reg_print_t ahd_mk_message_scsiid_print; | |||
| 1406 | #endif | 1133 | #endif |
| 1407 | 1134 | ||
| 1408 | #if AIC_DEBUG_REGISTERS | 1135 | #if AIC_DEBUG_REGISTERS |
| 1409 | ahd_reg_print_t ahd_scb_residual_datacnt_print; | ||
| 1410 | #else | ||
| 1411 | #define ahd_scb_residual_datacnt_print(regvalue, cur_col, wrap) \ | ||
| 1412 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", 0x180, regvalue, cur_col, wrap) | ||
| 1413 | #endif | ||
| 1414 | |||
| 1415 | #if AIC_DEBUG_REGISTERS | ||
| 1416 | ahd_reg_print_t ahd_scb_base_print; | 1136 | ahd_reg_print_t ahd_scb_base_print; |
| 1417 | #else | 1137 | #else |
| 1418 | #define ahd_scb_base_print(regvalue, cur_col, wrap) \ | 1138 | #define ahd_scb_base_print(regvalue, cur_col, wrap) \ |
| @@ -1420,17 +1140,10 @@ ahd_reg_print_t ahd_scb_base_print; | |||
| 1420 | #endif | 1140 | #endif |
| 1421 | 1141 | ||
| 1422 | #if AIC_DEBUG_REGISTERS | 1142 | #if AIC_DEBUG_REGISTERS |
| 1423 | ahd_reg_print_t ahd_scb_residual_sgptr_print; | 1143 | ahd_reg_print_t ahd_scb_residual_datacnt_print; |
| 1424 | #else | ||
| 1425 | #define ahd_scb_residual_sgptr_print(regvalue, cur_col, wrap) \ | ||
| 1426 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", 0x184, regvalue, cur_col, wrap) | ||
| 1427 | #endif | ||
| 1428 | |||
| 1429 | #if AIC_DEBUG_REGISTERS | ||
| 1430 | ahd_reg_print_t ahd_scb_scsi_status_print; | ||
| 1431 | #else | 1144 | #else |
| 1432 | #define ahd_scb_scsi_status_print(regvalue, cur_col, wrap) \ | 1145 | #define ahd_scb_residual_datacnt_print(regvalue, cur_col, wrap) \ |
| 1433 | ahd_print_register(NULL, 0, "SCB_SCSI_STATUS", 0x188, regvalue, cur_col, wrap) | 1146 | ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", 0x180, regvalue, cur_col, wrap) |
| 1434 | #endif | 1147 | #endif |
| 1435 | 1148 | ||
| 1436 | #if AIC_DEBUG_REGISTERS | 1149 | #if AIC_DEBUG_REGISTERS |
| @@ -1476,13 +1189,6 @@ ahd_reg_print_t ahd_scb_task_attribute_print; | |||
| 1476 | #endif | 1189 | #endif |
| 1477 | 1190 | ||
| 1478 | #if AIC_DEBUG_REGISTERS | 1191 | #if AIC_DEBUG_REGISTERS |
| 1479 | ahd_reg_print_t ahd_scb_cdb_len_print; | ||
| 1480 | #else | ||
| 1481 | #define ahd_scb_cdb_len_print(regvalue, cur_col, wrap) \ | ||
| 1482 | ahd_print_register(NULL, 0, "SCB_CDB_LEN", 0x196, regvalue, cur_col, wrap) | ||
| 1483 | #endif | ||
| 1484 | |||
| 1485 | #if AIC_DEBUG_REGISTERS | ||
| 1486 | ahd_reg_print_t ahd_scb_task_management_print; | 1192 | ahd_reg_print_t ahd_scb_task_management_print; |
| 1487 | #else | 1193 | #else |
| 1488 | #define ahd_scb_task_management_print(regvalue, cur_col, wrap) \ | 1194 | #define ahd_scb_task_management_print(regvalue, cur_col, wrap) \ |
| @@ -1518,13 +1224,6 @@ ahd_reg_print_t ahd_scb_busaddr_print; | |||
| 1518 | #endif | 1224 | #endif |
| 1519 | 1225 | ||
| 1520 | #if AIC_DEBUG_REGISTERS | 1226 | #if AIC_DEBUG_REGISTERS |
| 1521 | ahd_reg_print_t ahd_scb_next_print; | ||
| 1522 | #else | ||
| 1523 | #define ahd_scb_next_print(regvalue, cur_col, wrap) \ | ||
| 1524 | ahd_print_register(NULL, 0, "SCB_NEXT", 0x1ac, regvalue, cur_col, wrap) | ||
| 1525 | #endif | ||
| 1526 | |||
| 1527 | #if AIC_DEBUG_REGISTERS | ||
| 1528 | ahd_reg_print_t ahd_scb_next2_print; | 1227 | ahd_reg_print_t ahd_scb_next2_print; |
| 1529 | #else | 1228 | #else |
| 1530 | #define ahd_scb_next2_print(regvalue, cur_col, wrap) \ | 1229 | #define ahd_scb_next2_print(regvalue, cur_col, wrap) \ |
| @@ -1717,10 +1416,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1717 | 1416 | ||
| 1718 | #define SG_CACHE_PRE 0x1b | 1417 | #define SG_CACHE_PRE 0x1b |
| 1719 | 1418 | ||
| 1720 | #define TYPEPTR 0x20 | ||
| 1721 | |||
| 1722 | #define LQIN 0x20 | 1419 | #define LQIN 0x20 |
| 1723 | 1420 | ||
| 1421 | #define TYPEPTR 0x20 | ||
| 1422 | |||
| 1724 | #define TAGPTR 0x21 | 1423 | #define TAGPTR 0x21 |
| 1725 | 1424 | ||
| 1726 | #define LUNPTR 0x22 | 1425 | #define LUNPTR 0x22 |
| @@ -1780,6 +1479,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1780 | #define SINGLECMD 0x02 | 1479 | #define SINGLECMD 0x02 |
| 1781 | #define ABORTPENDING 0x01 | 1480 | #define ABORTPENDING 0x01 |
| 1782 | 1481 | ||
| 1482 | #define SCSBIST0 0x39 | ||
| 1483 | #define GSBISTERR 0x40 | ||
| 1484 | #define GSBISTDONE 0x20 | ||
| 1485 | #define GSBISTRUN 0x10 | ||
| 1486 | #define OSBISTERR 0x04 | ||
| 1487 | #define OSBISTDONE 0x02 | ||
| 1488 | #define OSBISTRUN 0x01 | ||
| 1489 | |||
| 1783 | #define LQCTL2 0x39 | 1490 | #define LQCTL2 0x39 |
| 1784 | #define LQIRETRY 0x80 | 1491 | #define LQIRETRY 0x80 |
| 1785 | #define LQICONTINUE 0x40 | 1492 | #define LQICONTINUE 0x40 |
| @@ -1790,13 +1497,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1790 | #define LQOTOIDLE 0x02 | 1497 | #define LQOTOIDLE 0x02 |
| 1791 | #define LQOPAUSE 0x01 | 1498 | #define LQOPAUSE 0x01 |
| 1792 | 1499 | ||
| 1793 | #define SCSBIST0 0x39 | 1500 | #define SCSBIST1 0x3a |
| 1794 | #define GSBISTERR 0x40 | 1501 | #define NTBISTERR 0x04 |
| 1795 | #define GSBISTDONE 0x20 | 1502 | #define NTBISTDONE 0x02 |
| 1796 | #define GSBISTRUN 0x10 | 1503 | #define NTBISTRUN 0x01 |
| 1797 | #define OSBISTERR 0x04 | ||
| 1798 | #define OSBISTDONE 0x02 | ||
| 1799 | #define OSBISTRUN 0x01 | ||
| 1800 | 1504 | ||
| 1801 | #define SCSISEQ0 0x3a | 1505 | #define SCSISEQ0 0x3a |
| 1802 | #define TEMODEO 0x80 | 1506 | #define TEMODEO 0x80 |
| @@ -1805,15 +1509,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1805 | #define FORCEBUSFREE 0x10 | 1509 | #define FORCEBUSFREE 0x10 |
| 1806 | #define SCSIRSTO 0x01 | 1510 | #define SCSIRSTO 0x01 |
| 1807 | 1511 | ||
| 1808 | #define SCSBIST1 0x3a | ||
| 1809 | #define NTBISTERR 0x04 | ||
| 1810 | #define NTBISTDONE 0x02 | ||
| 1811 | #define NTBISTRUN 0x01 | ||
| 1812 | |||
| 1813 | #define SCSISEQ1 0x3b | 1512 | #define SCSISEQ1 0x3b |
| 1814 | 1513 | ||
| 1815 | #define BUSINITID 0x3c | ||
| 1816 | |||
| 1817 | #define SXFRCTL0 0x3c | 1514 | #define SXFRCTL0 0x3c |
| 1818 | #define DFON 0x80 | 1515 | #define DFON 0x80 |
| 1819 | #define DFPEXP 0x40 | 1516 | #define DFPEXP 0x40 |
| @@ -1822,6 +1519,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1822 | 1519 | ||
| 1823 | #define DLCOUNT 0x3c | 1520 | #define DLCOUNT 0x3c |
| 1824 | 1521 | ||
| 1522 | #define BUSINITID 0x3c | ||
| 1523 | |||
| 1825 | #define SXFRCTL1 0x3d | 1524 | #define SXFRCTL1 0x3d |
| 1826 | #define BITBUCKET 0x80 | 1525 | #define BITBUCKET 0x80 |
| 1827 | #define ENSACHK 0x40 | 1526 | #define ENSACHK 0x40 |
| @@ -1846,8 +1545,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1846 | #define CURRFIFO_1 0x01 | 1545 | #define CURRFIFO_1 0x01 |
| 1847 | #define CURRFIFO_0 0x00 | 1546 | #define CURRFIFO_0 0x00 |
| 1848 | 1547 | ||
| 1849 | #define MULTARGID 0x40 | ||
| 1850 | |||
| 1851 | #define SCSISIGO 0x40 | 1548 | #define SCSISIGO 0x40 |
| 1852 | #define CDO 0x80 | 1549 | #define CDO 0x80 |
| 1853 | #define IOO 0x40 | 1550 | #define IOO 0x40 |
| @@ -1858,6 +1555,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1858 | #define REQO 0x02 | 1555 | #define REQO 0x02 |
| 1859 | #define ACKO 0x01 | 1556 | #define ACKO 0x01 |
| 1860 | 1557 | ||
| 1558 | #define MULTARGID 0x40 | ||
| 1559 | |||
| 1861 | #define SCSISIGI 0x41 | 1560 | #define SCSISIGI 0x41 |
| 1862 | #define ATNI 0x10 | 1561 | #define ATNI 0x10 |
| 1863 | #define SELI 0x08 | 1562 | #define SELI 0x08 |
| @@ -1904,6 +1603,15 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1904 | #define ENAB20 0x04 | 1603 | #define ENAB20 0x04 |
| 1905 | #define SELWIDE 0x02 | 1604 | #define SELWIDE 0x02 |
| 1906 | 1605 | ||
| 1606 | #define CLRSINT0 0x4b | ||
| 1607 | #define CLRSELDO 0x40 | ||
| 1608 | #define CLRSELDI 0x20 | ||
| 1609 | #define CLRSELINGO 0x10 | ||
| 1610 | #define CLRIOERR 0x08 | ||
| 1611 | #define CLROVERRUN 0x04 | ||
| 1612 | #define CLRSPIORDY 0x02 | ||
| 1613 | #define CLRARBDO 0x01 | ||
| 1614 | |||
| 1907 | #define SSTAT0 0x4b | 1615 | #define SSTAT0 0x4b |
| 1908 | #define TARGET 0x80 | 1616 | #define TARGET 0x80 |
| 1909 | #define SELDO 0x40 | 1617 | #define SELDO 0x40 |
| @@ -1923,14 +1631,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1923 | #define ENSPIORDY 0x02 | 1631 | #define ENSPIORDY 0x02 |
| 1924 | #define ENARBDO 0x01 | 1632 | #define ENARBDO 0x01 |
| 1925 | 1633 | ||
| 1926 | #define CLRSINT0 0x4b | 1634 | #define CLRSINT1 0x4c |
| 1927 | #define CLRSELDO 0x40 | 1635 | #define CLRSELTIMEO 0x80 |
| 1928 | #define CLRSELDI 0x20 | 1636 | #define CLRATNO 0x40 |
| 1929 | #define CLRSELINGO 0x10 | 1637 | #define CLRSCSIRSTI 0x20 |
| 1930 | #define CLRIOERR 0x08 | 1638 | #define CLRBUSFREE 0x08 |
| 1931 | #define CLROVERRUN 0x04 | 1639 | #define CLRSCSIPERR 0x04 |
| 1932 | #define CLRSPIORDY 0x02 | 1640 | #define CLRSTRB2FAST 0x02 |
| 1933 | #define CLRARBDO 0x01 | 1641 | #define CLRREQINIT 0x01 |
| 1934 | 1642 | ||
| 1935 | #define SSTAT1 0x4c | 1643 | #define SSTAT1 0x4c |
| 1936 | #define SELTO 0x80 | 1644 | #define SELTO 0x80 |
| @@ -1942,15 +1650,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1942 | #define STRB2FAST 0x02 | 1650 | #define STRB2FAST 0x02 |
| 1943 | #define REQINIT 0x01 | 1651 | #define REQINIT 0x01 |
| 1944 | 1652 | ||
| 1945 | #define CLRSINT1 0x4c | ||
| 1946 | #define CLRSELTIMEO 0x80 | ||
| 1947 | #define CLRATNO 0x40 | ||
| 1948 | #define CLRSCSIRSTI 0x20 | ||
| 1949 | #define CLRBUSFREE 0x08 | ||
| 1950 | #define CLRSCSIPERR 0x04 | ||
| 1951 | #define CLRSTRB2FAST 0x02 | ||
| 1952 | #define CLRREQINIT 0x01 | ||
| 1953 | |||
| 1954 | #define SSTAT2 0x4d | 1653 | #define SSTAT2 0x4d |
| 1955 | #define BUSFREETIME 0xc0 | 1654 | #define BUSFREETIME 0xc0 |
| 1956 | #define NONPACKREQ 0x20 | 1655 | #define NONPACKREQ 0x20 |
| @@ -1998,14 +1697,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 1998 | #define LQIATNLQ 0x02 | 1697 | #define LQIATNLQ 0x02 |
| 1999 | #define LQIATNCMD 0x01 | 1698 | #define LQIATNCMD 0x01 |
| 2000 | 1699 | ||
| 2001 | #define LQIMODE0 0x50 | ||
| 2002 | #define ENLQIATNQASK 0x20 | ||
| 2003 | #define ENLQICRCT1 0x10 | ||
| 2004 | #define ENLQICRCT2 0x08 | ||
| 2005 | #define ENLQIBADLQT 0x04 | ||
| 2006 | #define ENLQIATNLQ 0x02 | ||
| 2007 | #define ENLQIATNCMD 0x01 | ||
| 2008 | |||
| 2009 | #define CLRLQIINT0 0x50 | 1700 | #define CLRLQIINT0 0x50 |
| 2010 | #define CLRLQIATNQAS 0x20 | 1701 | #define CLRLQIATNQAS 0x20 |
| 2011 | #define CLRLQICRCT1 0x10 | 1702 | #define CLRLQICRCT1 0x10 |
| @@ -2014,6 +1705,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2014 | #define CLRLQIATNLQ 0x02 | 1705 | #define CLRLQIATNLQ 0x02 |
| 2015 | #define CLRLQIATNCMD 0x01 | 1706 | #define CLRLQIATNCMD 0x01 |
| 2016 | 1707 | ||
| 1708 | #define LQIMODE0 0x50 | ||
| 1709 | #define ENLQIATNQASK 0x20 | ||
| 1710 | #define ENLQICRCT1 0x10 | ||
| 1711 | #define ENLQICRCT2 0x08 | ||
| 1712 | #define ENLQIBADLQT 0x04 | ||
| 1713 | #define ENLQIATNLQ 0x02 | ||
| 1714 | #define ENLQIATNCMD 0x01 | ||
| 1715 | |||
| 2017 | #define LQIMODE1 0x51 | 1716 | #define LQIMODE1 0x51 |
| 2018 | #define ENLQIPHASE_LQ 0x80 | 1717 | #define ENLQIPHASE_LQ 0x80 |
| 2019 | #define ENLQIPHASE_NLQ 0x40 | 1718 | #define ENLQIPHASE_NLQ 0x40 |
| @@ -2160,6 +1859,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2160 | #define CFG4ICMD 0x02 | 1859 | #define CFG4ICMD 0x02 |
| 2161 | #define CFG4TCMD 0x01 | 1860 | #define CFG4TCMD 0x01 |
| 2162 | 1861 | ||
| 1862 | #define CURRSCB 0x5c | ||
| 1863 | |||
| 2163 | #define SEQIMODE 0x5c | 1864 | #define SEQIMODE 0x5c |
| 2164 | #define ENCTXTDONE 0x40 | 1865 | #define ENCTXTDONE 0x40 |
| 2165 | #define ENSAVEPTRS 0x20 | 1866 | #define ENSAVEPTRS 0x20 |
| @@ -2169,8 +1870,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2169 | #define ENCFG4ICMD 0x02 | 1870 | #define ENCFG4ICMD 0x02 |
| 2170 | #define ENCFG4TCMD 0x01 | 1871 | #define ENCFG4TCMD 0x01 |
| 2171 | 1872 | ||
| 2172 | #define CURRSCB 0x5c | ||
| 2173 | |||
| 2174 | #define MDFFSTAT 0x5d | 1873 | #define MDFFSTAT 0x5d |
| 2175 | #define SHCNTNEGATIVE 0x40 | 1874 | #define SHCNTNEGATIVE 0x40 |
| 2176 | #define SHCNTMINUS1 0x20 | 1875 | #define SHCNTMINUS1 0x20 |
| @@ -2185,29 +1884,29 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2185 | 1884 | ||
| 2186 | #define DFFTAG 0x5e | 1885 | #define DFFTAG 0x5e |
| 2187 | 1886 | ||
| 1887 | #define LASTSCB 0x5e | ||
| 1888 | |||
| 2188 | #define SCSITEST 0x5e | 1889 | #define SCSITEST 0x5e |
| 2189 | #define CNTRTEST 0x08 | 1890 | #define CNTRTEST 0x08 |
| 2190 | #define SEL_TXPLL_DEBUG 0x04 | 1891 | #define SEL_TXPLL_DEBUG 0x04 |
| 2191 | 1892 | ||
| 2192 | #define LASTSCB 0x5e | ||
| 2193 | |||
| 2194 | #define IOPDNCTL 0x5f | 1893 | #define IOPDNCTL 0x5f |
| 2195 | #define DISABLE_OE 0x80 | 1894 | #define DISABLE_OE 0x80 |
| 2196 | #define PDN_IDIST 0x04 | 1895 | #define PDN_IDIST 0x04 |
| 2197 | #define PDN_DIFFSENSE 0x01 | 1896 | #define PDN_DIFFSENSE 0x01 |
| 2198 | 1897 | ||
| 2199 | #define DGRPCRCI 0x60 | ||
| 2200 | |||
| 2201 | #define SHADDR 0x60 | 1898 | #define SHADDR 0x60 |
| 2202 | 1899 | ||
| 2203 | #define NEGOADDR 0x60 | 1900 | #define NEGOADDR 0x60 |
| 2204 | 1901 | ||
| 2205 | #define NEGPERIOD 0x61 | 1902 | #define DGRPCRCI 0x60 |
| 2206 | 1903 | ||
| 2207 | #define NEGOFFSET 0x62 | 1904 | #define NEGPERIOD 0x61 |
| 2208 | 1905 | ||
| 2209 | #define PACKCRCI 0x62 | 1906 | #define PACKCRCI 0x62 |
| 2210 | 1907 | ||
| 1908 | #define NEGOFFSET 0x62 | ||
| 1909 | |||
| 2211 | #define NEGPPROPTS 0x63 | 1910 | #define NEGPPROPTS 0x63 |
| 2212 | #define PPROPT_PACE 0x08 | 1911 | #define PPROPT_PACE 0x08 |
| 2213 | #define PPROPT_QAS 0x04 | 1912 | #define PPROPT_QAS 0x04 |
| @@ -2253,8 +1952,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2253 | 1952 | ||
| 2254 | #define SELOID 0x6b | 1953 | #define SELOID 0x6b |
| 2255 | 1954 | ||
| 2256 | #define FAIRNESS 0x6c | ||
| 2257 | |||
| 2258 | #define PLL400CTL0 0x6c | 1955 | #define PLL400CTL0 0x6c |
| 2259 | #define PLL_VCOSEL 0x80 | 1956 | #define PLL_VCOSEL 0x80 |
| 2260 | #define PLL_PWDN 0x40 | 1957 | #define PLL_PWDN 0x40 |
| @@ -2264,6 +1961,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2264 | #define PLL_DLPF 0x02 | 1961 | #define PLL_DLPF 0x02 |
| 2265 | #define PLL_ENFBM 0x01 | 1962 | #define PLL_ENFBM 0x01 |
| 2266 | 1963 | ||
| 1964 | #define FAIRNESS 0x6c | ||
| 1965 | |||
| 2267 | #define PLL400CTL1 0x6d | 1966 | #define PLL400CTL1 0x6d |
| 2268 | #define PLL_CNTEN 0x80 | 1967 | #define PLL_CNTEN 0x80 |
| 2269 | #define PLL_CNTCLR 0x40 | 1968 | #define PLL_CNTCLR 0x40 |
| @@ -2275,25 +1974,25 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2275 | 1974 | ||
| 2276 | #define HADDR 0x70 | 1975 | #define HADDR 0x70 |
| 2277 | 1976 | ||
| 2278 | #define HODMAADR 0x70 | ||
| 2279 | |||
| 2280 | #define PLLDELAY 0x70 | 1977 | #define PLLDELAY 0x70 |
| 2281 | #define SPLIT_DROP_REQ 0x80 | 1978 | #define SPLIT_DROP_REQ 0x80 |
| 2282 | 1979 | ||
| 2283 | #define HCNT 0x78 | 1980 | #define HODMAADR 0x70 |
| 2284 | 1981 | ||
| 2285 | #define HODMACNT 0x78 | 1982 | #define HODMACNT 0x78 |
| 2286 | 1983 | ||
| 2287 | #define HODMAEN 0x7a | 1984 | #define HCNT 0x78 |
| 2288 | 1985 | ||
| 2289 | #define SGHADDR 0x7c | 1986 | #define HODMAEN 0x7a |
| 2290 | 1987 | ||
| 2291 | #define SCBHADDR 0x7c | 1988 | #define SCBHADDR 0x7c |
| 2292 | 1989 | ||
| 2293 | #define SGHCNT 0x84 | 1990 | #define SGHADDR 0x7c |
| 2294 | 1991 | ||
| 2295 | #define SCBHCNT 0x84 | 1992 | #define SCBHCNT 0x84 |
| 2296 | 1993 | ||
| 1994 | #define SGHCNT 0x84 | ||
| 1995 | |||
| 2297 | #define DFF_THRSH 0x88 | 1996 | #define DFF_THRSH 0x88 |
| 2298 | #define WR_DFTHRSH 0x70 | 1997 | #define WR_DFTHRSH 0x70 |
| 2299 | #define RD_DFTHRSH 0x07 | 1998 | #define RD_DFTHRSH 0x07 |
| @@ -2326,10 +2025,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2326 | 2025 | ||
| 2327 | #define CMCRXMSG0 0x90 | 2026 | #define CMCRXMSG0 0x90 |
| 2328 | 2027 | ||
| 2329 | #define OVLYRXMSG0 0x90 | ||
| 2330 | |||
| 2331 | #define DCHRXMSG0 0x90 | ||
| 2332 | |||
| 2333 | #define ROENABLE 0x90 | 2028 | #define ROENABLE 0x90 |
| 2334 | #define MSIROEN 0x20 | 2029 | #define MSIROEN 0x20 |
| 2335 | #define OVLYROEN 0x10 | 2030 | #define OVLYROEN 0x10 |
| @@ -2338,11 +2033,11 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2338 | #define DCH1ROEN 0x02 | 2033 | #define DCH1ROEN 0x02 |
| 2339 | #define DCH0ROEN 0x01 | 2034 | #define DCH0ROEN 0x01 |
| 2340 | 2035 | ||
| 2341 | #define OVLYRXMSG1 0x91 | 2036 | #define OVLYRXMSG0 0x90 |
| 2342 | 2037 | ||
| 2343 | #define CMCRXMSG1 0x91 | 2038 | #define DCHRXMSG0 0x90 |
| 2344 | 2039 | ||
| 2345 | #define DCHRXMSG1 0x91 | 2040 | #define OVLYRXMSG1 0x91 |
| 2346 | 2041 | ||
| 2347 | #define NSENABLE 0x91 | 2042 | #define NSENABLE 0x91 |
| 2348 | #define MSINSEN 0x20 | 2043 | #define MSINSEN 0x20 |
| @@ -2352,6 +2047,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2352 | #define DCH1NSEN 0x02 | 2047 | #define DCH1NSEN 0x02 |
| 2353 | #define DCH0NSEN 0x01 | 2048 | #define DCH0NSEN 0x01 |
| 2354 | 2049 | ||
| 2050 | #define CMCRXMSG1 0x91 | ||
| 2051 | |||
| 2052 | #define DCHRXMSG1 0x91 | ||
| 2053 | |||
| 2355 | #define DCHRXMSG2 0x92 | 2054 | #define DCHRXMSG2 0x92 |
| 2356 | 2055 | ||
| 2357 | #define CMCRXMSG2 0x92 | 2056 | #define CMCRXMSG2 0x92 |
| @@ -2375,24 +2074,24 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2375 | #define TSCSERREN 0x02 | 2074 | #define TSCSERREN 0x02 |
| 2376 | #define CMPABCDIS 0x01 | 2075 | #define CMPABCDIS 0x01 |
| 2377 | 2076 | ||
| 2378 | #define CMCSEQBCNT 0x94 | ||
| 2379 | |||
| 2380 | #define OVLYSEQBCNT 0x94 | 2077 | #define OVLYSEQBCNT 0x94 |
| 2381 | 2078 | ||
| 2382 | #define DCHSEQBCNT 0x94 | 2079 | #define DCHSEQBCNT 0x94 |
| 2383 | 2080 | ||
| 2081 | #define CMCSEQBCNT 0x94 | ||
| 2082 | |||
| 2083 | #define CMCSPLTSTAT0 0x96 | ||
| 2084 | |||
| 2384 | #define DCHSPLTSTAT0 0x96 | 2085 | #define DCHSPLTSTAT0 0x96 |
| 2385 | 2086 | ||
| 2386 | #define OVLYSPLTSTAT0 0x96 | 2087 | #define OVLYSPLTSTAT0 0x96 |
| 2387 | 2088 | ||
| 2388 | #define CMCSPLTSTAT0 0x96 | 2089 | #define CMCSPLTSTAT1 0x97 |
| 2389 | 2090 | ||
| 2390 | #define OVLYSPLTSTAT1 0x97 | 2091 | #define OVLYSPLTSTAT1 0x97 |
| 2391 | 2092 | ||
| 2392 | #define DCHSPLTSTAT1 0x97 | 2093 | #define DCHSPLTSTAT1 0x97 |
| 2393 | 2094 | ||
| 2394 | #define CMCSPLTSTAT1 0x97 | ||
| 2395 | |||
| 2396 | #define SGRXMSG0 0x98 | 2095 | #define SGRXMSG0 0x98 |
| 2397 | #define CDNUM 0xf8 | 2096 | #define CDNUM 0xf8 |
| 2398 | #define CFNUM 0x07 | 2097 | #define CFNUM 0x07 |
| @@ -2420,15 +2119,18 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2420 | #define TAG_NUM 0x1f | 2119 | #define TAG_NUM 0x1f |
| 2421 | #define RLXORD 0x10 | 2120 | #define RLXORD 0x10 |
| 2422 | 2121 | ||
| 2122 | #define SGSEQBCNT 0x9c | ||
| 2123 | |||
| 2423 | #define SLVSPLTOUTATTR0 0x9c | 2124 | #define SLVSPLTOUTATTR0 0x9c |
| 2424 | #define LOWER_BCNT 0xff | 2125 | #define LOWER_BCNT 0xff |
| 2425 | 2126 | ||
| 2426 | #define SGSEQBCNT 0x9c | ||
| 2427 | |||
| 2428 | #define SLVSPLTOUTATTR1 0x9d | 2127 | #define SLVSPLTOUTATTR1 0x9d |
| 2429 | #define CMPLT_DNUM 0xf8 | 2128 | #define CMPLT_DNUM 0xf8 |
| 2430 | #define CMPLT_FNUM 0x07 | 2129 | #define CMPLT_FNUM 0x07 |
| 2431 | 2130 | ||
| 2131 | #define SLVSPLTOUTATTR2 0x9e | ||
| 2132 | #define CMPLT_BNUM 0xff | ||
| 2133 | |||
| 2432 | #define SGSPLTSTAT0 0x9e | 2134 | #define SGSPLTSTAT0 0x9e |
| 2433 | #define STAETERM 0x80 | 2135 | #define STAETERM 0x80 |
| 2434 | #define SCBCERR 0x40 | 2136 | #define SCBCERR 0x40 |
| @@ -2439,9 +2141,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2439 | #define RXSCEMSG 0x02 | 2141 | #define RXSCEMSG 0x02 |
| 2440 | #define RXSPLTRSP 0x01 | 2142 | #define RXSPLTRSP 0x01 |
| 2441 | 2143 | ||
| 2442 | #define SLVSPLTOUTATTR2 0x9e | ||
| 2443 | #define CMPLT_BNUM 0xff | ||
| 2444 | |||
| 2445 | #define SGSPLTSTAT1 0x9f | 2144 | #define SGSPLTSTAT1 0x9f |
| 2446 | #define RXDATABUCKET 0x01 | 2145 | #define RXDATABUCKET 0x01 |
| 2447 | 2146 | ||
| @@ -2497,10 +2196,10 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2497 | 2196 | ||
| 2498 | #define CCSGADDR 0xac | 2197 | #define CCSGADDR 0xac |
| 2499 | 2198 | ||
| 2500 | #define CCSCBADDR 0xac | ||
| 2501 | |||
| 2502 | #define CCSCBADR_BK 0xac | 2199 | #define CCSCBADR_BK 0xac |
| 2503 | 2200 | ||
| 2201 | #define CCSCBADDR 0xac | ||
| 2202 | |||
| 2504 | #define CMC_RAMBIST 0xad | 2203 | #define CMC_RAMBIST 0xad |
| 2505 | #define SG_ELEMENT_SIZE 0x80 | 2204 | #define SG_ELEMENT_SIZE 0x80 |
| 2506 | #define SCBRAMBIST_FAIL 0x40 | 2205 | #define SCBRAMBIST_FAIL 0x40 |
| @@ -2554,9 +2253,9 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2554 | #define SEEDAT 0xbc | 2253 | #define SEEDAT 0xbc |
| 2555 | 2254 | ||
| 2556 | #define SEECTL 0xbe | 2255 | #define SEECTL 0xbe |
| 2557 | #define SEEOP_EWDS 0x40 | ||
| 2558 | #define SEEOP_WALL 0x40 | 2256 | #define SEEOP_WALL 0x40 |
| 2559 | #define SEEOP_EWEN 0x40 | 2257 | #define SEEOP_EWEN 0x40 |
| 2258 | #define SEEOP_EWDS 0x40 | ||
| 2560 | #define SEEOPCODE 0x70 | 2259 | #define SEEOPCODE 0x70 |
| 2561 | #define SEERST 0x02 | 2260 | #define SEERST 0x02 |
| 2562 | #define SEESTART 0x01 | 2261 | #define SEESTART 0x01 |
| @@ -2573,25 +2272,25 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2573 | 2272 | ||
| 2574 | #define SCBCNT 0xbf | 2273 | #define SCBCNT 0xbf |
| 2575 | 2274 | ||
| 2275 | #define DFWADDR 0xc0 | ||
| 2276 | |||
| 2576 | #define DSPFLTRCTL 0xc0 | 2277 | #define DSPFLTRCTL 0xc0 |
| 2577 | #define FLTRDISABLE 0x20 | 2278 | #define FLTRDISABLE 0x20 |
| 2578 | #define EDGESENSE 0x10 | 2279 | #define EDGESENSE 0x10 |
| 2579 | #define DSPFCNTSEL 0x0f | 2280 | #define DSPFCNTSEL 0x0f |
| 2580 | 2281 | ||
| 2581 | #define DFWADDR 0xc0 | ||
| 2582 | |||
| 2583 | #define DSPDATACTL 0xc1 | 2282 | #define DSPDATACTL 0xc1 |
| 2584 | #define BYPASSENAB 0x80 | 2283 | #define BYPASSENAB 0x80 |
| 2585 | #define DESQDIS 0x10 | 2284 | #define DESQDIS 0x10 |
| 2586 | #define RCVROFFSTDIS 0x04 | 2285 | #define RCVROFFSTDIS 0x04 |
| 2587 | #define XMITOFFSTDIS 0x02 | 2286 | #define XMITOFFSTDIS 0x02 |
| 2588 | 2287 | ||
| 2288 | #define DFRADDR 0xc2 | ||
| 2289 | |||
| 2589 | #define DSPREQCTL 0xc2 | 2290 | #define DSPREQCTL 0xc2 |
| 2590 | #define MANREQCTL 0xc0 | 2291 | #define MANREQCTL 0xc0 |
| 2591 | #define MANREQDLY 0x3f | 2292 | #define MANREQDLY 0x3f |
| 2592 | 2293 | ||
| 2593 | #define DFRADDR 0xc2 | ||
| 2594 | |||
| 2595 | #define DSPACKCTL 0xc3 | 2294 | #define DSPACKCTL 0xc3 |
| 2596 | #define MANACKCTL 0xc0 | 2295 | #define MANACKCTL 0xc0 |
| 2597 | #define MANACKDLY 0x3f | 2296 | #define MANACKDLY 0x3f |
| @@ -2612,14 +2311,14 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2612 | 2311 | ||
| 2613 | #define WRTBIASCALC 0xc7 | 2312 | #define WRTBIASCALC 0xc7 |
| 2614 | 2313 | ||
| 2615 | #define DFPTRS 0xc8 | ||
| 2616 | |||
| 2617 | #define RCVRBIASCALC 0xc8 | 2314 | #define RCVRBIASCALC 0xc8 |
| 2618 | 2315 | ||
| 2619 | #define DFBKPTR 0xc9 | 2316 | #define DFPTRS 0xc8 |
| 2620 | 2317 | ||
| 2621 | #define SKEWCALC 0xc9 | 2318 | #define SKEWCALC 0xc9 |
| 2622 | 2319 | ||
| 2320 | #define DFBKPTR 0xc9 | ||
| 2321 | |||
| 2623 | #define DFDBCTL 0xcb | 2322 | #define DFDBCTL 0xcb |
| 2624 | #define DFF_CIO_WR_RDY 0x20 | 2323 | #define DFF_CIO_WR_RDY 0x20 |
| 2625 | #define DFF_CIO_RD_RDY 0x10 | 2324 | #define DFF_CIO_RD_RDY 0x10 |
| @@ -2704,12 +2403,12 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2704 | 2403 | ||
| 2705 | #define ACCUM_SAVE 0xfa | 2404 | #define ACCUM_SAVE 0xfa |
| 2706 | 2405 | ||
| 2406 | #define WAITING_SCB_TAILS 0x100 | ||
| 2407 | |||
| 2707 | #define AHD_PCI_CONFIG_BASE 0x100 | 2408 | #define AHD_PCI_CONFIG_BASE 0x100 |
| 2708 | 2409 | ||
| 2709 | #define SRAM_BASE 0x100 | 2410 | #define SRAM_BASE 0x100 |
| 2710 | 2411 | ||
| 2711 | #define WAITING_SCB_TAILS 0x100 | ||
| 2712 | |||
| 2713 | #define WAITING_TID_HEAD 0x120 | 2412 | #define WAITING_TID_HEAD 0x120 |
| 2714 | 2413 | ||
| 2715 | #define WAITING_TID_TAIL 0x122 | 2414 | #define WAITING_TID_TAIL 0x122 |
| @@ -2738,8 +2437,8 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2738 | #define PRELOADEN 0x80 | 2437 | #define PRELOADEN 0x80 |
| 2739 | #define WIDEODD 0x40 | 2438 | #define WIDEODD 0x40 |
| 2740 | #define SCSIEN 0x20 | 2439 | #define SCSIEN 0x20 |
| 2741 | #define SDMAENACK 0x10 | ||
| 2742 | #define SDMAEN 0x10 | 2440 | #define SDMAEN 0x10 |
| 2441 | #define SDMAENACK 0x10 | ||
| 2743 | #define HDMAEN 0x08 | 2442 | #define HDMAEN 0x08 |
| 2744 | #define HDMAENACK 0x08 | 2443 | #define HDMAENACK 0x08 |
| 2745 | #define DIRECTION 0x04 | 2444 | #define DIRECTION 0x04 |
| @@ -2837,12 +2536,12 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2837 | 2536 | ||
| 2838 | #define MK_MESSAGE_SCSIID 0x162 | 2537 | #define MK_MESSAGE_SCSIID 0x162 |
| 2839 | 2538 | ||
| 2539 | #define SCB_BASE 0x180 | ||
| 2540 | |||
| 2840 | #define SCB_RESIDUAL_DATACNT 0x180 | 2541 | #define SCB_RESIDUAL_DATACNT 0x180 |
| 2841 | #define SCB_CDB_STORE 0x180 | 2542 | #define SCB_CDB_STORE 0x180 |
| 2842 | #define SCB_HOST_CDB_PTR 0x180 | 2543 | #define SCB_HOST_CDB_PTR 0x180 |
| 2843 | 2544 | ||
| 2844 | #define SCB_BASE 0x180 | ||
| 2845 | |||
| 2846 | #define SCB_RESIDUAL_SGPTR 0x184 | 2545 | #define SCB_RESIDUAL_SGPTR 0x184 |
| 2847 | #define SG_ADDR_MASK 0xf8 | 2546 | #define SG_ADDR_MASK 0xf8 |
| 2848 | #define SG_OVERRUN_RESID 0x02 | 2547 | #define SG_OVERRUN_RESID 0x02 |
| @@ -2910,17 +2609,6 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2910 | #define SCB_DISCONNECTED_LISTS 0x1b8 | 2609 | #define SCB_DISCONNECTED_LISTS 0x1b8 |
| 2911 | 2610 | ||
| 2912 | 2611 | ||
| 2913 | #define CMD_GROUP_CODE_SHIFT 0x05 | ||
| 2914 | #define STIMESEL_MIN 0x18 | ||
| 2915 | #define STIMESEL_SHIFT 0x03 | ||
| 2916 | #define INVALID_ADDR 0x80 | ||
| 2917 | #define AHD_PRECOMP_MASK 0x07 | ||
| 2918 | #define TARGET_DATA_IN 0x01 | ||
| 2919 | #define CCSCBADDR_MAX 0x80 | ||
| 2920 | #define NUMDSPS 0x14 | ||
| 2921 | #define SEEOP_EWEN_ADDR 0xc0 | ||
| 2922 | #define AHD_ANNEXCOL_PER_DEV0 0x04 | ||
| 2923 | #define DST_MODE_SHIFT 0x04 | ||
| 2924 | #define AHD_TIMER_MAX_US 0x18ffe7 | 2612 | #define AHD_TIMER_MAX_US 0x18ffe7 |
| 2925 | #define AHD_TIMER_MAX_TICKS 0xffff | 2613 | #define AHD_TIMER_MAX_TICKS 0xffff |
| 2926 | #define AHD_SENSE_BUFSIZE 0x100 | 2614 | #define AHD_SENSE_BUFSIZE 0x100 |
| @@ -2955,32 +2643,43 @@ ahd_reg_print_t ahd_scb_disconnected_lists_print; | |||
| 2955 | #define LUNLEN_SINGLE_LEVEL_LUN 0x0f | 2643 | #define LUNLEN_SINGLE_LEVEL_LUN 0x0f |
| 2956 | #define NVRAM_SCB_OFFSET 0x2c | 2644 | #define NVRAM_SCB_OFFSET 0x2c |
| 2957 | #define STATUS_PKT_SENSE 0xff | 2645 | #define STATUS_PKT_SENSE 0xff |
| 2646 | #define CMD_GROUP_CODE_SHIFT 0x05 | ||
| 2958 | #define MAX_OFFSET_PACED_BUG 0x7f | 2647 | #define MAX_OFFSET_PACED_BUG 0x7f |
| 2959 | #define STIMESEL_BUG_ADJ 0x08 | 2648 | #define STIMESEL_BUG_ADJ 0x08 |
| 2649 | #define STIMESEL_MIN 0x18 | ||
| 2650 | #define STIMESEL_SHIFT 0x03 | ||
| 2960 | #define CCSGRAM_MAXSEGS 0x10 | 2651 | #define CCSGRAM_MAXSEGS 0x10 |
| 2652 | #define INVALID_ADDR 0x80 | ||
| 2961 | #define SEEOP_ERAL_ADDR 0x80 | 2653 | #define SEEOP_ERAL_ADDR 0x80 |
| 2962 | #define AHD_SLEWRATE_DEF_REVB 0x08 | 2654 | #define AHD_SLEWRATE_DEF_REVB 0x08 |
| 2963 | #define AHD_PRECOMP_CUTBACK_17 0x04 | 2655 | #define AHD_PRECOMP_CUTBACK_17 0x04 |
| 2656 | #define AHD_PRECOMP_MASK 0x07 | ||
| 2964 | #define SRC_MODE_SHIFT 0x00 | 2657 | #define SRC_MODE_SHIFT 0x00 |
| 2965 | #define PKT_OVERRUN_BUFSIZE 0x200 | 2658 | #define PKT_OVERRUN_BUFSIZE 0x200 |
| 2966 | #define SCB_TRANSFER_SIZE_1BYTE_LUN 0x30 | 2659 | #define SCB_TRANSFER_SIZE_1BYTE_LUN 0x30 |
| 2660 | #define TARGET_DATA_IN 0x01 | ||
| 2967 | #define HOST_MSG 0xff | 2661 | #define HOST_MSG 0xff |
| 2968 | #define MAX_OFFSET 0xfe | 2662 | #define MAX_OFFSET 0xfe |
| 2969 | #define BUS_16_BIT 0x01 | 2663 | #define BUS_16_BIT 0x01 |
| 2664 | #define CCSCBADDR_MAX 0x80 | ||
| 2665 | #define NUMDSPS 0x14 | ||
| 2666 | #define SEEOP_EWEN_ADDR 0xc0 | ||
| 2667 | #define AHD_ANNEXCOL_PER_DEV0 0x04 | ||
| 2668 | #define DST_MODE_SHIFT 0x04 | ||
| 2970 | 2669 | ||
| 2971 | 2670 | ||
| 2972 | /* Downloaded Constant Definitions */ | 2671 | /* Downloaded Constant Definitions */ |
| 2973 | #define SG_SIZEOF 0x04 | ||
| 2974 | #define SG_PREFETCH_ALIGN_MASK 0x02 | ||
| 2975 | #define SG_PREFETCH_CNT_LIMIT 0x01 | ||
| 2976 | #define CACHELINE_MASK 0x07 | 2672 | #define CACHELINE_MASK 0x07 |
| 2977 | #define SCB_TRANSFER_SIZE 0x06 | 2673 | #define SCB_TRANSFER_SIZE 0x06 |
| 2978 | #define PKT_OVERRUN_BUFOFFSET 0x05 | 2674 | #define PKT_OVERRUN_BUFOFFSET 0x05 |
| 2675 | #define SG_SIZEOF 0x04 | ||
| 2979 | #define SG_PREFETCH_ADDR_MASK 0x03 | 2676 | #define SG_PREFETCH_ADDR_MASK 0x03 |
| 2677 | #define SG_PREFETCH_ALIGN_MASK 0x02 | ||
| 2678 | #define SG_PREFETCH_CNT_LIMIT 0x01 | ||
| 2980 | #define SG_PREFETCH_CNT 0x00 | 2679 | #define SG_PREFETCH_CNT 0x00 |
| 2981 | #define DOWNLOAD_CONST_COUNT 0x08 | 2680 | #define DOWNLOAD_CONST_COUNT 0x08 |
| 2982 | 2681 | ||
| 2983 | 2682 | ||
| 2984 | /* Exported Labels */ | 2683 | /* Exported Labels */ |
| 2985 | #define LABEL_timer_isr 0x28b | ||
| 2986 | #define LABEL_seq_isr 0x28f | 2684 | #define LABEL_seq_isr 0x28f |
| 2685 | #define LABEL_timer_isr 0x28b | ||
diff --git a/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped b/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped index c4c8a96bf5a3..f5ea715d6ac3 100644 --- a/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped +++ b/drivers/scsi/aic7xxx/aic79xx_reg_print.c_shipped | |||
| @@ -8,18 +8,6 @@ | |||
| 8 | 8 | ||
| 9 | #include "aic79xx_osm.h" | 9 | #include "aic79xx_osm.h" |
| 10 | 10 | ||
| 11 | static const ahd_reg_parse_entry_t MODE_PTR_parse_table[] = { | ||
| 12 | { "SRC_MODE", 0x07, 0x07 }, | ||
| 13 | { "DST_MODE", 0x70, 0x70 } | ||
| 14 | }; | ||
| 15 | |||
| 16 | int | ||
| 17 | ahd_mode_ptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 18 | { | ||
| 19 | return (ahd_print_register(MODE_PTR_parse_table, 2, "MODE_PTR", | ||
| 20 | 0x00, regvalue, cur_col, wrap)); | ||
| 21 | } | ||
| 22 | |||
| 23 | static const ahd_reg_parse_entry_t INTSTAT_parse_table[] = { | 11 | static const ahd_reg_parse_entry_t INTSTAT_parse_table[] = { |
| 24 | { "SPLTINT", 0x01, 0x01 }, | 12 | { "SPLTINT", 0x01, 0x01 }, |
| 25 | { "CMDCMPLT", 0x02, 0x02 }, | 13 | { "CMDCMPLT", 0x02, 0x02 }, |
| @@ -39,110 +27,6 @@ ahd_intstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 39 | 0x01, regvalue, cur_col, wrap)); | 27 | 0x01, regvalue, cur_col, wrap)); |
| 40 | } | 28 | } |
| 41 | 29 | ||
| 42 | static const ahd_reg_parse_entry_t SEQINTCODE_parse_table[] = { | ||
| 43 | { "NO_SEQINT", 0x00, 0xff }, | ||
| 44 | { "BAD_PHASE", 0x01, 0xff }, | ||
| 45 | { "SEND_REJECT", 0x02, 0xff }, | ||
| 46 | { "PROTO_VIOLATION", 0x03, 0xff }, | ||
| 47 | { "NO_MATCH", 0x04, 0xff }, | ||
| 48 | { "IGN_WIDE_RES", 0x05, 0xff }, | ||
| 49 | { "PDATA_REINIT", 0x06, 0xff }, | ||
| 50 | { "HOST_MSG_LOOP", 0x07, 0xff }, | ||
| 51 | { "BAD_STATUS", 0x08, 0xff }, | ||
| 52 | { "DATA_OVERRUN", 0x09, 0xff }, | ||
| 53 | { "MKMSG_FAILED", 0x0a, 0xff }, | ||
| 54 | { "MISSED_BUSFREE", 0x0b, 0xff }, | ||
| 55 | { "DUMP_CARD_STATE", 0x0c, 0xff }, | ||
| 56 | { "ILLEGAL_PHASE", 0x0d, 0xff }, | ||
| 57 | { "INVALID_SEQINT", 0x0e, 0xff }, | ||
| 58 | { "CFG4ISTAT_INTR", 0x0f, 0xff }, | ||
| 59 | { "STATUS_OVERRUN", 0x10, 0xff }, | ||
| 60 | { "CFG4OVERRUN", 0x11, 0xff }, | ||
| 61 | { "ENTERING_NONPACK", 0x12, 0xff }, | ||
| 62 | { "TASKMGMT_FUNC_COMPLETE",0x13, 0xff }, | ||
| 63 | { "TASKMGMT_CMD_CMPLT_OKAY",0x14, 0xff }, | ||
| 64 | { "TRACEPOINT0", 0x15, 0xff }, | ||
| 65 | { "TRACEPOINT1", 0x16, 0xff }, | ||
| 66 | { "TRACEPOINT2", 0x17, 0xff }, | ||
| 67 | { "TRACEPOINT3", 0x18, 0xff }, | ||
| 68 | { "SAW_HWERR", 0x19, 0xff }, | ||
| 69 | { "BAD_SCB_STATUS", 0x1a, 0xff } | ||
| 70 | }; | ||
| 71 | |||
| 72 | int | ||
| 73 | ahd_seqintcode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 74 | { | ||
| 75 | return (ahd_print_register(SEQINTCODE_parse_table, 27, "SEQINTCODE", | ||
| 76 | 0x02, regvalue, cur_col, wrap)); | ||
| 77 | } | ||
| 78 | |||
| 79 | static const ahd_reg_parse_entry_t CLRINT_parse_table[] = { | ||
| 80 | { "CLRSPLTINT", 0x01, 0x01 }, | ||
| 81 | { "CLRCMDINT", 0x02, 0x02 }, | ||
| 82 | { "CLRSEQINT", 0x04, 0x04 }, | ||
| 83 | { "CLRSCSIINT", 0x08, 0x08 }, | ||
| 84 | { "CLRPCIINT", 0x10, 0x10 }, | ||
| 85 | { "CLRSWTMINT", 0x20, 0x20 }, | ||
| 86 | { "CLRBRKADRINT", 0x40, 0x40 }, | ||
| 87 | { "CLRHWERRINT", 0x80, 0x80 } | ||
| 88 | }; | ||
| 89 | |||
| 90 | int | ||
| 91 | ahd_clrint_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 92 | { | ||
| 93 | return (ahd_print_register(CLRINT_parse_table, 8, "CLRINT", | ||
| 94 | 0x03, regvalue, cur_col, wrap)); | ||
| 95 | } | ||
| 96 | |||
| 97 | static const ahd_reg_parse_entry_t ERROR_parse_table[] = { | ||
| 98 | { "DSCTMOUT", 0x02, 0x02 }, | ||
| 99 | { "ILLOPCODE", 0x04, 0x04 }, | ||
| 100 | { "SQPARERR", 0x08, 0x08 }, | ||
| 101 | { "DPARERR", 0x10, 0x10 }, | ||
| 102 | { "MPARERR", 0x20, 0x20 }, | ||
| 103 | { "CIOACCESFAIL", 0x40, 0x40 }, | ||
| 104 | { "CIOPARERR", 0x80, 0x80 } | ||
| 105 | }; | ||
| 106 | |||
| 107 | int | ||
| 108 | ahd_error_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 109 | { | ||
| 110 | return (ahd_print_register(ERROR_parse_table, 7, "ERROR", | ||
| 111 | 0x04, regvalue, cur_col, wrap)); | ||
| 112 | } | ||
| 113 | |||
| 114 | static const ahd_reg_parse_entry_t HCNTRL_parse_table[] = { | ||
| 115 | { "CHIPRST", 0x01, 0x01 }, | ||
| 116 | { "CHIPRSTACK", 0x01, 0x01 }, | ||
| 117 | { "INTEN", 0x02, 0x02 }, | ||
| 118 | { "PAUSE", 0x04, 0x04 }, | ||
| 119 | { "SWTIMER_START_B", 0x08, 0x08 }, | ||
| 120 | { "SWINT", 0x10, 0x10 }, | ||
| 121 | { "POWRDN", 0x40, 0x40 }, | ||
| 122 | { "SEQ_RESET", 0x80, 0x80 } | ||
| 123 | }; | ||
| 124 | |||
| 125 | int | ||
| 126 | ahd_hcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 127 | { | ||
| 128 | return (ahd_print_register(HCNTRL_parse_table, 8, "HCNTRL", | ||
| 129 | 0x05, regvalue, cur_col, wrap)); | ||
| 130 | } | ||
| 131 | |||
| 132 | int | ||
| 133 | ahd_hnscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 134 | { | ||
| 135 | return (ahd_print_register(NULL, 0, "HNSCB_QOFF", | ||
| 136 | 0x06, regvalue, cur_col, wrap)); | ||
| 137 | } | ||
| 138 | |||
| 139 | int | ||
| 140 | ahd_hescb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 141 | { | ||
| 142 | return (ahd_print_register(NULL, 0, "HESCB_QOFF", | ||
| 143 | 0x08, regvalue, cur_col, wrap)); | ||
| 144 | } | ||
| 145 | |||
| 146 | static const ahd_reg_parse_entry_t HS_MAILBOX_parse_table[] = { | 30 | static const ahd_reg_parse_entry_t HS_MAILBOX_parse_table[] = { |
| 147 | { "ENINT_COALESCE", 0x40, 0x40 }, | 31 | { "ENINT_COALESCE", 0x40, 0x40 }, |
| 148 | { "HOST_TQINPOS", 0x80, 0x80 } | 32 | { "HOST_TQINPOS", 0x80, 0x80 } |
| @@ -170,77 +54,6 @@ ahd_seqintstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 170 | 0x0c, regvalue, cur_col, wrap)); | 54 | 0x0c, regvalue, cur_col, wrap)); |
| 171 | } | 55 | } |
| 172 | 56 | ||
| 173 | static const ahd_reg_parse_entry_t CLRSEQINTSTAT_parse_table[] = { | ||
| 174 | { "CLRSEQ_SPLTINT", 0x01, 0x01 }, | ||
| 175 | { "CLRSEQ_PCIINT", 0x02, 0x02 }, | ||
| 176 | { "CLRSEQ_SCSIINT", 0x04, 0x04 }, | ||
| 177 | { "CLRSEQ_SEQINT", 0x08, 0x08 }, | ||
| 178 | { "CLRSEQ_SWTMRTO", 0x10, 0x10 } | ||
| 179 | }; | ||
| 180 | |||
| 181 | int | ||
| 182 | ahd_clrseqintstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 183 | { | ||
| 184 | return (ahd_print_register(CLRSEQINTSTAT_parse_table, 5, "CLRSEQINTSTAT", | ||
| 185 | 0x0c, regvalue, cur_col, wrap)); | ||
| 186 | } | ||
| 187 | |||
| 188 | int | ||
| 189 | ahd_swtimer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 190 | { | ||
| 191 | return (ahd_print_register(NULL, 0, "SWTIMER", | ||
| 192 | 0x0e, regvalue, cur_col, wrap)); | ||
| 193 | } | ||
| 194 | |||
| 195 | int | ||
| 196 | ahd_snscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 197 | { | ||
| 198 | return (ahd_print_register(NULL, 0, "SNSCB_QOFF", | ||
| 199 | 0x10, regvalue, cur_col, wrap)); | ||
| 200 | } | ||
| 201 | |||
| 202 | int | ||
| 203 | ahd_sescb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 204 | { | ||
| 205 | return (ahd_print_register(NULL, 0, "SESCB_QOFF", | ||
| 206 | 0x12, regvalue, cur_col, wrap)); | ||
| 207 | } | ||
| 208 | |||
| 209 | int | ||
| 210 | ahd_sdscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 211 | { | ||
| 212 | return (ahd_print_register(NULL, 0, "SDSCB_QOFF", | ||
| 213 | 0x14, regvalue, cur_col, wrap)); | ||
| 214 | } | ||
| 215 | |||
| 216 | static const ahd_reg_parse_entry_t QOFF_CTLSTA_parse_table[] = { | ||
| 217 | { "SCB_QSIZE_4", 0x00, 0x0f }, | ||
| 218 | { "SCB_QSIZE_8", 0x01, 0x0f }, | ||
| 219 | { "SCB_QSIZE_16", 0x02, 0x0f }, | ||
| 220 | { "SCB_QSIZE_32", 0x03, 0x0f }, | ||
| 221 | { "SCB_QSIZE_64", 0x04, 0x0f }, | ||
| 222 | { "SCB_QSIZE_128", 0x05, 0x0f }, | ||
| 223 | { "SCB_QSIZE_256", 0x06, 0x0f }, | ||
| 224 | { "SCB_QSIZE_512", 0x07, 0x0f }, | ||
| 225 | { "SCB_QSIZE_1024", 0x08, 0x0f }, | ||
| 226 | { "SCB_QSIZE_2048", 0x09, 0x0f }, | ||
| 227 | { "SCB_QSIZE_4096", 0x0a, 0x0f }, | ||
| 228 | { "SCB_QSIZE_8192", 0x0b, 0x0f }, | ||
| 229 | { "SCB_QSIZE_16384", 0x0c, 0x0f }, | ||
| 230 | { "SCB_QSIZE", 0x0f, 0x0f }, | ||
| 231 | { "HS_MAILBOX_ACT", 0x10, 0x10 }, | ||
| 232 | { "SDSCB_ROLLOVR", 0x20, 0x20 }, | ||
| 233 | { "NEW_SCB_AVAIL", 0x40, 0x40 }, | ||
| 234 | { "EMPTY_SCB_AVAIL", 0x80, 0x80 } | ||
| 235 | }; | ||
| 236 | |||
| 237 | int | ||
| 238 | ahd_qoff_ctlsta_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 239 | { | ||
| 240 | return (ahd_print_register(QOFF_CTLSTA_parse_table, 18, "QOFF_CTLSTA", | ||
| 241 | 0x16, regvalue, cur_col, wrap)); | ||
| 242 | } | ||
| 243 | |||
| 244 | static const ahd_reg_parse_entry_t INTCTL_parse_table[] = { | 57 | static const ahd_reg_parse_entry_t INTCTL_parse_table[] = { |
| 245 | { "SPLTINTEN", 0x01, 0x01 }, | 58 | { "SPLTINTEN", 0x01, 0x01 }, |
| 246 | { "SEQINTEN", 0x02, 0x02 }, | 59 | { "SEQINTEN", 0x02, 0x02 }, |
| @@ -280,22 +93,6 @@ ahd_dfcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 280 | 0x19, regvalue, cur_col, wrap)); | 93 | 0x19, regvalue, cur_col, wrap)); |
| 281 | } | 94 | } |
| 282 | 95 | ||
| 283 | static const ahd_reg_parse_entry_t DSCOMMAND0_parse_table[] = { | ||
| 284 | { "CIOPARCKEN", 0x01, 0x01 }, | ||
| 285 | { "DISABLE_TWATE", 0x02, 0x02 }, | ||
| 286 | { "EXTREQLCK", 0x10, 0x10 }, | ||
| 287 | { "MPARCKEN", 0x20, 0x20 }, | ||
| 288 | { "DPARCKEN", 0x40, 0x40 }, | ||
| 289 | { "CACHETHEN", 0x80, 0x80 } | ||
| 290 | }; | ||
| 291 | |||
| 292 | int | ||
| 293 | ahd_dscommand0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 294 | { | ||
| 295 | return (ahd_print_register(DSCOMMAND0_parse_table, 6, "DSCOMMAND0", | ||
| 296 | 0x19, regvalue, cur_col, wrap)); | ||
| 297 | } | ||
| 298 | |||
| 299 | static const ahd_reg_parse_entry_t DFSTATUS_parse_table[] = { | 96 | static const ahd_reg_parse_entry_t DFSTATUS_parse_table[] = { |
| 300 | { "FIFOEMP", 0x01, 0x01 }, | 97 | { "FIFOEMP", 0x01, 0x01 }, |
| 301 | { "FIFOFULL", 0x02, 0x02 }, | 98 | { "FIFOFULL", 0x02, 0x02 }, |
| @@ -327,146 +124,6 @@ ahd_sg_cache_shadow_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 327 | 0x1b, regvalue, cur_col, wrap)); | 124 | 0x1b, regvalue, cur_col, wrap)); |
| 328 | } | 125 | } |
| 329 | 126 | ||
| 330 | static const ahd_reg_parse_entry_t SG_CACHE_PRE_parse_table[] = { | ||
| 331 | { "LAST_SEG", 0x02, 0x02 }, | ||
| 332 | { "ODD_SEG", 0x04, 0x04 }, | ||
| 333 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
| 334 | }; | ||
| 335 | |||
| 336 | int | ||
| 337 | ahd_sg_cache_pre_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 338 | { | ||
| 339 | return (ahd_print_register(SG_CACHE_PRE_parse_table, 3, "SG_CACHE_PRE", | ||
| 340 | 0x1b, regvalue, cur_col, wrap)); | ||
| 341 | } | ||
| 342 | |||
| 343 | int | ||
| 344 | ahd_lqin_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 345 | { | ||
| 346 | return (ahd_print_register(NULL, 0, "LQIN", | ||
| 347 | 0x20, regvalue, cur_col, wrap)); | ||
| 348 | } | ||
| 349 | |||
| 350 | int | ||
| 351 | ahd_lunptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 352 | { | ||
| 353 | return (ahd_print_register(NULL, 0, "LUNPTR", | ||
| 354 | 0x22, regvalue, cur_col, wrap)); | ||
| 355 | } | ||
| 356 | |||
| 357 | int | ||
| 358 | ahd_cmdlenptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 359 | { | ||
| 360 | return (ahd_print_register(NULL, 0, "CMDLENPTR", | ||
| 361 | 0x25, regvalue, cur_col, wrap)); | ||
| 362 | } | ||
| 363 | |||
| 364 | int | ||
| 365 | ahd_attrptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 366 | { | ||
| 367 | return (ahd_print_register(NULL, 0, "ATTRPTR", | ||
| 368 | 0x26, regvalue, cur_col, wrap)); | ||
| 369 | } | ||
| 370 | |||
| 371 | int | ||
| 372 | ahd_flagptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 373 | { | ||
| 374 | return (ahd_print_register(NULL, 0, "FLAGPTR", | ||
| 375 | 0x27, regvalue, cur_col, wrap)); | ||
| 376 | } | ||
| 377 | |||
| 378 | int | ||
| 379 | ahd_cmdptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 380 | { | ||
| 381 | return (ahd_print_register(NULL, 0, "CMDPTR", | ||
| 382 | 0x28, regvalue, cur_col, wrap)); | ||
| 383 | } | ||
| 384 | |||
| 385 | int | ||
| 386 | ahd_qnextptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 387 | { | ||
| 388 | return (ahd_print_register(NULL, 0, "QNEXTPTR", | ||
| 389 | 0x29, regvalue, cur_col, wrap)); | ||
| 390 | } | ||
| 391 | |||
| 392 | int | ||
| 393 | ahd_abrtbyteptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 394 | { | ||
| 395 | return (ahd_print_register(NULL, 0, "ABRTBYTEPTR", | ||
| 396 | 0x2b, regvalue, cur_col, wrap)); | ||
| 397 | } | ||
| 398 | |||
| 399 | int | ||
| 400 | ahd_abrtbitptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 401 | { | ||
| 402 | return (ahd_print_register(NULL, 0, "ABRTBITPTR", | ||
| 403 | 0x2c, regvalue, cur_col, wrap)); | ||
| 404 | } | ||
| 405 | |||
| 406 | static const ahd_reg_parse_entry_t LUNLEN_parse_table[] = { | ||
| 407 | { "ILUNLEN", 0x0f, 0x0f }, | ||
| 408 | { "TLUNLEN", 0xf0, 0xf0 } | ||
| 409 | }; | ||
| 410 | |||
| 411 | int | ||
| 412 | ahd_lunlen_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 413 | { | ||
| 414 | return (ahd_print_register(LUNLEN_parse_table, 2, "LUNLEN", | ||
| 415 | 0x30, regvalue, cur_col, wrap)); | ||
| 416 | } | ||
| 417 | |||
| 418 | int | ||
| 419 | ahd_cdblimit_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 420 | { | ||
| 421 | return (ahd_print_register(NULL, 0, "CDBLIMIT", | ||
| 422 | 0x31, regvalue, cur_col, wrap)); | ||
| 423 | } | ||
| 424 | |||
| 425 | int | ||
| 426 | ahd_maxcmd_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 427 | { | ||
| 428 | return (ahd_print_register(NULL, 0, "MAXCMD", | ||
| 429 | 0x32, regvalue, cur_col, wrap)); | ||
| 430 | } | ||
| 431 | |||
| 432 | int | ||
| 433 | ahd_maxcmdcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 434 | { | ||
| 435 | return (ahd_print_register(NULL, 0, "MAXCMDCNT", | ||
| 436 | 0x33, regvalue, cur_col, wrap)); | ||
| 437 | } | ||
| 438 | |||
| 439 | static const ahd_reg_parse_entry_t LQCTL1_parse_table[] = { | ||
| 440 | { "ABORTPENDING", 0x01, 0x01 }, | ||
| 441 | { "SINGLECMD", 0x02, 0x02 }, | ||
| 442 | { "PCI2PCI", 0x04, 0x04 } | ||
| 443 | }; | ||
| 444 | |||
| 445 | int | ||
| 446 | ahd_lqctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 447 | { | ||
| 448 | return (ahd_print_register(LQCTL1_parse_table, 3, "LQCTL1", | ||
| 449 | 0x38, regvalue, cur_col, wrap)); | ||
| 450 | } | ||
| 451 | |||
| 452 | static const ahd_reg_parse_entry_t LQCTL2_parse_table[] = { | ||
| 453 | { "LQOPAUSE", 0x01, 0x01 }, | ||
| 454 | { "LQOTOIDLE", 0x02, 0x02 }, | ||
| 455 | { "LQOCONTINUE", 0x04, 0x04 }, | ||
| 456 | { "LQORETRY", 0x08, 0x08 }, | ||
| 457 | { "LQIPAUSE", 0x10, 0x10 }, | ||
| 458 | { "LQITOIDLE", 0x20, 0x20 }, | ||
| 459 | { "LQICONTINUE", 0x40, 0x40 }, | ||
| 460 | { "LQIRETRY", 0x80, 0x80 } | ||
| 461 | }; | ||
| 462 | |||
| 463 | int | ||
| 464 | ahd_lqctl2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 465 | { | ||
| 466 | return (ahd_print_register(LQCTL2_parse_table, 8, "LQCTL2", | ||
| 467 | 0x39, regvalue, cur_col, wrap)); | ||
| 468 | } | ||
| 469 | |||
| 470 | static const ahd_reg_parse_entry_t SCSISEQ0_parse_table[] = { | 127 | static const ahd_reg_parse_entry_t SCSISEQ0_parse_table[] = { |
| 471 | { "SCSIRSTO", 0x01, 0x01 }, | 128 | { "SCSIRSTO", 0x01, 0x01 }, |
| 472 | { "FORCEBUSFREE", 0x10, 0x10 }, | 129 | { "FORCEBUSFREE", 0x10, 0x10 }, |
| @@ -498,37 +155,6 @@ ahd_scsiseq1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 498 | 0x3b, regvalue, cur_col, wrap)); | 155 | 0x3b, regvalue, cur_col, wrap)); |
| 499 | } | 156 | } |
| 500 | 157 | ||
| 501 | static const ahd_reg_parse_entry_t SXFRCTL0_parse_table[] = { | ||
| 502 | { "SPIOEN", 0x08, 0x08 }, | ||
| 503 | { "BIOSCANCELEN", 0x10, 0x10 }, | ||
| 504 | { "DFPEXP", 0x40, 0x40 }, | ||
| 505 | { "DFON", 0x80, 0x80 } | ||
| 506 | }; | ||
| 507 | |||
| 508 | int | ||
| 509 | ahd_sxfrctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 510 | { | ||
| 511 | return (ahd_print_register(SXFRCTL0_parse_table, 4, "SXFRCTL0", | ||
| 512 | 0x3c, regvalue, cur_col, wrap)); | ||
| 513 | } | ||
| 514 | |||
| 515 | static const ahd_reg_parse_entry_t SXFRCTL1_parse_table[] = { | ||
| 516 | { "STPWEN", 0x01, 0x01 }, | ||
| 517 | { "ACTNEGEN", 0x02, 0x02 }, | ||
| 518 | { "ENSTIMER", 0x04, 0x04 }, | ||
| 519 | { "STIMESEL", 0x18, 0x18 }, | ||
| 520 | { "ENSPCHK", 0x20, 0x20 }, | ||
| 521 | { "ENSACHK", 0x40, 0x40 }, | ||
| 522 | { "BITBUCKET", 0x80, 0x80 } | ||
| 523 | }; | ||
| 524 | |||
| 525 | int | ||
| 526 | ahd_sxfrctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 527 | { | ||
| 528 | return (ahd_print_register(SXFRCTL1_parse_table, 7, "SXFRCTL1", | ||
| 529 | 0x3d, regvalue, cur_col, wrap)); | ||
| 530 | } | ||
| 531 | |||
| 532 | static const ahd_reg_parse_entry_t DFFSTAT_parse_table[] = { | 158 | static const ahd_reg_parse_entry_t DFFSTAT_parse_table[] = { |
| 533 | { "CURRFIFO_0", 0x00, 0x03 }, | 159 | { "CURRFIFO_0", 0x00, 0x03 }, |
| 534 | { "CURRFIFO_1", 0x01, 0x03 }, | 160 | { "CURRFIFO_1", 0x01, 0x03 }, |
| @@ -545,40 +171,6 @@ ahd_dffstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 545 | 0x3f, regvalue, cur_col, wrap)); | 171 | 0x3f, regvalue, cur_col, wrap)); |
| 546 | } | 172 | } |
| 547 | 173 | ||
| 548 | int | ||
| 549 | ahd_multargid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 550 | { | ||
| 551 | return (ahd_print_register(NULL, 0, "MULTARGID", | ||
| 552 | 0x40, regvalue, cur_col, wrap)); | ||
| 553 | } | ||
| 554 | |||
| 555 | static const ahd_reg_parse_entry_t SCSISIGO_parse_table[] = { | ||
| 556 | { "P_DATAOUT", 0x00, 0xe0 }, | ||
| 557 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | ||
| 558 | { "P_DATAIN", 0x40, 0xe0 }, | ||
| 559 | { "P_DATAIN_DT", 0x60, 0xe0 }, | ||
| 560 | { "P_COMMAND", 0x80, 0xe0 }, | ||
| 561 | { "P_MESGOUT", 0xa0, 0xe0 }, | ||
| 562 | { "P_STATUS", 0xc0, 0xe0 }, | ||
| 563 | { "P_MESGIN", 0xe0, 0xe0 }, | ||
| 564 | { "ACKO", 0x01, 0x01 }, | ||
| 565 | { "REQO", 0x02, 0x02 }, | ||
| 566 | { "BSYO", 0x04, 0x04 }, | ||
| 567 | { "SELO", 0x08, 0x08 }, | ||
| 568 | { "ATNO", 0x10, 0x10 }, | ||
| 569 | { "MSGO", 0x20, 0x20 }, | ||
| 570 | { "IOO", 0x40, 0x40 }, | ||
| 571 | { "CDO", 0x80, 0x80 }, | ||
| 572 | { "PHASE_MASK", 0xe0, 0xe0 } | ||
| 573 | }; | ||
| 574 | |||
| 575 | int | ||
| 576 | ahd_scsisigo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 577 | { | ||
| 578 | return (ahd_print_register(SCSISIGO_parse_table, 17, "SCSISIGO", | ||
| 579 | 0x40, regvalue, cur_col, wrap)); | ||
| 580 | } | ||
| 581 | |||
| 582 | static const ahd_reg_parse_entry_t SCSISIGI_parse_table[] = { | 174 | static const ahd_reg_parse_entry_t SCSISIGI_parse_table[] = { |
| 583 | { "P_DATAOUT", 0x00, 0xe0 }, | 175 | { "P_DATAOUT", 0x00, 0xe0 }, |
| 584 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | 176 | { "P_DATAOUT_DT", 0x20, 0xe0 }, |
| @@ -624,31 +216,12 @@ ahd_scsiphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 624 | } | 216 | } |
| 625 | 217 | ||
| 626 | int | 218 | int |
| 627 | ahd_scsidat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 628 | { | ||
| 629 | return (ahd_print_register(NULL, 0, "SCSIDAT", | ||
| 630 | 0x44, regvalue, cur_col, wrap)); | ||
| 631 | } | ||
| 632 | |||
| 633 | int | ||
| 634 | ahd_scsibus_print(u_int regvalue, u_int *cur_col, u_int wrap) | 219 | ahd_scsibus_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 635 | { | 220 | { |
| 636 | return (ahd_print_register(NULL, 0, "SCSIBUS", | 221 | return (ahd_print_register(NULL, 0, "SCSIBUS", |
| 637 | 0x46, regvalue, cur_col, wrap)); | 222 | 0x46, regvalue, cur_col, wrap)); |
| 638 | } | 223 | } |
| 639 | 224 | ||
| 640 | static const ahd_reg_parse_entry_t TARGIDIN_parse_table[] = { | ||
| 641 | { "TARGID", 0x0f, 0x0f }, | ||
| 642 | { "CLKOUT", 0x80, 0x80 } | ||
| 643 | }; | ||
| 644 | |||
| 645 | int | ||
| 646 | ahd_targidin_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 647 | { | ||
| 648 | return (ahd_print_register(TARGIDIN_parse_table, 2, "TARGIDIN", | ||
| 649 | 0x48, regvalue, cur_col, wrap)); | ||
| 650 | } | ||
| 651 | |||
| 652 | static const ahd_reg_parse_entry_t SELID_parse_table[] = { | 225 | static const ahd_reg_parse_entry_t SELID_parse_table[] = { |
| 653 | { "ONEBIT", 0x08, 0x08 }, | 226 | { "ONEBIT", 0x08, 0x08 }, |
| 654 | { "SELID_MASK", 0xf0, 0xf0 } | 227 | { "SELID_MASK", 0xf0, 0xf0 } |
| @@ -661,38 +234,6 @@ ahd_selid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 661 | 0x49, regvalue, cur_col, wrap)); | 234 | 0x49, regvalue, cur_col, wrap)); |
| 662 | } | 235 | } |
| 663 | 236 | ||
| 664 | static const ahd_reg_parse_entry_t OPTIONMODE_parse_table[] = { | ||
| 665 | { "AUTO_MSGOUT_DE", 0x02, 0x02 }, | ||
| 666 | { "ENDGFORMCHK", 0x04, 0x04 }, | ||
| 667 | { "BUSFREEREV", 0x10, 0x10 }, | ||
| 668 | { "BIASCANCTL", 0x20, 0x20 }, | ||
| 669 | { "AUTOACKEN", 0x40, 0x40 }, | ||
| 670 | { "BIOSCANCTL", 0x80, 0x80 }, | ||
| 671 | { "OPTIONMODE_DEFAULTS",0x02, 0x02 } | ||
| 672 | }; | ||
| 673 | |||
| 674 | int | ||
| 675 | ahd_optionmode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 676 | { | ||
| 677 | return (ahd_print_register(OPTIONMODE_parse_table, 7, "OPTIONMODE", | ||
| 678 | 0x4a, regvalue, cur_col, wrap)); | ||
| 679 | } | ||
| 680 | |||
| 681 | static const ahd_reg_parse_entry_t SBLKCTL_parse_table[] = { | ||
| 682 | { "SELWIDE", 0x02, 0x02 }, | ||
| 683 | { "ENAB20", 0x04, 0x04 }, | ||
| 684 | { "ENAB40", 0x08, 0x08 }, | ||
| 685 | { "DIAGLEDON", 0x40, 0x40 }, | ||
| 686 | { "DIAGLEDEN", 0x80, 0x80 } | ||
| 687 | }; | ||
| 688 | |||
| 689 | int | ||
| 690 | ahd_sblkctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 691 | { | ||
| 692 | return (ahd_print_register(SBLKCTL_parse_table, 5, "SBLKCTL", | ||
| 693 | 0x4a, regvalue, cur_col, wrap)); | ||
| 694 | } | ||
| 695 | |||
| 696 | static const ahd_reg_parse_entry_t SSTAT0_parse_table[] = { | 237 | static const ahd_reg_parse_entry_t SSTAT0_parse_table[] = { |
| 697 | { "ARBDO", 0x01, 0x01 }, | 238 | { "ARBDO", 0x01, 0x01 }, |
| 698 | { "SPIORDY", 0x02, 0x02 }, | 239 | { "SPIORDY", 0x02, 0x02 }, |
| @@ -728,23 +269,6 @@ ahd_simode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 728 | 0x4b, regvalue, cur_col, wrap)); | 269 | 0x4b, regvalue, cur_col, wrap)); |
| 729 | } | 270 | } |
| 730 | 271 | ||
| 731 | static const ahd_reg_parse_entry_t CLRSINT0_parse_table[] = { | ||
| 732 | { "CLRARBDO", 0x01, 0x01 }, | ||
| 733 | { "CLRSPIORDY", 0x02, 0x02 }, | ||
| 734 | { "CLROVERRUN", 0x04, 0x04 }, | ||
| 735 | { "CLRIOERR", 0x08, 0x08 }, | ||
| 736 | { "CLRSELINGO", 0x10, 0x10 }, | ||
| 737 | { "CLRSELDI", 0x20, 0x20 }, | ||
| 738 | { "CLRSELDO", 0x40, 0x40 } | ||
| 739 | }; | ||
| 740 | |||
| 741 | int | ||
| 742 | ahd_clrsint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 743 | { | ||
| 744 | return (ahd_print_register(CLRSINT0_parse_table, 7, "CLRSINT0", | ||
| 745 | 0x4b, regvalue, cur_col, wrap)); | ||
| 746 | } | ||
| 747 | |||
| 748 | static const ahd_reg_parse_entry_t SSTAT1_parse_table[] = { | 272 | static const ahd_reg_parse_entry_t SSTAT1_parse_table[] = { |
| 749 | { "REQINIT", 0x01, 0x01 }, | 273 | { "REQINIT", 0x01, 0x01 }, |
| 750 | { "STRB2FAST", 0x02, 0x02 }, | 274 | { "STRB2FAST", 0x02, 0x02 }, |
| @@ -763,23 +287,6 @@ ahd_sstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 763 | 0x4c, regvalue, cur_col, wrap)); | 287 | 0x4c, regvalue, cur_col, wrap)); |
| 764 | } | 288 | } |
| 765 | 289 | ||
| 766 | static const ahd_reg_parse_entry_t CLRSINT1_parse_table[] = { | ||
| 767 | { "CLRREQINIT", 0x01, 0x01 }, | ||
| 768 | { "CLRSTRB2FAST", 0x02, 0x02 }, | ||
| 769 | { "CLRSCSIPERR", 0x04, 0x04 }, | ||
| 770 | { "CLRBUSFREE", 0x08, 0x08 }, | ||
| 771 | { "CLRSCSIRSTI", 0x20, 0x20 }, | ||
| 772 | { "CLRATNO", 0x40, 0x40 }, | ||
| 773 | { "CLRSELTIMEO", 0x80, 0x80 } | ||
| 774 | }; | ||
| 775 | |||
| 776 | int | ||
| 777 | ahd_clrsint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 778 | { | ||
| 779 | return (ahd_print_register(CLRSINT1_parse_table, 7, "CLRSINT1", | ||
| 780 | 0x4c, regvalue, cur_col, wrap)); | ||
| 781 | } | ||
| 782 | |||
| 783 | static const ahd_reg_parse_entry_t SSTAT2_parse_table[] = { | 290 | static const ahd_reg_parse_entry_t SSTAT2_parse_table[] = { |
| 784 | { "BUSFREE_LQO", 0x40, 0xc0 }, | 291 | { "BUSFREE_LQO", 0x40, 0xc0 }, |
| 785 | { "BUSFREE_DFF0", 0x80, 0xc0 }, | 292 | { "BUSFREE_DFF0", 0x80, 0xc0 }, |
| @@ -800,20 +307,6 @@ ahd_sstat2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 800 | 0x4d, regvalue, cur_col, wrap)); | 307 | 0x4d, regvalue, cur_col, wrap)); |
| 801 | } | 308 | } |
| 802 | 309 | ||
| 803 | static const ahd_reg_parse_entry_t CLRSINT2_parse_table[] = { | ||
| 804 | { "CLRDMADONE", 0x01, 0x01 }, | ||
| 805 | { "CLRSDONE", 0x02, 0x02 }, | ||
| 806 | { "CLRWIDE_RES", 0x04, 0x04 }, | ||
| 807 | { "CLRNONPACKREQ", 0x20, 0x20 } | ||
| 808 | }; | ||
| 809 | |||
| 810 | int | ||
| 811 | ahd_clrsint2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 812 | { | ||
| 813 | return (ahd_print_register(CLRSINT2_parse_table, 4, "CLRSINT2", | ||
| 814 | 0x4d, regvalue, cur_col, wrap)); | ||
| 815 | } | ||
| 816 | |||
| 817 | static const ahd_reg_parse_entry_t PERRDIAG_parse_table[] = { | 310 | static const ahd_reg_parse_entry_t PERRDIAG_parse_table[] = { |
| 818 | { "DTERR", 0x01, 0x01 }, | 311 | { "DTERR", 0x01, 0x01 }, |
| 819 | { "DGFORMERR", 0x02, 0x02 }, | 312 | { "DGFORMERR", 0x02, 0x02 }, |
| @@ -833,26 +326,12 @@ ahd_perrdiag_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 833 | } | 326 | } |
| 834 | 327 | ||
| 835 | int | 328 | int |
| 836 | ahd_lqistate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 837 | { | ||
| 838 | return (ahd_print_register(NULL, 0, "LQISTATE", | ||
| 839 | 0x4e, regvalue, cur_col, wrap)); | ||
| 840 | } | ||
| 841 | |||
| 842 | int | ||
| 843 | ahd_soffcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | 329 | ahd_soffcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 844 | { | 330 | { |
| 845 | return (ahd_print_register(NULL, 0, "SOFFCNT", | 331 | return (ahd_print_register(NULL, 0, "SOFFCNT", |
| 846 | 0x4f, regvalue, cur_col, wrap)); | 332 | 0x4f, regvalue, cur_col, wrap)); |
| 847 | } | 333 | } |
| 848 | 334 | ||
| 849 | int | ||
| 850 | ahd_lqostate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 851 | { | ||
| 852 | return (ahd_print_register(NULL, 0, "LQOSTATE", | ||
| 853 | 0x4f, regvalue, cur_col, wrap)); | ||
| 854 | } | ||
| 855 | |||
| 856 | static const ahd_reg_parse_entry_t LQISTAT0_parse_table[] = { | 335 | static const ahd_reg_parse_entry_t LQISTAT0_parse_table[] = { |
| 857 | { "LQIATNCMD", 0x01, 0x01 }, | 336 | { "LQIATNCMD", 0x01, 0x01 }, |
| 858 | { "LQIATNLQ", 0x02, 0x02 }, | 337 | { "LQIATNLQ", 0x02, 0x02 }, |
| @@ -869,56 +348,6 @@ ahd_lqistat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 869 | 0x50, regvalue, cur_col, wrap)); | 348 | 0x50, regvalue, cur_col, wrap)); |
| 870 | } | 349 | } |
| 871 | 350 | ||
| 872 | static const ahd_reg_parse_entry_t LQIMODE0_parse_table[] = { | ||
| 873 | { "ENLQIATNCMD", 0x01, 0x01 }, | ||
| 874 | { "ENLQIATNLQ", 0x02, 0x02 }, | ||
| 875 | { "ENLQIBADLQT", 0x04, 0x04 }, | ||
| 876 | { "ENLQICRCT2", 0x08, 0x08 }, | ||
| 877 | { "ENLQICRCT1", 0x10, 0x10 }, | ||
| 878 | { "ENLQIATNQASK", 0x20, 0x20 } | ||
| 879 | }; | ||
| 880 | |||
| 881 | int | ||
| 882 | ahd_lqimode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 883 | { | ||
| 884 | return (ahd_print_register(LQIMODE0_parse_table, 6, "LQIMODE0", | ||
| 885 | 0x50, regvalue, cur_col, wrap)); | ||
| 886 | } | ||
| 887 | |||
| 888 | static const ahd_reg_parse_entry_t CLRLQIINT0_parse_table[] = { | ||
| 889 | { "CLRLQIATNCMD", 0x01, 0x01 }, | ||
| 890 | { "CLRLQIATNLQ", 0x02, 0x02 }, | ||
| 891 | { "CLRLQIBADLQT", 0x04, 0x04 }, | ||
| 892 | { "CLRLQICRCT2", 0x08, 0x08 }, | ||
| 893 | { "CLRLQICRCT1", 0x10, 0x10 }, | ||
| 894 | { "CLRLQIATNQAS", 0x20, 0x20 } | ||
| 895 | }; | ||
| 896 | |||
| 897 | int | ||
| 898 | ahd_clrlqiint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 899 | { | ||
| 900 | return (ahd_print_register(CLRLQIINT0_parse_table, 6, "CLRLQIINT0", | ||
| 901 | 0x50, regvalue, cur_col, wrap)); | ||
| 902 | } | ||
| 903 | |||
| 904 | static const ahd_reg_parse_entry_t LQIMODE1_parse_table[] = { | ||
| 905 | { "ENLQIOVERI_NLQ", 0x01, 0x01 }, | ||
| 906 | { "ENLQIOVERI_LQ", 0x02, 0x02 }, | ||
| 907 | { "ENLQIBADLQI", 0x04, 0x04 }, | ||
| 908 | { "ENLQICRCI_NLQ", 0x08, 0x08 }, | ||
| 909 | { "ENLQICRCI_LQ", 0x10, 0x10 }, | ||
| 910 | { "ENLIQABORT", 0x20, 0x20 }, | ||
| 911 | { "ENLQIPHASE_NLQ", 0x40, 0x40 }, | ||
| 912 | { "ENLQIPHASE_LQ", 0x80, 0x80 } | ||
| 913 | }; | ||
| 914 | |||
| 915 | int | ||
| 916 | ahd_lqimode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 917 | { | ||
| 918 | return (ahd_print_register(LQIMODE1_parse_table, 8, "LQIMODE1", | ||
| 919 | 0x51, regvalue, cur_col, wrap)); | ||
| 920 | } | ||
| 921 | |||
| 922 | static const ahd_reg_parse_entry_t LQISTAT1_parse_table[] = { | 351 | static const ahd_reg_parse_entry_t LQISTAT1_parse_table[] = { |
| 923 | { "LQIOVERI_NLQ", 0x01, 0x01 }, | 352 | { "LQIOVERI_NLQ", 0x01, 0x01 }, |
| 924 | { "LQIOVERI_LQ", 0x02, 0x02 }, | 353 | { "LQIOVERI_LQ", 0x02, 0x02 }, |
| @@ -937,24 +366,6 @@ ahd_lqistat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 937 | 0x51, regvalue, cur_col, wrap)); | 366 | 0x51, regvalue, cur_col, wrap)); |
| 938 | } | 367 | } |
| 939 | 368 | ||
| 940 | static const ahd_reg_parse_entry_t CLRLQIINT1_parse_table[] = { | ||
| 941 | { "CLRLQIOVERI_NLQ", 0x01, 0x01 }, | ||
| 942 | { "CLRLQIOVERI_LQ", 0x02, 0x02 }, | ||
| 943 | { "CLRLQIBADLQI", 0x04, 0x04 }, | ||
| 944 | { "CLRLQICRCI_NLQ", 0x08, 0x08 }, | ||
| 945 | { "CLRLQICRCI_LQ", 0x10, 0x10 }, | ||
| 946 | { "CLRLIQABORT", 0x20, 0x20 }, | ||
| 947 | { "CLRLQIPHASE_NLQ", 0x40, 0x40 }, | ||
| 948 | { "CLRLQIPHASE_LQ", 0x80, 0x80 } | ||
| 949 | }; | ||
| 950 | |||
| 951 | int | ||
| 952 | ahd_clrlqiint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 953 | { | ||
| 954 | return (ahd_print_register(CLRLQIINT1_parse_table, 8, "CLRLQIINT1", | ||
| 955 | 0x51, regvalue, cur_col, wrap)); | ||
| 956 | } | ||
| 957 | |||
| 958 | static const ahd_reg_parse_entry_t LQISTAT2_parse_table[] = { | 369 | static const ahd_reg_parse_entry_t LQISTAT2_parse_table[] = { |
| 959 | { "LQIGSAVAIL", 0x01, 0x01 }, | 370 | { "LQIGSAVAIL", 0x01, 0x01 }, |
| 960 | { "LQISTOPCMD", 0x02, 0x02 }, | 371 | { "LQISTOPCMD", 0x02, 0x02 }, |
| @@ -985,30 +396,6 @@ ahd_sstat3_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 985 | 0x53, regvalue, cur_col, wrap)); | 396 | 0x53, regvalue, cur_col, wrap)); |
| 986 | } | 397 | } |
| 987 | 398 | ||
| 988 | static const ahd_reg_parse_entry_t SIMODE3_parse_table[] = { | ||
| 989 | { "ENOSRAMPERR", 0x01, 0x01 }, | ||
| 990 | { "ENNTRAMPERR", 0x02, 0x02 } | ||
| 991 | }; | ||
| 992 | |||
| 993 | int | ||
| 994 | ahd_simode3_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 995 | { | ||
| 996 | return (ahd_print_register(SIMODE3_parse_table, 2, "SIMODE3", | ||
| 997 | 0x53, regvalue, cur_col, wrap)); | ||
| 998 | } | ||
| 999 | |||
| 1000 | static const ahd_reg_parse_entry_t CLRSINT3_parse_table[] = { | ||
| 1001 | { "CLROSRAMPERR", 0x01, 0x01 }, | ||
| 1002 | { "CLRNTRAMPERR", 0x02, 0x02 } | ||
| 1003 | }; | ||
| 1004 | |||
| 1005 | int | ||
| 1006 | ahd_clrsint3_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1007 | { | ||
| 1008 | return (ahd_print_register(CLRSINT3_parse_table, 2, "CLRSINT3", | ||
| 1009 | 0x53, regvalue, cur_col, wrap)); | ||
| 1010 | } | ||
| 1011 | |||
| 1012 | static const ahd_reg_parse_entry_t LQOSTAT0_parse_table[] = { | 399 | static const ahd_reg_parse_entry_t LQOSTAT0_parse_table[] = { |
| 1013 | { "LQOTCRC", 0x01, 0x01 }, | 400 | { "LQOTCRC", 0x01, 0x01 }, |
| 1014 | { "LQOATNPKT", 0x02, 0x02 }, | 401 | { "LQOATNPKT", 0x02, 0x02 }, |
| @@ -1024,51 +411,6 @@ ahd_lqostat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1024 | 0x54, regvalue, cur_col, wrap)); | 411 | 0x54, regvalue, cur_col, wrap)); |
| 1025 | } | 412 | } |
| 1026 | 413 | ||
| 1027 | static const ahd_reg_parse_entry_t CLRLQOINT0_parse_table[] = { | ||
| 1028 | { "CLRLQOTCRC", 0x01, 0x01 }, | ||
| 1029 | { "CLRLQOATNPKT", 0x02, 0x02 }, | ||
| 1030 | { "CLRLQOATNLQ", 0x04, 0x04 }, | ||
| 1031 | { "CLRLQOSTOPT2", 0x08, 0x08 }, | ||
| 1032 | { "CLRLQOTARGSCBPERR", 0x10, 0x10 } | ||
| 1033 | }; | ||
| 1034 | |||
| 1035 | int | ||
| 1036 | ahd_clrlqoint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1037 | { | ||
| 1038 | return (ahd_print_register(CLRLQOINT0_parse_table, 5, "CLRLQOINT0", | ||
| 1039 | 0x54, regvalue, cur_col, wrap)); | ||
| 1040 | } | ||
| 1041 | |||
| 1042 | static const ahd_reg_parse_entry_t LQOMODE0_parse_table[] = { | ||
| 1043 | { "ENLQOTCRC", 0x01, 0x01 }, | ||
| 1044 | { "ENLQOATNPKT", 0x02, 0x02 }, | ||
| 1045 | { "ENLQOATNLQ", 0x04, 0x04 }, | ||
| 1046 | { "ENLQOSTOPT2", 0x08, 0x08 }, | ||
| 1047 | { "ENLQOTARGSCBPERR", 0x10, 0x10 } | ||
| 1048 | }; | ||
| 1049 | |||
| 1050 | int | ||
| 1051 | ahd_lqomode0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1052 | { | ||
| 1053 | return (ahd_print_register(LQOMODE0_parse_table, 5, "LQOMODE0", | ||
| 1054 | 0x54, regvalue, cur_col, wrap)); | ||
| 1055 | } | ||
| 1056 | |||
| 1057 | static const ahd_reg_parse_entry_t LQOMODE1_parse_table[] = { | ||
| 1058 | { "ENLQOPHACHGINPKT", 0x01, 0x01 }, | ||
| 1059 | { "ENLQOBUSFREE", 0x02, 0x02 }, | ||
| 1060 | { "ENLQOBADQAS", 0x04, 0x04 }, | ||
| 1061 | { "ENLQOSTOPI2", 0x08, 0x08 }, | ||
| 1062 | { "ENLQOINITSCBPERR", 0x10, 0x10 } | ||
| 1063 | }; | ||
| 1064 | |||
| 1065 | int | ||
| 1066 | ahd_lqomode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1067 | { | ||
| 1068 | return (ahd_print_register(LQOMODE1_parse_table, 5, "LQOMODE1", | ||
| 1069 | 0x55, regvalue, cur_col, wrap)); | ||
| 1070 | } | ||
| 1071 | |||
| 1072 | static const ahd_reg_parse_entry_t LQOSTAT1_parse_table[] = { | 414 | static const ahd_reg_parse_entry_t LQOSTAT1_parse_table[] = { |
| 1073 | { "LQOPHACHGINPKT", 0x01, 0x01 }, | 415 | { "LQOPHACHGINPKT", 0x01, 0x01 }, |
| 1074 | { "LQOBUSFREE", 0x02, 0x02 }, | 416 | { "LQOBUSFREE", 0x02, 0x02 }, |
| @@ -1084,21 +426,6 @@ ahd_lqostat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1084 | 0x55, regvalue, cur_col, wrap)); | 426 | 0x55, regvalue, cur_col, wrap)); |
| 1085 | } | 427 | } |
| 1086 | 428 | ||
| 1087 | static const ahd_reg_parse_entry_t CLRLQOINT1_parse_table[] = { | ||
| 1088 | { "CLRLQOPHACHGINPKT", 0x01, 0x01 }, | ||
| 1089 | { "CLRLQOBUSFREE", 0x02, 0x02 }, | ||
| 1090 | { "CLRLQOBADQAS", 0x04, 0x04 }, | ||
| 1091 | { "CLRLQOSTOPI2", 0x08, 0x08 }, | ||
| 1092 | { "CLRLQOINITSCBPERR", 0x10, 0x10 } | ||
| 1093 | }; | ||
| 1094 | |||
| 1095 | int | ||
| 1096 | ahd_clrlqoint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1097 | { | ||
| 1098 | return (ahd_print_register(CLRLQOINT1_parse_table, 5, "CLRLQOINT1", | ||
| 1099 | 0x55, regvalue, cur_col, wrap)); | ||
| 1100 | } | ||
| 1101 | |||
| 1102 | static const ahd_reg_parse_entry_t LQOSTAT2_parse_table[] = { | 429 | static const ahd_reg_parse_entry_t LQOSTAT2_parse_table[] = { |
| 1103 | { "LQOSTOP0", 0x01, 0x01 }, | 430 | { "LQOSTOP0", 0x01, 0x01 }, |
| 1104 | { "LQOPHACHGOUTPKT", 0x02, 0x02 }, | 431 | { "LQOPHACHGOUTPKT", 0x02, 0x02 }, |
| @@ -1113,13 +440,6 @@ ahd_lqostat2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1113 | 0x56, regvalue, cur_col, wrap)); | 440 | 0x56, regvalue, cur_col, wrap)); |
| 1114 | } | 441 | } |
| 1115 | 442 | ||
| 1116 | int | ||
| 1117 | ahd_os_space_cnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1118 | { | ||
| 1119 | return (ahd_print_register(NULL, 0, "OS_SPACE_CNT", | ||
| 1120 | 0x56, regvalue, cur_col, wrap)); | ||
| 1121 | } | ||
| 1122 | |||
| 1123 | static const ahd_reg_parse_entry_t SIMODE1_parse_table[] = { | 443 | static const ahd_reg_parse_entry_t SIMODE1_parse_table[] = { |
| 1124 | { "ENREQINIT", 0x01, 0x01 }, | 444 | { "ENREQINIT", 0x01, 0x01 }, |
| 1125 | { "ENSTRB2FAST", 0x02, 0x02 }, | 445 | { "ENSTRB2FAST", 0x02, 0x02 }, |
| @@ -1138,13 +458,6 @@ ahd_simode1_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1138 | 0x57, regvalue, cur_col, wrap)); | 458 | 0x57, regvalue, cur_col, wrap)); |
| 1139 | } | 459 | } |
| 1140 | 460 | ||
| 1141 | int | ||
| 1142 | ahd_gsfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1143 | { | ||
| 1144 | return (ahd_print_register(NULL, 0, "GSFIFO", | ||
| 1145 | 0x58, regvalue, cur_col, wrap)); | ||
| 1146 | } | ||
| 1147 | |||
| 1148 | static const ahd_reg_parse_entry_t DFFSXFRCTL_parse_table[] = { | 461 | static const ahd_reg_parse_entry_t DFFSXFRCTL_parse_table[] = { |
| 1149 | { "RSTCHN", 0x01, 0x01 }, | 462 | { "RSTCHN", 0x01, 0x01 }, |
| 1150 | { "CLRCHN", 0x02, 0x02 }, | 463 | { "CLRCHN", 0x02, 0x02 }, |
| @@ -1159,44 +472,6 @@ ahd_dffsxfrctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1159 | 0x5a, regvalue, cur_col, wrap)); | 472 | 0x5a, regvalue, cur_col, wrap)); |
| 1160 | } | 473 | } |
| 1161 | 474 | ||
| 1162 | static const ahd_reg_parse_entry_t LQOSCSCTL_parse_table[] = { | ||
| 1163 | { "LQONOCHKOVER", 0x01, 0x01 }, | ||
| 1164 | { "LQONOHOLDLACK", 0x02, 0x02 }, | ||
| 1165 | { "LQOBUSETDLY", 0x40, 0x40 }, | ||
| 1166 | { "LQOH2A_VERSION", 0x80, 0x80 } | ||
| 1167 | }; | ||
| 1168 | |||
| 1169 | int | ||
| 1170 | ahd_lqoscsctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1171 | { | ||
| 1172 | return (ahd_print_register(LQOSCSCTL_parse_table, 4, "LQOSCSCTL", | ||
| 1173 | 0x5a, regvalue, cur_col, wrap)); | ||
| 1174 | } | ||
| 1175 | |||
| 1176 | int | ||
| 1177 | ahd_nextscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1178 | { | ||
| 1179 | return (ahd_print_register(NULL, 0, "NEXTSCB", | ||
| 1180 | 0x5a, regvalue, cur_col, wrap)); | ||
| 1181 | } | ||
| 1182 | |||
| 1183 | static const ahd_reg_parse_entry_t CLRSEQINTSRC_parse_table[] = { | ||
| 1184 | { "CLRCFG4TCMD", 0x01, 0x01 }, | ||
| 1185 | { "CLRCFG4ICMD", 0x02, 0x02 }, | ||
| 1186 | { "CLRCFG4TSTAT", 0x04, 0x04 }, | ||
| 1187 | { "CLRCFG4ISTAT", 0x08, 0x08 }, | ||
| 1188 | { "CLRCFG4DATA", 0x10, 0x10 }, | ||
| 1189 | { "CLRSAVEPTRS", 0x20, 0x20 }, | ||
| 1190 | { "CLRCTXTDONE", 0x40, 0x40 } | ||
| 1191 | }; | ||
| 1192 | |||
| 1193 | int | ||
| 1194 | ahd_clrseqintsrc_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1195 | { | ||
| 1196 | return (ahd_print_register(CLRSEQINTSRC_parse_table, 7, "CLRSEQINTSRC", | ||
| 1197 | 0x5b, regvalue, cur_col, wrap)); | ||
| 1198 | } | ||
| 1199 | |||
| 1200 | static const ahd_reg_parse_entry_t SEQINTSRC_parse_table[] = { | 475 | static const ahd_reg_parse_entry_t SEQINTSRC_parse_table[] = { |
| 1201 | { "CFG4TCMD", 0x01, 0x01 }, | 476 | { "CFG4TCMD", 0x01, 0x01 }, |
| 1202 | { "CFG4ICMD", 0x02, 0x02 }, | 477 | { "CFG4ICMD", 0x02, 0x02 }, |
| @@ -1231,13 +506,6 @@ ahd_seqimode_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1231 | 0x5c, regvalue, cur_col, wrap)); | 506 | 0x5c, regvalue, cur_col, wrap)); |
| 1232 | } | 507 | } |
| 1233 | 508 | ||
| 1234 | int | ||
| 1235 | ahd_currscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1236 | { | ||
| 1237 | return (ahd_print_register(NULL, 0, "CURRSCB", | ||
| 1238 | 0x5c, regvalue, cur_col, wrap)); | ||
| 1239 | } | ||
| 1240 | |||
| 1241 | static const ahd_reg_parse_entry_t MDFFSTAT_parse_table[] = { | 509 | static const ahd_reg_parse_entry_t MDFFSTAT_parse_table[] = { |
| 1242 | { "FIFOFREE", 0x01, 0x01 }, | 510 | { "FIFOFREE", 0x01, 0x01 }, |
| 1243 | { "DATAINFIFO", 0x02, 0x02 }, | 511 | { "DATAINFIFO", 0x02, 0x02 }, |
| @@ -1256,308 +524,12 @@ ahd_mdffstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1256 | } | 524 | } |
| 1257 | 525 | ||
| 1258 | int | 526 | int |
| 1259 | ahd_lastscb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1260 | { | ||
| 1261 | return (ahd_print_register(NULL, 0, "LASTSCB", | ||
| 1262 | 0x5e, regvalue, cur_col, wrap)); | ||
| 1263 | } | ||
| 1264 | |||
| 1265 | int | ||
| 1266 | ahd_shaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1267 | { | ||
| 1268 | return (ahd_print_register(NULL, 0, "SHADDR", | ||
| 1269 | 0x60, regvalue, cur_col, wrap)); | ||
| 1270 | } | ||
| 1271 | |||
| 1272 | int | ||
| 1273 | ahd_negoaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1274 | { | ||
| 1275 | return (ahd_print_register(NULL, 0, "NEGOADDR", | ||
| 1276 | 0x60, regvalue, cur_col, wrap)); | ||
| 1277 | } | ||
| 1278 | |||
| 1279 | int | ||
| 1280 | ahd_negperiod_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1281 | { | ||
| 1282 | return (ahd_print_register(NULL, 0, "NEGPERIOD", | ||
| 1283 | 0x61, regvalue, cur_col, wrap)); | ||
| 1284 | } | ||
| 1285 | |||
| 1286 | int | ||
| 1287 | ahd_negoffset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1288 | { | ||
| 1289 | return (ahd_print_register(NULL, 0, "NEGOFFSET", | ||
| 1290 | 0x62, regvalue, cur_col, wrap)); | ||
| 1291 | } | ||
| 1292 | |||
| 1293 | static const ahd_reg_parse_entry_t NEGPPROPTS_parse_table[] = { | ||
| 1294 | { "PPROPT_IUT", 0x01, 0x01 }, | ||
| 1295 | { "PPROPT_DT", 0x02, 0x02 }, | ||
| 1296 | { "PPROPT_QAS", 0x04, 0x04 }, | ||
| 1297 | { "PPROPT_PACE", 0x08, 0x08 } | ||
| 1298 | }; | ||
| 1299 | |||
| 1300 | int | ||
| 1301 | ahd_negppropts_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1302 | { | ||
| 1303 | return (ahd_print_register(NEGPPROPTS_parse_table, 4, "NEGPPROPTS", | ||
| 1304 | 0x63, regvalue, cur_col, wrap)); | ||
| 1305 | } | ||
| 1306 | |||
| 1307 | static const ahd_reg_parse_entry_t NEGCONOPTS_parse_table[] = { | ||
| 1308 | { "WIDEXFER", 0x01, 0x01 }, | ||
| 1309 | { "ENAUTOATNO", 0x02, 0x02 }, | ||
| 1310 | { "ENAUTOATNI", 0x04, 0x04 }, | ||
| 1311 | { "ENSLOWCRC", 0x08, 0x08 }, | ||
| 1312 | { "RTI_OVRDTRN", 0x10, 0x10 }, | ||
| 1313 | { "RTI_WRTDIS", 0x20, 0x20 }, | ||
| 1314 | { "ENSNAPSHOT", 0x40, 0x40 } | ||
| 1315 | }; | ||
| 1316 | |||
| 1317 | int | ||
| 1318 | ahd_negconopts_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1319 | { | ||
| 1320 | return (ahd_print_register(NEGCONOPTS_parse_table, 7, "NEGCONOPTS", | ||
| 1321 | 0x64, regvalue, cur_col, wrap)); | ||
| 1322 | } | ||
| 1323 | |||
| 1324 | int | ||
| 1325 | ahd_annexcol_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1326 | { | ||
| 1327 | return (ahd_print_register(NULL, 0, "ANNEXCOL", | ||
| 1328 | 0x65, regvalue, cur_col, wrap)); | ||
| 1329 | } | ||
| 1330 | |||
| 1331 | int | ||
| 1332 | ahd_annexdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1333 | { | ||
| 1334 | return (ahd_print_register(NULL, 0, "ANNEXDAT", | ||
| 1335 | 0x66, regvalue, cur_col, wrap)); | ||
| 1336 | } | ||
| 1337 | |||
| 1338 | static const ahd_reg_parse_entry_t SCSCHKN_parse_table[] = { | ||
| 1339 | { "LSTSGCLRDIS", 0x01, 0x01 }, | ||
| 1340 | { "SHVALIDSTDIS", 0x02, 0x02 }, | ||
| 1341 | { "DFFACTCLR", 0x04, 0x04 }, | ||
| 1342 | { "SDONEMSKDIS", 0x08, 0x08 }, | ||
| 1343 | { "WIDERESEN", 0x10, 0x10 }, | ||
| 1344 | { "CURRFIFODEF", 0x20, 0x20 }, | ||
| 1345 | { "STSELSKIDDIS", 0x40, 0x40 }, | ||
| 1346 | { "BIDICHKDIS", 0x80, 0x80 } | ||
| 1347 | }; | ||
| 1348 | |||
| 1349 | int | ||
| 1350 | ahd_scschkn_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1351 | { | ||
| 1352 | return (ahd_print_register(SCSCHKN_parse_table, 8, "SCSCHKN", | ||
| 1353 | 0x66, regvalue, cur_col, wrap)); | ||
| 1354 | } | ||
| 1355 | |||
| 1356 | int | ||
| 1357 | ahd_iownid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1358 | { | ||
| 1359 | return (ahd_print_register(NULL, 0, "IOWNID", | ||
| 1360 | 0x67, regvalue, cur_col, wrap)); | ||
| 1361 | } | ||
| 1362 | |||
| 1363 | int | ||
| 1364 | ahd_shcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1365 | { | ||
| 1366 | return (ahd_print_register(NULL, 0, "SHCNT", | ||
| 1367 | 0x68, regvalue, cur_col, wrap)); | ||
| 1368 | } | ||
| 1369 | |||
| 1370 | int | ||
| 1371 | ahd_townid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1372 | { | ||
| 1373 | return (ahd_print_register(NULL, 0, "TOWNID", | ||
| 1374 | 0x69, regvalue, cur_col, wrap)); | ||
| 1375 | } | ||
| 1376 | |||
| 1377 | int | ||
| 1378 | ahd_seloid_print(u_int regvalue, u_int *cur_col, u_int wrap) | 527 | ahd_seloid_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 1379 | { | 528 | { |
| 1380 | return (ahd_print_register(NULL, 0, "SELOID", | 529 | return (ahd_print_register(NULL, 0, "SELOID", |
| 1381 | 0x6b, regvalue, cur_col, wrap)); | 530 | 0x6b, regvalue, cur_col, wrap)); |
| 1382 | } | 531 | } |
| 1383 | 532 | ||
| 1384 | int | ||
| 1385 | ahd_haddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1386 | { | ||
| 1387 | return (ahd_print_register(NULL, 0, "HADDR", | ||
| 1388 | 0x70, regvalue, cur_col, wrap)); | ||
| 1389 | } | ||
| 1390 | |||
| 1391 | int | ||
| 1392 | ahd_hcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1393 | { | ||
| 1394 | return (ahd_print_register(NULL, 0, "HCNT", | ||
| 1395 | 0x78, regvalue, cur_col, wrap)); | ||
| 1396 | } | ||
| 1397 | |||
| 1398 | int | ||
| 1399 | ahd_sghaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1400 | { | ||
| 1401 | return (ahd_print_register(NULL, 0, "SGHADDR", | ||
| 1402 | 0x7c, regvalue, cur_col, wrap)); | ||
| 1403 | } | ||
| 1404 | |||
| 1405 | int | ||
| 1406 | ahd_scbhaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1407 | { | ||
| 1408 | return (ahd_print_register(NULL, 0, "SCBHADDR", | ||
| 1409 | 0x7c, regvalue, cur_col, wrap)); | ||
| 1410 | } | ||
| 1411 | |||
| 1412 | int | ||
| 1413 | ahd_sghcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1414 | { | ||
| 1415 | return (ahd_print_register(NULL, 0, "SGHCNT", | ||
| 1416 | 0x84, regvalue, cur_col, wrap)); | ||
| 1417 | } | ||
| 1418 | |||
| 1419 | int | ||
| 1420 | ahd_scbhcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1421 | { | ||
| 1422 | return (ahd_print_register(NULL, 0, "SCBHCNT", | ||
| 1423 | 0x84, regvalue, cur_col, wrap)); | ||
| 1424 | } | ||
| 1425 | |||
| 1426 | static const ahd_reg_parse_entry_t DFF_THRSH_parse_table[] = { | ||
| 1427 | { "WR_DFTHRSH_MIN", 0x00, 0x70 }, | ||
| 1428 | { "RD_DFTHRSH_MIN", 0x00, 0x07 }, | ||
| 1429 | { "RD_DFTHRSH_25", 0x01, 0x07 }, | ||
| 1430 | { "RD_DFTHRSH_50", 0x02, 0x07 }, | ||
| 1431 | { "RD_DFTHRSH_63", 0x03, 0x07 }, | ||
| 1432 | { "RD_DFTHRSH_75", 0x04, 0x07 }, | ||
| 1433 | { "RD_DFTHRSH_85", 0x05, 0x07 }, | ||
| 1434 | { "RD_DFTHRSH_90", 0x06, 0x07 }, | ||
| 1435 | { "RD_DFTHRSH_MAX", 0x07, 0x07 }, | ||
| 1436 | { "WR_DFTHRSH_25", 0x10, 0x70 }, | ||
| 1437 | { "WR_DFTHRSH_50", 0x20, 0x70 }, | ||
| 1438 | { "WR_DFTHRSH_63", 0x30, 0x70 }, | ||
| 1439 | { "WR_DFTHRSH_75", 0x40, 0x70 }, | ||
| 1440 | { "WR_DFTHRSH_85", 0x50, 0x70 }, | ||
| 1441 | { "WR_DFTHRSH_90", 0x60, 0x70 }, | ||
| 1442 | { "WR_DFTHRSH_MAX", 0x70, 0x70 }, | ||
| 1443 | { "RD_DFTHRSH", 0x07, 0x07 }, | ||
| 1444 | { "WR_DFTHRSH", 0x70, 0x70 } | ||
| 1445 | }; | ||
| 1446 | |||
| 1447 | int | ||
| 1448 | ahd_dff_thrsh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1449 | { | ||
| 1450 | return (ahd_print_register(DFF_THRSH_parse_table, 18, "DFF_THRSH", | ||
| 1451 | 0x88, regvalue, cur_col, wrap)); | ||
| 1452 | } | ||
| 1453 | |||
| 1454 | static const ahd_reg_parse_entry_t PCIXCTL_parse_table[] = { | ||
| 1455 | { "CMPABCDIS", 0x01, 0x01 }, | ||
| 1456 | { "TSCSERREN", 0x02, 0x02 }, | ||
| 1457 | { "SRSPDPEEN", 0x04, 0x04 }, | ||
| 1458 | { "SPLTSTADIS", 0x08, 0x08 }, | ||
| 1459 | { "SPLTSMADIS", 0x10, 0x10 }, | ||
| 1460 | { "UNEXPSCIEN", 0x20, 0x20 }, | ||
| 1461 | { "SERRPULSE", 0x80, 0x80 } | ||
| 1462 | }; | ||
| 1463 | |||
| 1464 | int | ||
| 1465 | ahd_pcixctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1466 | { | ||
| 1467 | return (ahd_print_register(PCIXCTL_parse_table, 7, "PCIXCTL", | ||
| 1468 | 0x93, regvalue, cur_col, wrap)); | ||
| 1469 | } | ||
| 1470 | |||
| 1471 | static const ahd_reg_parse_entry_t DCHSPLTSTAT0_parse_table[] = { | ||
| 1472 | { "RXSPLTRSP", 0x01, 0x01 }, | ||
| 1473 | { "RXSCEMSG", 0x02, 0x02 }, | ||
| 1474 | { "RXOVRUN", 0x04, 0x04 }, | ||
| 1475 | { "CNTNOTCMPLT", 0x08, 0x08 }, | ||
| 1476 | { "SCDATBUCKET", 0x10, 0x10 }, | ||
| 1477 | { "SCADERR", 0x20, 0x20 }, | ||
| 1478 | { "SCBCERR", 0x40, 0x40 }, | ||
| 1479 | { "STAETERM", 0x80, 0x80 } | ||
| 1480 | }; | ||
| 1481 | |||
| 1482 | int | ||
| 1483 | ahd_dchspltstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1484 | { | ||
| 1485 | return (ahd_print_register(DCHSPLTSTAT0_parse_table, 8, "DCHSPLTSTAT0", | ||
| 1486 | 0x96, regvalue, cur_col, wrap)); | ||
| 1487 | } | ||
| 1488 | |||
| 1489 | static const ahd_reg_parse_entry_t DCHSPLTSTAT1_parse_table[] = { | ||
| 1490 | { "RXDATABUCKET", 0x01, 0x01 } | ||
| 1491 | }; | ||
| 1492 | |||
| 1493 | int | ||
| 1494 | ahd_dchspltstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1495 | { | ||
| 1496 | return (ahd_print_register(DCHSPLTSTAT1_parse_table, 1, "DCHSPLTSTAT1", | ||
| 1497 | 0x97, regvalue, cur_col, wrap)); | ||
| 1498 | } | ||
| 1499 | |||
| 1500 | static const ahd_reg_parse_entry_t SGSPLTSTAT0_parse_table[] = { | ||
| 1501 | { "RXSPLTRSP", 0x01, 0x01 }, | ||
| 1502 | { "RXSCEMSG", 0x02, 0x02 }, | ||
| 1503 | { "RXOVRUN", 0x04, 0x04 }, | ||
| 1504 | { "CNTNOTCMPLT", 0x08, 0x08 }, | ||
| 1505 | { "SCDATBUCKET", 0x10, 0x10 }, | ||
| 1506 | { "SCADERR", 0x20, 0x20 }, | ||
| 1507 | { "SCBCERR", 0x40, 0x40 }, | ||
| 1508 | { "STAETERM", 0x80, 0x80 } | ||
| 1509 | }; | ||
| 1510 | |||
| 1511 | int | ||
| 1512 | ahd_sgspltstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1513 | { | ||
| 1514 | return (ahd_print_register(SGSPLTSTAT0_parse_table, 8, "SGSPLTSTAT0", | ||
| 1515 | 0x9e, regvalue, cur_col, wrap)); | ||
| 1516 | } | ||
| 1517 | |||
| 1518 | static const ahd_reg_parse_entry_t SGSPLTSTAT1_parse_table[] = { | ||
| 1519 | { "RXDATABUCKET", 0x01, 0x01 } | ||
| 1520 | }; | ||
| 1521 | |||
| 1522 | int | ||
| 1523 | ahd_sgspltstat1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1524 | { | ||
| 1525 | return (ahd_print_register(SGSPLTSTAT1_parse_table, 1, "SGSPLTSTAT1", | ||
| 1526 | 0x9f, regvalue, cur_col, wrap)); | ||
| 1527 | } | ||
| 1528 | |||
| 1529 | static const ahd_reg_parse_entry_t DF0PCISTAT_parse_table[] = { | ||
| 1530 | { "DPR", 0x01, 0x01 }, | ||
| 1531 | { "TWATERR", 0x02, 0x02 }, | ||
| 1532 | { "RDPERR", 0x04, 0x04 }, | ||
| 1533 | { "SCAAPERR", 0x08, 0x08 }, | ||
| 1534 | { "RTA", 0x10, 0x10 }, | ||
| 1535 | { "RMA", 0x20, 0x20 }, | ||
| 1536 | { "SSE", 0x40, 0x40 }, | ||
| 1537 | { "DPE", 0x80, 0x80 } | ||
| 1538 | }; | ||
| 1539 | |||
| 1540 | int | ||
| 1541 | ahd_df0pcistat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1542 | { | ||
| 1543 | return (ahd_print_register(DF0PCISTAT_parse_table, 8, "DF0PCISTAT", | ||
| 1544 | 0xa0, regvalue, cur_col, wrap)); | ||
| 1545 | } | ||
| 1546 | |||
| 1547 | int | ||
| 1548 | ahd_reg0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1549 | { | ||
| 1550 | return (ahd_print_register(NULL, 0, "REG0", | ||
| 1551 | 0xa0, regvalue, cur_col, wrap)); | ||
| 1552 | } | ||
| 1553 | |||
| 1554 | int | ||
| 1555 | ahd_reg_isr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1556 | { | ||
| 1557 | return (ahd_print_register(NULL, 0, "REG_ISR", | ||
| 1558 | 0xa4, regvalue, cur_col, wrap)); | ||
| 1559 | } | ||
| 1560 | |||
| 1561 | static const ahd_reg_parse_entry_t SG_STATE_parse_table[] = { | 533 | static const ahd_reg_parse_entry_t SG_STATE_parse_table[] = { |
| 1562 | { "SEGS_AVAIL", 0x01, 0x01 }, | 534 | { "SEGS_AVAIL", 0x01, 0x01 }, |
| 1563 | { "LOADING_NEEDED", 0x02, 0x02 }, | 535 | { "LOADING_NEEDED", 0x02, 0x02 }, |
| @@ -1571,54 +543,6 @@ ahd_sg_state_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1571 | 0xa6, regvalue, cur_col, wrap)); | 543 | 0xa6, regvalue, cur_col, wrap)); |
| 1572 | } | 544 | } |
| 1573 | 545 | ||
| 1574 | static const ahd_reg_parse_entry_t TARGPCISTAT_parse_table[] = { | ||
| 1575 | { "TWATERR", 0x02, 0x02 }, | ||
| 1576 | { "STA", 0x08, 0x08 }, | ||
| 1577 | { "SSE", 0x40, 0x40 }, | ||
| 1578 | { "DPE", 0x80, 0x80 } | ||
| 1579 | }; | ||
| 1580 | |||
| 1581 | int | ||
| 1582 | ahd_targpcistat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1583 | { | ||
| 1584 | return (ahd_print_register(TARGPCISTAT_parse_table, 4, "TARGPCISTAT", | ||
| 1585 | 0xa7, regvalue, cur_col, wrap)); | ||
| 1586 | } | ||
| 1587 | |||
| 1588 | int | ||
| 1589 | ahd_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1590 | { | ||
| 1591 | return (ahd_print_register(NULL, 0, "SCBPTR", | ||
| 1592 | 0xa8, regvalue, cur_col, wrap)); | ||
| 1593 | } | ||
| 1594 | |||
| 1595 | static const ahd_reg_parse_entry_t SCBAUTOPTR_parse_table[] = { | ||
| 1596 | { "SCBPTR_OFF", 0x07, 0x07 }, | ||
| 1597 | { "SCBPTR_ADDR", 0x38, 0x38 }, | ||
| 1598 | { "AUSCBPTR_EN", 0x80, 0x80 } | ||
| 1599 | }; | ||
| 1600 | |||
| 1601 | int | ||
| 1602 | ahd_scbautoptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1603 | { | ||
| 1604 | return (ahd_print_register(SCBAUTOPTR_parse_table, 3, "SCBAUTOPTR", | ||
| 1605 | 0xab, regvalue, cur_col, wrap)); | ||
| 1606 | } | ||
| 1607 | |||
| 1608 | int | ||
| 1609 | ahd_ccsgaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1610 | { | ||
| 1611 | return (ahd_print_register(NULL, 0, "CCSGADDR", | ||
| 1612 | 0xac, regvalue, cur_col, wrap)); | ||
| 1613 | } | ||
| 1614 | |||
| 1615 | int | ||
| 1616 | ahd_ccscbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1617 | { | ||
| 1618 | return (ahd_print_register(NULL, 0, "CCSCBADDR", | ||
| 1619 | 0xac, regvalue, cur_col, wrap)); | ||
| 1620 | } | ||
| 1621 | |||
| 1622 | static const ahd_reg_parse_entry_t CCSCBCTL_parse_table[] = { | 546 | static const ahd_reg_parse_entry_t CCSCBCTL_parse_table[] = { |
| 1623 | { "CCSCBRESET", 0x01, 0x01 }, | 547 | { "CCSCBRESET", 0x01, 0x01 }, |
| 1624 | { "CCSCBDIR", 0x04, 0x04 }, | 548 | { "CCSCBDIR", 0x04, 0x04 }, |
| @@ -1651,138 +575,6 @@ ahd_ccsgctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1651 | 0xad, regvalue, cur_col, wrap)); | 575 | 0xad, regvalue, cur_col, wrap)); |
| 1652 | } | 576 | } |
| 1653 | 577 | ||
| 1654 | int | ||
| 1655 | ahd_ccsgram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1656 | { | ||
| 1657 | return (ahd_print_register(NULL, 0, "CCSGRAM", | ||
| 1658 | 0xb0, regvalue, cur_col, wrap)); | ||
| 1659 | } | ||
| 1660 | |||
| 1661 | int | ||
| 1662 | ahd_ccscbram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1663 | { | ||
| 1664 | return (ahd_print_register(NULL, 0, "CCSCBRAM", | ||
| 1665 | 0xb0, regvalue, cur_col, wrap)); | ||
| 1666 | } | ||
| 1667 | |||
| 1668 | int | ||
| 1669 | ahd_brddat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1670 | { | ||
| 1671 | return (ahd_print_register(NULL, 0, "BRDDAT", | ||
| 1672 | 0xb8, regvalue, cur_col, wrap)); | ||
| 1673 | } | ||
| 1674 | |||
| 1675 | static const ahd_reg_parse_entry_t BRDCTL_parse_table[] = { | ||
| 1676 | { "BRDSTB", 0x01, 0x01 }, | ||
| 1677 | { "BRDRW", 0x02, 0x02 }, | ||
| 1678 | { "BRDEN", 0x04, 0x04 }, | ||
| 1679 | { "BRDADDR", 0x38, 0x38 }, | ||
| 1680 | { "FLXARBREQ", 0x40, 0x40 }, | ||
| 1681 | { "FLXARBACK", 0x80, 0x80 } | ||
| 1682 | }; | ||
| 1683 | |||
| 1684 | int | ||
| 1685 | ahd_brdctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1686 | { | ||
| 1687 | return (ahd_print_register(BRDCTL_parse_table, 6, "BRDCTL", | ||
| 1688 | 0xb9, regvalue, cur_col, wrap)); | ||
| 1689 | } | ||
| 1690 | |||
| 1691 | int | ||
| 1692 | ahd_seeadr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1693 | { | ||
| 1694 | return (ahd_print_register(NULL, 0, "SEEADR", | ||
| 1695 | 0xba, regvalue, cur_col, wrap)); | ||
| 1696 | } | ||
| 1697 | |||
| 1698 | int | ||
| 1699 | ahd_seedat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1700 | { | ||
| 1701 | return (ahd_print_register(NULL, 0, "SEEDAT", | ||
| 1702 | 0xbc, regvalue, cur_col, wrap)); | ||
| 1703 | } | ||
| 1704 | |||
| 1705 | static const ahd_reg_parse_entry_t SEECTL_parse_table[] = { | ||
| 1706 | { "SEEOP_ERAL", 0x40, 0x70 }, | ||
| 1707 | { "SEEOP_WRITE", 0x50, 0x70 }, | ||
| 1708 | { "SEEOP_READ", 0x60, 0x70 }, | ||
| 1709 | { "SEEOP_ERASE", 0x70, 0x70 }, | ||
| 1710 | { "SEESTART", 0x01, 0x01 }, | ||
| 1711 | { "SEERST", 0x02, 0x02 }, | ||
| 1712 | { "SEEOPCODE", 0x70, 0x70 }, | ||
| 1713 | { "SEEOP_EWEN", 0x40, 0x40 }, | ||
| 1714 | { "SEEOP_WALL", 0x40, 0x40 }, | ||
| 1715 | { "SEEOP_EWDS", 0x40, 0x40 } | ||
| 1716 | }; | ||
| 1717 | |||
| 1718 | int | ||
| 1719 | ahd_seectl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1720 | { | ||
| 1721 | return (ahd_print_register(SEECTL_parse_table, 10, "SEECTL", | ||
| 1722 | 0xbe, regvalue, cur_col, wrap)); | ||
| 1723 | } | ||
| 1724 | |||
| 1725 | static const ahd_reg_parse_entry_t SEESTAT_parse_table[] = { | ||
| 1726 | { "SEESTART", 0x01, 0x01 }, | ||
| 1727 | { "SEEBUSY", 0x02, 0x02 }, | ||
| 1728 | { "SEEARBACK", 0x04, 0x04 }, | ||
| 1729 | { "LDALTID_L", 0x08, 0x08 }, | ||
| 1730 | { "SEEOPCODE", 0x70, 0x70 }, | ||
| 1731 | { "INIT_DONE", 0x80, 0x80 } | ||
| 1732 | }; | ||
| 1733 | |||
| 1734 | int | ||
| 1735 | ahd_seestat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1736 | { | ||
| 1737 | return (ahd_print_register(SEESTAT_parse_table, 6, "SEESTAT", | ||
| 1738 | 0xbe, regvalue, cur_col, wrap)); | ||
| 1739 | } | ||
| 1740 | |||
| 1741 | static const ahd_reg_parse_entry_t DSPDATACTL_parse_table[] = { | ||
| 1742 | { "XMITOFFSTDIS", 0x02, 0x02 }, | ||
| 1743 | { "RCVROFFSTDIS", 0x04, 0x04 }, | ||
| 1744 | { "DESQDIS", 0x10, 0x10 }, | ||
| 1745 | { "BYPASSENAB", 0x80, 0x80 } | ||
| 1746 | }; | ||
| 1747 | |||
| 1748 | int | ||
| 1749 | ahd_dspdatactl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1750 | { | ||
| 1751 | return (ahd_print_register(DSPDATACTL_parse_table, 4, "DSPDATACTL", | ||
| 1752 | 0xc1, regvalue, cur_col, wrap)); | ||
| 1753 | } | ||
| 1754 | |||
| 1755 | int | ||
| 1756 | ahd_dfdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1757 | { | ||
| 1758 | return (ahd_print_register(NULL, 0, "DFDAT", | ||
| 1759 | 0xc4, regvalue, cur_col, wrap)); | ||
| 1760 | } | ||
| 1761 | |||
| 1762 | static const ahd_reg_parse_entry_t DSPSELECT_parse_table[] = { | ||
| 1763 | { "DSPSEL", 0x1f, 0x1f }, | ||
| 1764 | { "AUTOINCEN", 0x80, 0x80 } | ||
| 1765 | }; | ||
| 1766 | |||
| 1767 | int | ||
| 1768 | ahd_dspselect_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1769 | { | ||
| 1770 | return (ahd_print_register(DSPSELECT_parse_table, 2, "DSPSELECT", | ||
| 1771 | 0xc4, regvalue, cur_col, wrap)); | ||
| 1772 | } | ||
| 1773 | |||
| 1774 | static const ahd_reg_parse_entry_t WRTBIASCTL_parse_table[] = { | ||
| 1775 | { "XMITMANVAL", 0x3f, 0x3f }, | ||
| 1776 | { "AUTOXBCDIS", 0x80, 0x80 } | ||
| 1777 | }; | ||
| 1778 | |||
| 1779 | int | ||
| 1780 | ahd_wrtbiasctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1781 | { | ||
| 1782 | return (ahd_print_register(WRTBIASCTL_parse_table, 2, "WRTBIASCTL", | ||
| 1783 | 0xc5, regvalue, cur_col, wrap)); | ||
| 1784 | } | ||
| 1785 | |||
| 1786 | static const ahd_reg_parse_entry_t SEQCTL0_parse_table[] = { | 578 | static const ahd_reg_parse_entry_t SEQCTL0_parse_table[] = { |
| 1787 | { "LOADRAM", 0x01, 0x01 }, | 579 | { "LOADRAM", 0x01, 0x01 }, |
| 1788 | { "SEQRESET", 0x02, 0x02 }, | 580 | { "SEQRESET", 0x02, 0x02 }, |
| @@ -1801,18 +593,6 @@ ahd_seqctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1801 | 0xd6, regvalue, cur_col, wrap)); | 593 | 0xd6, regvalue, cur_col, wrap)); |
| 1802 | } | 594 | } |
| 1803 | 595 | ||
| 1804 | static const ahd_reg_parse_entry_t FLAGS_parse_table[] = { | ||
| 1805 | { "CARRY", 0x01, 0x01 }, | ||
| 1806 | { "ZERO", 0x02, 0x02 } | ||
| 1807 | }; | ||
| 1808 | |||
| 1809 | int | ||
| 1810 | ahd_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1811 | { | ||
| 1812 | return (ahd_print_register(FLAGS_parse_table, 2, "FLAGS", | ||
| 1813 | 0xd8, regvalue, cur_col, wrap)); | ||
| 1814 | } | ||
| 1815 | |||
| 1816 | static const ahd_reg_parse_entry_t SEQINTCTL_parse_table[] = { | 596 | static const ahd_reg_parse_entry_t SEQINTCTL_parse_table[] = { |
| 1817 | { "IRET", 0x01, 0x01 }, | 597 | { "IRET", 0x01, 0x01 }, |
| 1818 | { "INTMASK1", 0x02, 0x02 }, | 598 | { "INTMASK1", 0x02, 0x02 }, |
| @@ -1831,118 +611,6 @@ ahd_seqintctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1831 | } | 611 | } |
| 1832 | 612 | ||
| 1833 | int | 613 | int |
| 1834 | ahd_seqram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1835 | { | ||
| 1836 | return (ahd_print_register(NULL, 0, "SEQRAM", | ||
| 1837 | 0xda, regvalue, cur_col, wrap)); | ||
| 1838 | } | ||
| 1839 | |||
| 1840 | int | ||
| 1841 | ahd_prgmcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1842 | { | ||
| 1843 | return (ahd_print_register(NULL, 0, "PRGMCNT", | ||
| 1844 | 0xde, regvalue, cur_col, wrap)); | ||
| 1845 | } | ||
| 1846 | |||
| 1847 | int | ||
| 1848 | ahd_accum_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1849 | { | ||
| 1850 | return (ahd_print_register(NULL, 0, "ACCUM", | ||
| 1851 | 0xe0, regvalue, cur_col, wrap)); | ||
| 1852 | } | ||
| 1853 | |||
| 1854 | int | ||
| 1855 | ahd_sindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1856 | { | ||
| 1857 | return (ahd_print_register(NULL, 0, "SINDEX", | ||
| 1858 | 0xe2, regvalue, cur_col, wrap)); | ||
| 1859 | } | ||
| 1860 | |||
| 1861 | int | ||
| 1862 | ahd_dindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1863 | { | ||
| 1864 | return (ahd_print_register(NULL, 0, "DINDEX", | ||
| 1865 | 0xe4, regvalue, cur_col, wrap)); | ||
| 1866 | } | ||
| 1867 | |||
| 1868 | int | ||
| 1869 | ahd_allones_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1870 | { | ||
| 1871 | return (ahd_print_register(NULL, 0, "ALLONES", | ||
| 1872 | 0xe8, regvalue, cur_col, wrap)); | ||
| 1873 | } | ||
| 1874 | |||
| 1875 | int | ||
| 1876 | ahd_allzeros_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1877 | { | ||
| 1878 | return (ahd_print_register(NULL, 0, "ALLZEROS", | ||
| 1879 | 0xea, regvalue, cur_col, wrap)); | ||
| 1880 | } | ||
| 1881 | |||
| 1882 | int | ||
| 1883 | ahd_none_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1884 | { | ||
| 1885 | return (ahd_print_register(NULL, 0, "NONE", | ||
| 1886 | 0xea, regvalue, cur_col, wrap)); | ||
| 1887 | } | ||
| 1888 | |||
| 1889 | int | ||
| 1890 | ahd_sindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1891 | { | ||
| 1892 | return (ahd_print_register(NULL, 0, "SINDIR", | ||
| 1893 | 0xec, regvalue, cur_col, wrap)); | ||
| 1894 | } | ||
| 1895 | |||
| 1896 | int | ||
| 1897 | ahd_dindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1898 | { | ||
| 1899 | return (ahd_print_register(NULL, 0, "DINDIR", | ||
| 1900 | 0xed, regvalue, cur_col, wrap)); | ||
| 1901 | } | ||
| 1902 | |||
| 1903 | int | ||
| 1904 | ahd_stack_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1905 | { | ||
| 1906 | return (ahd_print_register(NULL, 0, "STACK", | ||
| 1907 | 0xf2, regvalue, cur_col, wrap)); | ||
| 1908 | } | ||
| 1909 | |||
| 1910 | int | ||
| 1911 | ahd_intvec1_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1912 | { | ||
| 1913 | return (ahd_print_register(NULL, 0, "INTVEC1_ADDR", | ||
| 1914 | 0xf4, regvalue, cur_col, wrap)); | ||
| 1915 | } | ||
| 1916 | |||
| 1917 | int | ||
| 1918 | ahd_curaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1919 | { | ||
| 1920 | return (ahd_print_register(NULL, 0, "CURADDR", | ||
| 1921 | 0xf4, regvalue, cur_col, wrap)); | ||
| 1922 | } | ||
| 1923 | |||
| 1924 | int | ||
| 1925 | ahd_intvec2_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1926 | { | ||
| 1927 | return (ahd_print_register(NULL, 0, "INTVEC2_ADDR", | ||
| 1928 | 0xf6, regvalue, cur_col, wrap)); | ||
| 1929 | } | ||
| 1930 | |||
| 1931 | int | ||
| 1932 | ahd_longjmp_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1933 | { | ||
| 1934 | return (ahd_print_register(NULL, 0, "LONGJMP_ADDR", | ||
| 1935 | 0xf8, regvalue, cur_col, wrap)); | ||
| 1936 | } | ||
| 1937 | |||
| 1938 | int | ||
| 1939 | ahd_accum_save_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1940 | { | ||
| 1941 | return (ahd_print_register(NULL, 0, "ACCUM_SAVE", | ||
| 1942 | 0xfa, regvalue, cur_col, wrap)); | ||
| 1943 | } | ||
| 1944 | |||
| 1945 | int | ||
| 1946 | ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 614 | ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 1947 | { | 615 | { |
| 1948 | return (ahd_print_register(NULL, 0, "SRAM_BASE", | 616 | return (ahd_print_register(NULL, 0, "SRAM_BASE", |
| @@ -1950,69 +618,6 @@ ahd_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1950 | } | 618 | } |
| 1951 | 619 | ||
| 1952 | int | 620 | int |
| 1953 | ahd_waiting_scb_tails_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1954 | { | ||
| 1955 | return (ahd_print_register(NULL, 0, "WAITING_SCB_TAILS", | ||
| 1956 | 0x100, regvalue, cur_col, wrap)); | ||
| 1957 | } | ||
| 1958 | |||
| 1959 | int | ||
| 1960 | ahd_waiting_tid_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1961 | { | ||
| 1962 | return (ahd_print_register(NULL, 0, "WAITING_TID_HEAD", | ||
| 1963 | 0x120, regvalue, cur_col, wrap)); | ||
| 1964 | } | ||
| 1965 | |||
| 1966 | int | ||
| 1967 | ahd_waiting_tid_tail_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1968 | { | ||
| 1969 | return (ahd_print_register(NULL, 0, "WAITING_TID_TAIL", | ||
| 1970 | 0x122, regvalue, cur_col, wrap)); | ||
| 1971 | } | ||
| 1972 | |||
| 1973 | int | ||
| 1974 | ahd_next_queued_scb_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1975 | { | ||
| 1976 | return (ahd_print_register(NULL, 0, "NEXT_QUEUED_SCB_ADDR", | ||
| 1977 | 0x124, regvalue, cur_col, wrap)); | ||
| 1978 | } | ||
| 1979 | |||
| 1980 | int | ||
| 1981 | ahd_complete_scb_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1982 | { | ||
| 1983 | return (ahd_print_register(NULL, 0, "COMPLETE_SCB_HEAD", | ||
| 1984 | 0x128, regvalue, cur_col, wrap)); | ||
| 1985 | } | ||
| 1986 | |||
| 1987 | int | ||
| 1988 | ahd_complete_scb_dmainprog_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1989 | { | ||
| 1990 | return (ahd_print_register(NULL, 0, "COMPLETE_SCB_DMAINPROG_HEAD", | ||
| 1991 | 0x12a, regvalue, cur_col, wrap)); | ||
| 1992 | } | ||
| 1993 | |||
| 1994 | int | ||
| 1995 | ahd_complete_dma_scb_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1996 | { | ||
| 1997 | return (ahd_print_register(NULL, 0, "COMPLETE_DMA_SCB_HEAD", | ||
| 1998 | 0x12c, regvalue, cur_col, wrap)); | ||
| 1999 | } | ||
| 2000 | |||
| 2001 | int | ||
| 2002 | ahd_complete_dma_scb_tail_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2003 | { | ||
| 2004 | return (ahd_print_register(NULL, 0, "COMPLETE_DMA_SCB_TAIL", | ||
| 2005 | 0x12e, regvalue, cur_col, wrap)); | ||
| 2006 | } | ||
| 2007 | |||
| 2008 | int | ||
| 2009 | ahd_complete_on_qfreeze_head_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2010 | { | ||
| 2011 | return (ahd_print_register(NULL, 0, "COMPLETE_ON_QFREEZE_HEAD", | ||
| 2012 | 0x130, regvalue, cur_col, wrap)); | ||
| 2013 | } | ||
| 2014 | |||
| 2015 | int | ||
| 2016 | ahd_qfreeze_count_print(u_int regvalue, u_int *cur_col, u_int wrap) | 621 | ahd_qfreeze_count_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 2017 | { | 622 | { |
| 2018 | return (ahd_print_register(NULL, 0, "QFREEZE_COUNT", | 623 | return (ahd_print_register(NULL, 0, "QFREEZE_COUNT", |
| @@ -2033,33 +638,6 @@ ahd_saved_mode_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2033 | 0x136, regvalue, cur_col, wrap)); | 638 | 0x136, regvalue, cur_col, wrap)); |
| 2034 | } | 639 | } |
| 2035 | 640 | ||
| 2036 | int | ||
| 2037 | ahd_msg_out_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2038 | { | ||
| 2039 | return (ahd_print_register(NULL, 0, "MSG_OUT", | ||
| 2040 | 0x137, regvalue, cur_col, wrap)); | ||
| 2041 | } | ||
| 2042 | |||
| 2043 | static const ahd_reg_parse_entry_t DMAPARAMS_parse_table[] = { | ||
| 2044 | { "FIFORESET", 0x01, 0x01 }, | ||
| 2045 | { "FIFOFLUSH", 0x02, 0x02 }, | ||
| 2046 | { "DIRECTION", 0x04, 0x04 }, | ||
| 2047 | { "HDMAEN", 0x08, 0x08 }, | ||
| 2048 | { "HDMAENACK", 0x08, 0x08 }, | ||
| 2049 | { "SDMAEN", 0x10, 0x10 }, | ||
| 2050 | { "SDMAENACK", 0x10, 0x10 }, | ||
| 2051 | { "SCSIEN", 0x20, 0x20 }, | ||
| 2052 | { "WIDEODD", 0x40, 0x40 }, | ||
| 2053 | { "PRELOADEN", 0x80, 0x80 } | ||
| 2054 | }; | ||
| 2055 | |||
| 2056 | int | ||
| 2057 | ahd_dmaparams_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2058 | { | ||
| 2059 | return (ahd_print_register(DMAPARAMS_parse_table, 10, "DMAPARAMS", | ||
| 2060 | 0x138, regvalue, cur_col, wrap)); | ||
| 2061 | } | ||
| 2062 | |||
| 2063 | static const ahd_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { | 641 | static const ahd_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { |
| 2064 | { "NO_DISCONNECT", 0x01, 0x01 }, | 642 | { "NO_DISCONNECT", 0x01, 0x01 }, |
| 2065 | { "SPHASE_PENDING", 0x02, 0x02 }, | 643 | { "SPHASE_PENDING", 0x02, 0x02 }, |
| @@ -2079,20 +657,6 @@ ahd_seq_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2079 | 0x139, regvalue, cur_col, wrap)); | 657 | 0x139, regvalue, cur_col, wrap)); |
| 2080 | } | 658 | } |
| 2081 | 659 | ||
| 2082 | int | ||
| 2083 | ahd_saved_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2084 | { | ||
| 2085 | return (ahd_print_register(NULL, 0, "SAVED_SCSIID", | ||
| 2086 | 0x13a, regvalue, cur_col, wrap)); | ||
| 2087 | } | ||
| 2088 | |||
| 2089 | int | ||
| 2090 | ahd_saved_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2091 | { | ||
| 2092 | return (ahd_print_register(NULL, 0, "SAVED_LUN", | ||
| 2093 | 0x13b, regvalue, cur_col, wrap)); | ||
| 2094 | } | ||
| 2095 | |||
| 2096 | static const ahd_reg_parse_entry_t LASTPHASE_parse_table[] = { | 660 | static const ahd_reg_parse_entry_t LASTPHASE_parse_table[] = { |
| 2097 | { "P_DATAOUT", 0x00, 0xe0 }, | 661 | { "P_DATAOUT", 0x00, 0xe0 }, |
| 2098 | { "P_DATAOUT_DT", 0x20, 0xe0 }, | 662 | { "P_DATAOUT_DT", 0x20, 0xe0 }, |
| @@ -2116,96 +680,6 @@ ahd_lastphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2116 | 0x13c, regvalue, cur_col, wrap)); | 680 | 0x13c, regvalue, cur_col, wrap)); |
| 2117 | } | 681 | } |
| 2118 | 682 | ||
| 2119 | int | ||
| 2120 | ahd_qoutfifo_entry_valid_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2121 | { | ||
| 2122 | return (ahd_print_register(NULL, 0, "QOUTFIFO_ENTRY_VALID_TAG", | ||
| 2123 | 0x13d, regvalue, cur_col, wrap)); | ||
| 2124 | } | ||
| 2125 | |||
| 2126 | int | ||
| 2127 | ahd_kernel_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2128 | { | ||
| 2129 | return (ahd_print_register(NULL, 0, "KERNEL_TQINPOS", | ||
| 2130 | 0x13e, regvalue, cur_col, wrap)); | ||
| 2131 | } | ||
| 2132 | |||
| 2133 | int | ||
| 2134 | ahd_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2135 | { | ||
| 2136 | return (ahd_print_register(NULL, 0, "TQINPOS", | ||
| 2137 | 0x13f, regvalue, cur_col, wrap)); | ||
| 2138 | } | ||
| 2139 | |||
| 2140 | int | ||
| 2141 | ahd_shared_data_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2142 | { | ||
| 2143 | return (ahd_print_register(NULL, 0, "SHARED_DATA_ADDR", | ||
| 2144 | 0x140, regvalue, cur_col, wrap)); | ||
| 2145 | } | ||
| 2146 | |||
| 2147 | int | ||
| 2148 | ahd_qoutfifo_next_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2149 | { | ||
| 2150 | return (ahd_print_register(NULL, 0, "QOUTFIFO_NEXT_ADDR", | ||
| 2151 | 0x144, regvalue, cur_col, wrap)); | ||
| 2152 | } | ||
| 2153 | |||
| 2154 | static const ahd_reg_parse_entry_t ARG_1_parse_table[] = { | ||
| 2155 | { "CONT_MSG_LOOP_TARG", 0x02, 0x02 }, | ||
| 2156 | { "CONT_MSG_LOOP_READ", 0x03, 0x03 }, | ||
| 2157 | { "CONT_MSG_LOOP_WRITE",0x04, 0x04 }, | ||
| 2158 | { "EXIT_MSG_LOOP", 0x08, 0x08 }, | ||
| 2159 | { "MSGOUT_PHASEMIS", 0x10, 0x10 }, | ||
| 2160 | { "SEND_REJ", 0x20, 0x20 }, | ||
| 2161 | { "SEND_SENSE", 0x40, 0x40 }, | ||
| 2162 | { "SEND_MSG", 0x80, 0x80 } | ||
| 2163 | }; | ||
| 2164 | |||
| 2165 | int | ||
| 2166 | ahd_arg_1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2167 | { | ||
| 2168 | return (ahd_print_register(ARG_1_parse_table, 8, "ARG_1", | ||
| 2169 | 0x148, regvalue, cur_col, wrap)); | ||
| 2170 | } | ||
| 2171 | |||
| 2172 | int | ||
| 2173 | ahd_arg_2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2174 | { | ||
| 2175 | return (ahd_print_register(NULL, 0, "ARG_2", | ||
| 2176 | 0x149, regvalue, cur_col, wrap)); | ||
| 2177 | } | ||
| 2178 | |||
| 2179 | int | ||
| 2180 | ahd_last_msg_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2181 | { | ||
| 2182 | return (ahd_print_register(NULL, 0, "LAST_MSG", | ||
| 2183 | 0x14a, regvalue, cur_col, wrap)); | ||
| 2184 | } | ||
| 2185 | |||
| 2186 | static const ahd_reg_parse_entry_t SCSISEQ_TEMPLATE_parse_table[] = { | ||
| 2187 | { "ALTSTIM", 0x01, 0x01 }, | ||
| 2188 | { "ENAUTOATNP", 0x02, 0x02 }, | ||
| 2189 | { "MANUALP", 0x0c, 0x0c }, | ||
| 2190 | { "ENRSELI", 0x10, 0x10 }, | ||
| 2191 | { "ENSELI", 0x20, 0x20 }, | ||
| 2192 | { "MANUALCTL", 0x40, 0x40 } | ||
| 2193 | }; | ||
| 2194 | |||
| 2195 | int | ||
| 2196 | ahd_scsiseq_template_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2197 | { | ||
| 2198 | return (ahd_print_register(SCSISEQ_TEMPLATE_parse_table, 6, "SCSISEQ_TEMPLATE", | ||
| 2199 | 0x14b, regvalue, cur_col, wrap)); | ||
| 2200 | } | ||
| 2201 | |||
| 2202 | int | ||
| 2203 | ahd_initiator_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2204 | { | ||
| 2205 | return (ahd_print_register(NULL, 0, "INITIATOR_TAG", | ||
| 2206 | 0x14c, regvalue, cur_col, wrap)); | ||
| 2207 | } | ||
| 2208 | |||
| 2209 | static const ahd_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { | 683 | static const ahd_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { |
| 2210 | { "PENDING_MK_MESSAGE", 0x01, 0x01 }, | 684 | { "PENDING_MK_MESSAGE", 0x01, 0x01 }, |
| 2211 | { "TARGET_MSG_PENDING", 0x02, 0x02 }, | 685 | { "TARGET_MSG_PENDING", 0x02, 0x02 }, |
| @@ -2220,62 +694,6 @@ ahd_seq_flags2_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2220 | } | 694 | } |
| 2221 | 695 | ||
| 2222 | int | 696 | int |
| 2223 | ahd_allocfifo_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2224 | { | ||
| 2225 | return (ahd_print_register(NULL, 0, "ALLOCFIFO_SCBPTR", | ||
| 2226 | 0x14e, regvalue, cur_col, wrap)); | ||
| 2227 | } | ||
| 2228 | |||
| 2229 | int | ||
| 2230 | ahd_int_coalescing_timer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2231 | { | ||
| 2232 | return (ahd_print_register(NULL, 0, "INT_COALESCING_TIMER", | ||
| 2233 | 0x150, regvalue, cur_col, wrap)); | ||
| 2234 | } | ||
| 2235 | |||
| 2236 | int | ||
| 2237 | ahd_int_coalescing_maxcmds_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2238 | { | ||
| 2239 | return (ahd_print_register(NULL, 0, "INT_COALESCING_MAXCMDS", | ||
| 2240 | 0x152, regvalue, cur_col, wrap)); | ||
| 2241 | } | ||
| 2242 | |||
| 2243 | int | ||
| 2244 | ahd_int_coalescing_mincmds_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2245 | { | ||
| 2246 | return (ahd_print_register(NULL, 0, "INT_COALESCING_MINCMDS", | ||
| 2247 | 0x153, regvalue, cur_col, wrap)); | ||
| 2248 | } | ||
| 2249 | |||
| 2250 | int | ||
| 2251 | ahd_cmds_pending_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2252 | { | ||
| 2253 | return (ahd_print_register(NULL, 0, "CMDS_PENDING", | ||
| 2254 | 0x154, regvalue, cur_col, wrap)); | ||
| 2255 | } | ||
| 2256 | |||
| 2257 | int | ||
| 2258 | ahd_int_coalescing_cmdcount_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2259 | { | ||
| 2260 | return (ahd_print_register(NULL, 0, "INT_COALESCING_CMDCOUNT", | ||
| 2261 | 0x156, regvalue, cur_col, wrap)); | ||
| 2262 | } | ||
| 2263 | |||
| 2264 | int | ||
| 2265 | ahd_local_hs_mailbox_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2266 | { | ||
| 2267 | return (ahd_print_register(NULL, 0, "LOCAL_HS_MAILBOX", | ||
| 2268 | 0x157, regvalue, cur_col, wrap)); | ||
| 2269 | } | ||
| 2270 | |||
| 2271 | int | ||
| 2272 | ahd_cmdsize_table_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2273 | { | ||
| 2274 | return (ahd_print_register(NULL, 0, "CMDSIZE_TABLE", | ||
| 2275 | 0x158, regvalue, cur_col, wrap)); | ||
| 2276 | } | ||
| 2277 | |||
| 2278 | int | ||
| 2279 | ahd_mk_message_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) | 697 | ahd_mk_message_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 2280 | { | 698 | { |
| 2281 | return (ahd_print_register(NULL, 0, "MK_MESSAGE_SCB", | 699 | return (ahd_print_register(NULL, 0, "MK_MESSAGE_SCB", |
| @@ -2290,53 +708,12 @@ ahd_mk_message_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2290 | } | 708 | } |
| 2291 | 709 | ||
| 2292 | int | 710 | int |
| 2293 | ahd_scb_residual_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2294 | { | ||
| 2295 | return (ahd_print_register(NULL, 0, "SCB_RESIDUAL_DATACNT", | ||
| 2296 | 0x180, regvalue, cur_col, wrap)); | ||
| 2297 | } | ||
| 2298 | |||
| 2299 | int | ||
| 2300 | ahd_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 711 | ahd_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 2301 | { | 712 | { |
| 2302 | return (ahd_print_register(NULL, 0, "SCB_BASE", | 713 | return (ahd_print_register(NULL, 0, "SCB_BASE", |
| 2303 | 0x180, regvalue, cur_col, wrap)); | 714 | 0x180, regvalue, cur_col, wrap)); |
| 2304 | } | 715 | } |
| 2305 | 716 | ||
| 2306 | static const ahd_reg_parse_entry_t SCB_RESIDUAL_SGPTR_parse_table[] = { | ||
| 2307 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
| 2308 | { "SG_OVERRUN_RESID", 0x02, 0x02 }, | ||
| 2309 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
| 2310 | }; | ||
| 2311 | |||
| 2312 | int | ||
| 2313 | ahd_scb_residual_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2314 | { | ||
| 2315 | return (ahd_print_register(SCB_RESIDUAL_SGPTR_parse_table, 3, "SCB_RESIDUAL_SGPTR", | ||
| 2316 | 0x184, regvalue, cur_col, wrap)); | ||
| 2317 | } | ||
| 2318 | |||
| 2319 | int | ||
| 2320 | ahd_scb_scsi_status_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2321 | { | ||
| 2322 | return (ahd_print_register(NULL, 0, "SCB_SCSI_STATUS", | ||
| 2323 | 0x188, regvalue, cur_col, wrap)); | ||
| 2324 | } | ||
| 2325 | |||
| 2326 | int | ||
| 2327 | ahd_scb_sense_busaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2328 | { | ||
| 2329 | return (ahd_print_register(NULL, 0, "SCB_SENSE_BUSADDR", | ||
| 2330 | 0x18c, regvalue, cur_col, wrap)); | ||
| 2331 | } | ||
| 2332 | |||
| 2333 | int | ||
| 2334 | ahd_scb_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2335 | { | ||
| 2336 | return (ahd_print_register(NULL, 0, "SCB_TAG", | ||
| 2337 | 0x190, regvalue, cur_col, wrap)); | ||
| 2338 | } | ||
| 2339 | |||
| 2340 | static const ahd_reg_parse_entry_t SCB_CONTROL_parse_table[] = { | 717 | static const ahd_reg_parse_entry_t SCB_CONTROL_parse_table[] = { |
| 2341 | { "SCB_TAG_TYPE", 0x03, 0x03 }, | 718 | { "SCB_TAG_TYPE", 0x03, 0x03 }, |
| 2342 | { "DISCONNECTED", 0x04, 0x04 }, | 719 | { "DISCONNECTED", 0x04, 0x04 }, |
| @@ -2366,103 +743,3 @@ ahd_scb_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 2366 | 0x193, regvalue, cur_col, wrap)); | 743 | 0x193, regvalue, cur_col, wrap)); |
| 2367 | } | 744 | } |
| 2368 | 745 | ||
| 2369 | static const ahd_reg_parse_entry_t SCB_LUN_parse_table[] = { | ||
| 2370 | { "LID", 0xff, 0xff } | ||
| 2371 | }; | ||
| 2372 | |||
| 2373 | int | ||
| 2374 | ahd_scb_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2375 | { | ||
| 2376 | return (ahd_print_register(SCB_LUN_parse_table, 1, "SCB_LUN", | ||
| 2377 | 0x194, regvalue, cur_col, wrap)); | ||
| 2378 | } | ||
| 2379 | |||
| 2380 | static const ahd_reg_parse_entry_t SCB_TASK_ATTRIBUTE_parse_table[] = { | ||
| 2381 | { "SCB_XFERLEN_ODD", 0x01, 0x01 } | ||
| 2382 | }; | ||
| 2383 | |||
| 2384 | int | ||
| 2385 | ahd_scb_task_attribute_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2386 | { | ||
| 2387 | return (ahd_print_register(SCB_TASK_ATTRIBUTE_parse_table, 1, "SCB_TASK_ATTRIBUTE", | ||
| 2388 | 0x195, regvalue, cur_col, wrap)); | ||
| 2389 | } | ||
| 2390 | |||
| 2391 | static const ahd_reg_parse_entry_t SCB_CDB_LEN_parse_table[] = { | ||
| 2392 | { "SCB_CDB_LEN_PTR", 0x80, 0x80 } | ||
| 2393 | }; | ||
| 2394 | |||
| 2395 | int | ||
| 2396 | ahd_scb_cdb_len_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2397 | { | ||
| 2398 | return (ahd_print_register(SCB_CDB_LEN_parse_table, 1, "SCB_CDB_LEN", | ||
| 2399 | 0x196, regvalue, cur_col, wrap)); | ||
| 2400 | } | ||
| 2401 | |||
| 2402 | int | ||
| 2403 | ahd_scb_task_management_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2404 | { | ||
| 2405 | return (ahd_print_register(NULL, 0, "SCB_TASK_MANAGEMENT", | ||
| 2406 | 0x197, regvalue, cur_col, wrap)); | ||
| 2407 | } | ||
| 2408 | |||
| 2409 | int | ||
| 2410 | ahd_scb_dataptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2411 | { | ||
| 2412 | return (ahd_print_register(NULL, 0, "SCB_DATAPTR", | ||
| 2413 | 0x198, regvalue, cur_col, wrap)); | ||
| 2414 | } | ||
| 2415 | |||
| 2416 | static const ahd_reg_parse_entry_t SCB_DATACNT_parse_table[] = { | ||
| 2417 | { "SG_HIGH_ADDR_BITS", 0x7f, 0x7f }, | ||
| 2418 | { "SG_LAST_SEG", 0x80, 0x80 } | ||
| 2419 | }; | ||
| 2420 | |||
| 2421 | int | ||
| 2422 | ahd_scb_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2423 | { | ||
| 2424 | return (ahd_print_register(SCB_DATACNT_parse_table, 2, "SCB_DATACNT", | ||
| 2425 | 0x1a0, regvalue, cur_col, wrap)); | ||
| 2426 | } | ||
| 2427 | |||
| 2428 | static const ahd_reg_parse_entry_t SCB_SGPTR_parse_table[] = { | ||
| 2429 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
| 2430 | { "SG_FULL_RESID", 0x02, 0x02 }, | ||
| 2431 | { "SG_STATUS_VALID", 0x04, 0x04 } | ||
| 2432 | }; | ||
| 2433 | |||
| 2434 | int | ||
| 2435 | ahd_scb_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2436 | { | ||
| 2437 | return (ahd_print_register(SCB_SGPTR_parse_table, 3, "SCB_SGPTR", | ||
| 2438 | 0x1a4, regvalue, cur_col, wrap)); | ||
| 2439 | } | ||
| 2440 | |||
| 2441 | int | ||
| 2442 | ahd_scb_busaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2443 | { | ||
| 2444 | return (ahd_print_register(NULL, 0, "SCB_BUSADDR", | ||
| 2445 | 0x1a8, regvalue, cur_col, wrap)); | ||
| 2446 | } | ||
| 2447 | |||
| 2448 | int | ||
| 2449 | ahd_scb_next_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2450 | { | ||
| 2451 | return (ahd_print_register(NULL, 0, "SCB_NEXT", | ||
| 2452 | 0x1ac, regvalue, cur_col, wrap)); | ||
| 2453 | } | ||
| 2454 | |||
| 2455 | int | ||
| 2456 | ahd_scb_next2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2457 | { | ||
| 2458 | return (ahd_print_register(NULL, 0, "SCB_NEXT2", | ||
| 2459 | 0x1ae, regvalue, cur_col, wrap)); | ||
| 2460 | } | ||
| 2461 | |||
| 2462 | int | ||
| 2463 | ahd_scb_disconnected_lists_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 2464 | { | ||
| 2465 | return (ahd_print_register(NULL, 0, "SCB_DISCONNECTED_LISTS", | ||
| 2466 | 0x1b8, regvalue, cur_col, wrap)); | ||
| 2467 | } | ||
| 2468 | |||
diff --git a/drivers/scsi/aic7xxx/aic7xxx.reg b/drivers/scsi/aic7xxx/aic7xxx.reg index 0d2f763c3427..9a96e55da39a 100644 --- a/drivers/scsi/aic7xxx/aic7xxx.reg +++ b/drivers/scsi/aic7xxx/aic7xxx.reg | |||
| @@ -51,6 +51,17 @@ VERSION = "$Id: //depot/aic7xxx/aic7xxx/aic7xxx.reg#40 $" | |||
| 51 | */ | 51 | */ |
| 52 | 52 | ||
| 53 | /* | 53 | /* |
| 54 | * Registers marked "dont_generate_debug_code" are not (yet) referenced | ||
| 55 | * from the driver code, and this keyword inhibit generation | ||
| 56 | * of debug code for them. | ||
| 57 | * | ||
| 58 | * REG_PRETTY_PRINT config will complain if dont_generate_debug_code | ||
| 59 | * is added to the register which is referenced in the driver. | ||
| 60 | * Unreferenced register with no dont_generate_debug_code will result | ||
| 61 | * in dead code. No warning is issued. | ||
| 62 | */ | ||
| 63 | |||
| 64 | /* | ||
| 54 | * SCSI Sequence Control (p. 3-11). | 65 | * SCSI Sequence Control (p. 3-11). |
| 55 | * Each bit, when set starts a specific SCSI sequence on the bus | 66 | * Each bit, when set starts a specific SCSI sequence on the bus |
| 56 | */ | 67 | */ |
| @@ -97,6 +108,7 @@ register SXFRCTL1 { | |||
| 97 | field ENSTIMER 0x04 | 108 | field ENSTIMER 0x04 |
| 98 | field ACTNEGEN 0x02 | 109 | field ACTNEGEN 0x02 |
| 99 | field STPWEN 0x01 /* Powered Termination */ | 110 | field STPWEN 0x01 /* Powered Termination */ |
| 111 | dont_generate_debug_code | ||
| 100 | } | 112 | } |
| 101 | 113 | ||
| 102 | /* | 114 | /* |
| @@ -155,6 +167,7 @@ register SCSISIGO { | |||
| 155 | mask P_MESGOUT CDI|MSGI | 167 | mask P_MESGOUT CDI|MSGI |
| 156 | mask P_STATUS CDI|IOI | 168 | mask P_STATUS CDI|IOI |
| 157 | mask P_MESGIN CDI|IOI|MSGI | 169 | mask P_MESGIN CDI|IOI|MSGI |
| 170 | dont_generate_debug_code | ||
| 158 | } | 171 | } |
| 159 | 172 | ||
| 160 | /* | 173 | /* |
| @@ -194,6 +207,7 @@ register SCSIID { | |||
| 194 | */ | 207 | */ |
| 195 | alias SCSIOFFSET | 208 | alias SCSIOFFSET |
| 196 | mask SOFS_ULTRA2 0x7f /* Sync offset U2 chips */ | 209 | mask SOFS_ULTRA2 0x7f /* Sync offset U2 chips */ |
| 210 | dont_generate_debug_code | ||
| 197 | } | 211 | } |
| 198 | 212 | ||
| 199 | /* | 213 | /* |
| @@ -205,6 +219,7 @@ register SCSIID { | |||
| 205 | register SCSIDATL { | 219 | register SCSIDATL { |
| 206 | address 0x006 | 220 | address 0x006 |
| 207 | access_mode RW | 221 | access_mode RW |
| 222 | dont_generate_debug_code | ||
| 208 | } | 223 | } |
| 209 | 224 | ||
| 210 | register SCSIDATH { | 225 | register SCSIDATH { |
| @@ -223,6 +238,7 @@ register STCNT { | |||
| 223 | address 0x008 | 238 | address 0x008 |
| 224 | size 3 | 239 | size 3 |
| 225 | access_mode RW | 240 | access_mode RW |
| 241 | dont_generate_debug_code | ||
| 226 | } | 242 | } |
| 227 | 243 | ||
| 228 | /* ALT_MODE registers (Ultra2 and Ultra160 chips) */ | 244 | /* ALT_MODE registers (Ultra2 and Ultra160 chips) */ |
| @@ -248,6 +264,7 @@ register OPTIONMODE { | |||
| 248 | field AUTO_MSGOUT_DE 0x02 | 264 | field AUTO_MSGOUT_DE 0x02 |
| 249 | field DIS_MSGIN_DUALEDGE 0x01 | 265 | field DIS_MSGIN_DUALEDGE 0x01 |
| 250 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE|DIS_MSGIN_DUALEDGE | 266 | mask OPTIONMODE_DEFAULTS AUTO_MSGOUT_DE|DIS_MSGIN_DUALEDGE |
| 267 | dont_generate_debug_code | ||
| 251 | } | 268 | } |
| 252 | 269 | ||
| 253 | /* ALT_MODE register on Ultra160 chips */ | 270 | /* ALT_MODE register on Ultra160 chips */ |
| @@ -256,6 +273,7 @@ register TARGCRCCNT { | |||
| 256 | size 2 | 273 | size 2 |
| 257 | access_mode RW | 274 | access_mode RW |
| 258 | count 2 | 275 | count 2 |
| 276 | dont_generate_debug_code | ||
| 259 | } | 277 | } |
| 260 | 278 | ||
| 261 | /* | 279 | /* |
| @@ -271,6 +289,7 @@ register CLRSINT0 { | |||
| 271 | field CLRSWRAP 0x08 | 289 | field CLRSWRAP 0x08 |
| 272 | field CLRIOERR 0x08 /* Ultra2 Only */ | 290 | field CLRIOERR 0x08 /* Ultra2 Only */ |
| 273 | field CLRSPIORDY 0x02 | 291 | field CLRSPIORDY 0x02 |
| 292 | dont_generate_debug_code | ||
| 274 | } | 293 | } |
| 275 | 294 | ||
| 276 | /* | 295 | /* |
| @@ -306,6 +325,7 @@ register CLRSINT1 { | |||
| 306 | field CLRSCSIPERR 0x04 | 325 | field CLRSCSIPERR 0x04 |
| 307 | field CLRPHASECHG 0x02 | 326 | field CLRPHASECHG 0x02 |
| 308 | field CLRREQINIT 0x01 | 327 | field CLRREQINIT 0x01 |
| 328 | dont_generate_debug_code | ||
| 309 | } | 329 | } |
| 310 | 330 | ||
| 311 | /* | 331 | /* |
| @@ -360,6 +380,7 @@ register SCSIID_ULTRA2 { | |||
| 360 | access_mode RW | 380 | access_mode RW |
| 361 | mask TID 0xf0 /* Target ID mask */ | 381 | mask TID 0xf0 /* Target ID mask */ |
| 362 | mask OID 0x0f /* Our ID mask */ | 382 | mask OID 0x0f /* Our ID mask */ |
| 383 | dont_generate_debug_code | ||
| 363 | } | 384 | } |
| 364 | 385 | ||
| 365 | /* | 386 | /* |
| @@ -425,6 +446,7 @@ register SHADDR { | |||
| 425 | address 0x014 | 446 | address 0x014 |
| 426 | size 4 | 447 | size 4 |
| 427 | access_mode RO | 448 | access_mode RO |
| 449 | dont_generate_debug_code | ||
| 428 | } | 450 | } |
| 429 | 451 | ||
| 430 | /* | 452 | /* |
| @@ -441,6 +463,7 @@ register SELTIMER { | |||
| 441 | field STAGE2 0x02 | 463 | field STAGE2 0x02 |
| 442 | field STAGE1 0x01 | 464 | field STAGE1 0x01 |
| 443 | alias TARGIDIN | 465 | alias TARGIDIN |
| 466 | dont_generate_debug_code | ||
| 444 | } | 467 | } |
| 445 | 468 | ||
| 446 | /* | 469 | /* |
| @@ -453,6 +476,7 @@ register SELID { | |||
| 453 | access_mode RW | 476 | access_mode RW |
| 454 | mask SELID_MASK 0xf0 | 477 | mask SELID_MASK 0xf0 |
| 455 | field ONEBIT 0x08 | 478 | field ONEBIT 0x08 |
| 479 | dont_generate_debug_code | ||
| 456 | } | 480 | } |
| 457 | 481 | ||
| 458 | register SCAMCTL { | 482 | register SCAMCTL { |
| @@ -473,6 +497,7 @@ register TARGID { | |||
| 473 | size 2 | 497 | size 2 |
| 474 | access_mode RW | 498 | access_mode RW |
| 475 | count 14 | 499 | count 14 |
| 500 | dont_generate_debug_code | ||
| 476 | } | 501 | } |
| 477 | 502 | ||
| 478 | /* | 503 | /* |
| @@ -495,6 +520,7 @@ register SPIOCAP { | |||
| 495 | field EEPROM 0x04 /* Writable external BIOS ROM */ | 520 | field EEPROM 0x04 /* Writable external BIOS ROM */ |
| 496 | field ROM 0x02 /* Logic for accessing external ROM */ | 521 | field ROM 0x02 /* Logic for accessing external ROM */ |
| 497 | field SSPIOCPS 0x01 /* Termination and cable detection */ | 522 | field SSPIOCPS 0x01 /* Termination and cable detection */ |
| 523 | dont_generate_debug_code | ||
| 498 | } | 524 | } |
| 499 | 525 | ||
| 500 | register BRDCTL { | 526 | register BRDCTL { |
| @@ -514,6 +540,7 @@ register BRDCTL { | |||
| 514 | field BRDDAT2 0x04 | 540 | field BRDDAT2 0x04 |
| 515 | field BRDRW_ULTRA2 0x02 | 541 | field BRDRW_ULTRA2 0x02 |
| 516 | field BRDSTB_ULTRA2 0x01 | 542 | field BRDSTB_ULTRA2 0x01 |
| 543 | dont_generate_debug_code | ||
| 517 | } | 544 | } |
| 518 | 545 | ||
| 519 | /* | 546 | /* |
| @@ -551,6 +578,7 @@ register SEECTL { | |||
| 551 | field SEECK 0x04 | 578 | field SEECK 0x04 |
| 552 | field SEEDO 0x02 | 579 | field SEEDO 0x02 |
| 553 | field SEEDI 0x01 | 580 | field SEEDI 0x01 |
| 581 | dont_generate_debug_code | ||
| 554 | } | 582 | } |
| 555 | /* | 583 | /* |
| 556 | * SCSI Block Control (p. 3-32) | 584 | * SCSI Block Control (p. 3-32) |
| @@ -601,6 +629,7 @@ register SEQRAM { | |||
| 601 | address 0x061 | 629 | address 0x061 |
| 602 | access_mode RW | 630 | access_mode RW |
| 603 | count 2 | 631 | count 2 |
| 632 | dont_generate_debug_code | ||
| 604 | } | 633 | } |
| 605 | 634 | ||
| 606 | /* | 635 | /* |
| @@ -610,6 +639,7 @@ register SEQRAM { | |||
| 610 | register SEQADDR0 { | 639 | register SEQADDR0 { |
| 611 | address 0x062 | 640 | address 0x062 |
| 612 | access_mode RW | 641 | access_mode RW |
| 642 | dont_generate_debug_code | ||
| 613 | } | 643 | } |
| 614 | 644 | ||
| 615 | register SEQADDR1 { | 645 | register SEQADDR1 { |
| @@ -617,6 +647,7 @@ register SEQADDR1 { | |||
| 617 | access_mode RW | 647 | access_mode RW |
| 618 | count 8 | 648 | count 8 |
| 619 | mask SEQADDR1_MASK 0x01 | 649 | mask SEQADDR1_MASK 0x01 |
| 650 | dont_generate_debug_code | ||
| 620 | } | 651 | } |
| 621 | 652 | ||
| 622 | /* | 653 | /* |
| @@ -627,35 +658,41 @@ register ACCUM { | |||
| 627 | address 0x064 | 658 | address 0x064 |
| 628 | access_mode RW | 659 | access_mode RW |
| 629 | accumulator | 660 | accumulator |
| 661 | dont_generate_debug_code | ||
| 630 | } | 662 | } |
| 631 | 663 | ||
| 632 | register SINDEX { | 664 | register SINDEX { |
| 633 | address 0x065 | 665 | address 0x065 |
| 634 | access_mode RW | 666 | access_mode RW |
| 635 | sindex | 667 | sindex |
| 668 | dont_generate_debug_code | ||
| 636 | } | 669 | } |
| 637 | 670 | ||
| 638 | register DINDEX { | 671 | register DINDEX { |
| 639 | address 0x066 | 672 | address 0x066 |
| 640 | access_mode RW | 673 | access_mode RW |
| 674 | dont_generate_debug_code | ||
| 641 | } | 675 | } |
| 642 | 676 | ||
| 643 | register ALLONES { | 677 | register ALLONES { |
| 644 | address 0x069 | 678 | address 0x069 |
| 645 | access_mode RO | 679 | access_mode RO |
| 646 | allones | 680 | allones |
| 681 | dont_generate_debug_code | ||
| 647 | } | 682 | } |
| 648 | 683 | ||
| 649 | register ALLZEROS { | 684 | register ALLZEROS { |
| 650 | address 0x06a | 685 | address 0x06a |
| 651 | access_mode RO | 686 | access_mode RO |
| 652 | allzeros | 687 | allzeros |
| 688 | dont_generate_debug_code | ||
| 653 | } | 689 | } |
| 654 | 690 | ||
| 655 | register NONE { | 691 | register NONE { |
| 656 | address 0x06a | 692 | address 0x06a |
| 657 | access_mode WO | 693 | access_mode WO |
| 658 | none | 694 | none |
| 695 | dont_generate_debug_code | ||
| 659 | } | 696 | } |
| 660 | 697 | ||
| 661 | register FLAGS { | 698 | register FLAGS { |
| @@ -664,16 +701,19 @@ register FLAGS { | |||
| 664 | count 18 | 701 | count 18 |
| 665 | field ZERO 0x02 | 702 | field ZERO 0x02 |
| 666 | field CARRY 0x01 | 703 | field CARRY 0x01 |
| 704 | dont_generate_debug_code | ||
| 667 | } | 705 | } |
| 668 | 706 | ||
| 669 | register SINDIR { | 707 | register SINDIR { |
| 670 | address 0x06c | 708 | address 0x06c |
| 671 | access_mode RO | 709 | access_mode RO |
| 710 | dont_generate_debug_code | ||
| 672 | } | 711 | } |
| 673 | 712 | ||
| 674 | register DINDIR { | 713 | register DINDIR { |
| 675 | address 0x06d | 714 | address 0x06d |
| 676 | access_mode WO | 715 | access_mode WO |
| 716 | dont_generate_debug_code | ||
| 677 | } | 717 | } |
| 678 | 718 | ||
| 679 | register FUNCTION1 { | 719 | register FUNCTION1 { |
| @@ -685,6 +725,7 @@ register STACK { | |||
| 685 | address 0x06f | 725 | address 0x06f |
| 686 | access_mode RO | 726 | access_mode RO |
| 687 | count 5 | 727 | count 5 |
| 728 | dont_generate_debug_code | ||
| 688 | } | 729 | } |
| 689 | 730 | ||
| 690 | const STACK_SIZE 4 | 731 | const STACK_SIZE 4 |
| @@ -716,6 +757,7 @@ register DSCOMMAND0 { | |||
| 716 | field RAMPS 0x04 /* External SCB RAM Present */ | 757 | field RAMPS 0x04 /* External SCB RAM Present */ |
| 717 | field USCBSIZE32 0x02 /* Use 32byte SCB Page Size */ | 758 | field USCBSIZE32 0x02 /* Use 32byte SCB Page Size */ |
| 718 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ | 759 | field CIOPARCKEN 0x01 /* Internal bus parity error enable */ |
| 760 | dont_generate_debug_code | ||
| 719 | } | 761 | } |
| 720 | 762 | ||
| 721 | register DSCOMMAND1 { | 763 | register DSCOMMAND1 { |
| @@ -724,6 +766,7 @@ register DSCOMMAND1 { | |||
| 724 | mask DSLATT 0xfc /* PCI latency timer (non-ultra2) */ | 766 | mask DSLATT 0xfc /* PCI latency timer (non-ultra2) */ |
| 725 | field HADDLDSEL1 0x02 /* Host Address Load Select Bits */ | 767 | field HADDLDSEL1 0x02 /* Host Address Load Select Bits */ |
| 726 | field HADDLDSEL0 0x01 | 768 | field HADDLDSEL0 0x01 |
| 769 | dont_generate_debug_code | ||
| 727 | } | 770 | } |
| 728 | 771 | ||
| 729 | /* | 772 | /* |
| @@ -735,6 +778,7 @@ register BUSTIME { | |||
| 735 | count 2 | 778 | count 2 |
| 736 | mask BOFF 0xf0 | 779 | mask BOFF 0xf0 |
| 737 | mask BON 0x0f | 780 | mask BON 0x0f |
| 781 | dont_generate_debug_code | ||
| 738 | } | 782 | } |
| 739 | 783 | ||
| 740 | /* | 784 | /* |
| @@ -749,6 +793,7 @@ register BUSSPD { | |||
| 749 | mask STBON 0x07 | 793 | mask STBON 0x07 |
| 750 | mask DFTHRSH_100 0xc0 | 794 | mask DFTHRSH_100 0xc0 |
| 751 | mask DFTHRSH_75 0x80 | 795 | mask DFTHRSH_75 0x80 |
| 796 | dont_generate_debug_code | ||
| 752 | } | 797 | } |
| 753 | 798 | ||
| 754 | /* aic7850/55/60/70/80/95 only */ | 799 | /* aic7850/55/60/70/80/95 only */ |
| @@ -756,6 +801,7 @@ register DSPCISTATUS { | |||
| 756 | address 0x086 | 801 | address 0x086 |
| 757 | count 4 | 802 | count 4 |
| 758 | mask DFTHRSH_100 0xc0 | 803 | mask DFTHRSH_100 0xc0 |
| 804 | dont_generate_debug_code | ||
| 759 | } | 805 | } |
| 760 | 806 | ||
| 761 | /* aic7890/91/96/97 only */ | 807 | /* aic7890/91/96/97 only */ |
| @@ -764,6 +810,7 @@ register HS_MAILBOX { | |||
| 764 | mask HOST_MAILBOX 0xF0 | 810 | mask HOST_MAILBOX 0xF0 |
| 765 | mask SEQ_MAILBOX 0x0F | 811 | mask SEQ_MAILBOX 0x0F |
| 766 | mask HOST_TQINPOS 0x80 /* Boundary at either 0 or 128 */ | 812 | mask HOST_TQINPOS 0x80 /* Boundary at either 0 or 128 */ |
| 813 | dont_generate_debug_code | ||
| 767 | } | 814 | } |
| 768 | 815 | ||
| 769 | const HOST_MAILBOX_SHIFT 4 | 816 | const HOST_MAILBOX_SHIFT 4 |
| @@ -784,6 +831,7 @@ register HCNTRL { | |||
| 784 | field INTEN 0x02 | 831 | field INTEN 0x02 |
| 785 | field CHIPRST 0x01 | 832 | field CHIPRST 0x01 |
| 786 | field CHIPRSTACK 0x01 | 833 | field CHIPRSTACK 0x01 |
| 834 | dont_generate_debug_code | ||
| 787 | } | 835 | } |
| 788 | 836 | ||
| 789 | /* | 837 | /* |
| @@ -795,12 +843,14 @@ register HADDR { | |||
| 795 | address 0x088 | 843 | address 0x088 |
| 796 | size 4 | 844 | size 4 |
| 797 | access_mode RW | 845 | access_mode RW |
| 846 | dont_generate_debug_code | ||
| 798 | } | 847 | } |
| 799 | 848 | ||
| 800 | register HCNT { | 849 | register HCNT { |
| 801 | address 0x08c | 850 | address 0x08c |
| 802 | size 3 | 851 | size 3 |
| 803 | access_mode RW | 852 | access_mode RW |
| 853 | dont_generate_debug_code | ||
| 804 | } | 854 | } |
| 805 | 855 | ||
| 806 | /* | 856 | /* |
| @@ -810,6 +860,7 @@ register HCNT { | |||
| 810 | register SCBPTR { | 860 | register SCBPTR { |
| 811 | address 0x090 | 861 | address 0x090 |
| 812 | access_mode RW | 862 | access_mode RW |
| 863 | dont_generate_debug_code | ||
| 813 | } | 864 | } |
| 814 | 865 | ||
| 815 | /* | 866 | /* |
| @@ -878,6 +929,7 @@ register INTSTAT { | |||
| 878 | 929 | ||
| 879 | mask SEQINT_MASK 0xf0|SEQINT /* SEQINT Status Codes */ | 930 | mask SEQINT_MASK 0xf0|SEQINT /* SEQINT Status Codes */ |
| 880 | mask INT_PEND (BRKADRINT|SEQINT|SCSIINT|CMDCMPLT) | 931 | mask INT_PEND (BRKADRINT|SEQINT|SCSIINT|CMDCMPLT) |
| 932 | dont_generate_debug_code | ||
| 881 | } | 933 | } |
| 882 | 934 | ||
| 883 | /* | 935 | /* |
| @@ -911,6 +963,7 @@ register CLRINT { | |||
| 911 | field CLRSCSIINT 0x04 | 963 | field CLRSCSIINT 0x04 |
| 912 | field CLRCMDINT 0x02 | 964 | field CLRCMDINT 0x02 |
| 913 | field CLRSEQINT 0x01 | 965 | field CLRSEQINT 0x01 |
| 966 | dont_generate_debug_code | ||
| 914 | } | 967 | } |
| 915 | 968 | ||
| 916 | register DFCNTRL { | 969 | register DFCNTRL { |
| @@ -944,6 +997,7 @@ register DFSTATUS { | |||
| 944 | register DFWADDR { | 997 | register DFWADDR { |
| 945 | address 0x95 | 998 | address 0x95 |
| 946 | access_mode RW | 999 | access_mode RW |
| 1000 | dont_generate_debug_code | ||
| 947 | } | 1001 | } |
| 948 | 1002 | ||
| 949 | register DFRADDR { | 1003 | register DFRADDR { |
| @@ -954,6 +1008,7 @@ register DFRADDR { | |||
| 954 | register DFDAT { | 1008 | register DFDAT { |
| 955 | address 0x099 | 1009 | address 0x099 |
| 956 | access_mode RW | 1010 | access_mode RW |
| 1011 | dont_generate_debug_code | ||
| 957 | } | 1012 | } |
| 958 | 1013 | ||
| 959 | /* | 1014 | /* |
| @@ -967,6 +1022,7 @@ register SCBCNT { | |||
| 967 | count 1 | 1022 | count 1 |
| 968 | field SCBAUTO 0x80 | 1023 | field SCBAUTO 0x80 |
| 969 | mask SCBCNT_MASK 0x1f | 1024 | mask SCBCNT_MASK 0x1f |
| 1025 | dont_generate_debug_code | ||
| 970 | } | 1026 | } |
| 971 | 1027 | ||
| 972 | /* | 1028 | /* |
| @@ -977,6 +1033,7 @@ register QINFIFO { | |||
| 977 | address 0x09b | 1033 | address 0x09b |
| 978 | access_mode RW | 1034 | access_mode RW |
| 979 | count 12 | 1035 | count 12 |
| 1036 | dont_generate_debug_code | ||
| 980 | } | 1037 | } |
| 981 | 1038 | ||
| 982 | /* | 1039 | /* |
| @@ -996,6 +1053,7 @@ register QOUTFIFO { | |||
| 996 | address 0x09d | 1053 | address 0x09d |
| 997 | access_mode WO | 1054 | access_mode WO |
| 998 | count 7 | 1055 | count 7 |
| 1056 | dont_generate_debug_code | ||
| 999 | } | 1057 | } |
| 1000 | 1058 | ||
| 1001 | register CRCCONTROL1 { | 1059 | register CRCCONTROL1 { |
| @@ -1008,6 +1066,7 @@ register CRCCONTROL1 { | |||
| 1008 | field CRCREQCHKEN 0x10 | 1066 | field CRCREQCHKEN 0x10 |
| 1009 | field TARGCRCENDEN 0x08 | 1067 | field TARGCRCENDEN 0x08 |
| 1010 | field TARGCRCCNTEN 0x04 | 1068 | field TARGCRCCNTEN 0x04 |
| 1069 | dont_generate_debug_code | ||
| 1011 | } | 1070 | } |
| 1012 | 1071 | ||
| 1013 | 1072 | ||
| @@ -1040,6 +1099,7 @@ register SFUNCT { | |||
| 1040 | access_mode RW | 1099 | access_mode RW |
| 1041 | count 4 | 1100 | count 4 |
| 1042 | field ALT_MODE 0x80 | 1101 | field ALT_MODE 0x80 |
| 1102 | dont_generate_debug_code | ||
| 1043 | } | 1103 | } |
| 1044 | 1104 | ||
| 1045 | /* | 1105 | /* |
| @@ -1053,24 +1113,31 @@ scb { | |||
| 1053 | size 4 | 1113 | size 4 |
| 1054 | alias SCB_RESIDUAL_DATACNT | 1114 | alias SCB_RESIDUAL_DATACNT |
| 1055 | alias SCB_CDB_STORE | 1115 | alias SCB_CDB_STORE |
| 1116 | dont_generate_debug_code | ||
| 1056 | } | 1117 | } |
| 1057 | SCB_RESIDUAL_SGPTR { | 1118 | SCB_RESIDUAL_SGPTR { |
| 1058 | size 4 | 1119 | size 4 |
| 1120 | dont_generate_debug_code | ||
| 1059 | } | 1121 | } |
| 1060 | SCB_SCSI_STATUS { | 1122 | SCB_SCSI_STATUS { |
| 1061 | size 1 | 1123 | size 1 |
| 1124 | dont_generate_debug_code | ||
| 1062 | } | 1125 | } |
| 1063 | SCB_TARGET_PHASES { | 1126 | SCB_TARGET_PHASES { |
| 1064 | size 1 | 1127 | size 1 |
| 1128 | dont_generate_debug_code | ||
| 1065 | } | 1129 | } |
| 1066 | SCB_TARGET_DATA_DIR { | 1130 | SCB_TARGET_DATA_DIR { |
| 1067 | size 1 | 1131 | size 1 |
| 1132 | dont_generate_debug_code | ||
| 1068 | } | 1133 | } |
| 1069 | SCB_TARGET_ITAG { | 1134 | SCB_TARGET_ITAG { |
| 1070 | size 1 | 1135 | size 1 |
| 1136 | dont_generate_debug_code | ||
| 1071 | } | 1137 | } |
| 1072 | SCB_DATAPTR { | 1138 | SCB_DATAPTR { |
| 1073 | size 4 | 1139 | size 4 |
| 1140 | dont_generate_debug_code | ||
| 1074 | } | 1141 | } |
| 1075 | SCB_DATACNT { | 1142 | SCB_DATACNT { |
| 1076 | /* | 1143 | /* |
| @@ -1080,12 +1147,14 @@ scb { | |||
| 1080 | size 4 | 1147 | size 4 |
| 1081 | field SG_LAST_SEG 0x80 /* In the fourth byte */ | 1148 | field SG_LAST_SEG 0x80 /* In the fourth byte */ |
| 1082 | mask SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ | 1149 | mask SG_HIGH_ADDR_BITS 0x7F /* In the fourth byte */ |
| 1150 | dont_generate_debug_code | ||
| 1083 | } | 1151 | } |
| 1084 | SCB_SGPTR { | 1152 | SCB_SGPTR { |
| 1085 | size 4 | 1153 | size 4 |
| 1086 | field SG_RESID_VALID 0x04 /* In the first byte */ | 1154 | field SG_RESID_VALID 0x04 /* In the first byte */ |
| 1087 | field SG_FULL_RESID 0x02 /* In the first byte */ | 1155 | field SG_FULL_RESID 0x02 /* In the first byte */ |
| 1088 | field SG_LIST_NULL 0x01 /* In the first byte */ | 1156 | field SG_LIST_NULL 0x01 /* In the first byte */ |
| 1157 | dont_generate_debug_code | ||
| 1089 | } | 1158 | } |
| 1090 | SCB_CONTROL { | 1159 | SCB_CONTROL { |
| 1091 | size 1 | 1160 | size 1 |
| @@ -1115,22 +1184,27 @@ scb { | |||
| 1115 | } | 1184 | } |
| 1116 | SCB_CDB_LEN { | 1185 | SCB_CDB_LEN { |
| 1117 | size 1 | 1186 | size 1 |
| 1187 | dont_generate_debug_code | ||
| 1118 | } | 1188 | } |
| 1119 | SCB_SCSIRATE { | 1189 | SCB_SCSIRATE { |
| 1120 | size 1 | 1190 | size 1 |
| 1191 | dont_generate_debug_code | ||
| 1121 | } | 1192 | } |
| 1122 | SCB_SCSIOFFSET { | 1193 | SCB_SCSIOFFSET { |
| 1123 | size 1 | 1194 | size 1 |
| 1124 | count 1 | 1195 | count 1 |
| 1196 | dont_generate_debug_code | ||
| 1125 | } | 1197 | } |
| 1126 | SCB_NEXT { | 1198 | SCB_NEXT { |
| 1127 | size 1 | 1199 | size 1 |
| 1200 | dont_generate_debug_code | ||
| 1128 | } | 1201 | } |
| 1129 | SCB_64_SPARE { | 1202 | SCB_64_SPARE { |
| 1130 | size 16 | 1203 | size 16 |
| 1131 | } | 1204 | } |
| 1132 | SCB_64_BTT { | 1205 | SCB_64_BTT { |
| 1133 | size 16 | 1206 | size 16 |
| 1207 | dont_generate_debug_code | ||
| 1134 | } | 1208 | } |
| 1135 | } | 1209 | } |
| 1136 | 1210 | ||
| @@ -1149,6 +1223,7 @@ register SEECTL_2840 { | |||
| 1149 | field CS_2840 0x04 | 1223 | field CS_2840 0x04 |
| 1150 | field CK_2840 0x02 | 1224 | field CK_2840 0x02 |
| 1151 | field DO_2840 0x01 | 1225 | field DO_2840 0x01 |
| 1226 | dont_generate_debug_code | ||
| 1152 | } | 1227 | } |
| 1153 | 1228 | ||
| 1154 | register STATUS_2840 { | 1229 | register STATUS_2840 { |
| @@ -1159,6 +1234,7 @@ register STATUS_2840 { | |||
| 1159 | mask BIOS_SEL 0x60 | 1234 | mask BIOS_SEL 0x60 |
| 1160 | mask ADSEL 0x1e | 1235 | mask ADSEL 0x1e |
| 1161 | field DI_2840 0x01 | 1236 | field DI_2840 0x01 |
| 1237 | dont_generate_debug_code | ||
| 1162 | } | 1238 | } |
| 1163 | 1239 | ||
| 1164 | /* --------------------- AIC-7870-only definitions -------------------- */ | 1240 | /* --------------------- AIC-7870-only definitions -------------------- */ |
| @@ -1166,18 +1242,22 @@ register STATUS_2840 { | |||
| 1166 | register CCHADDR { | 1242 | register CCHADDR { |
| 1167 | address 0x0E0 | 1243 | address 0x0E0 |
| 1168 | size 8 | 1244 | size 8 |
| 1245 | dont_generate_debug_code | ||
| 1169 | } | 1246 | } |
| 1170 | 1247 | ||
| 1171 | register CCHCNT { | 1248 | register CCHCNT { |
| 1172 | address 0x0E8 | 1249 | address 0x0E8 |
| 1250 | dont_generate_debug_code | ||
| 1173 | } | 1251 | } |
| 1174 | 1252 | ||
| 1175 | register CCSGRAM { | 1253 | register CCSGRAM { |
| 1176 | address 0x0E9 | 1254 | address 0x0E9 |
| 1255 | dont_generate_debug_code | ||
| 1177 | } | 1256 | } |
| 1178 | 1257 | ||
| 1179 | register CCSGADDR { | 1258 | register CCSGADDR { |
| 1180 | address 0x0EA | 1259 | address 0x0EA |
| 1260 | dont_generate_debug_code | ||
| 1181 | } | 1261 | } |
| 1182 | 1262 | ||
| 1183 | register CCSGCTL { | 1263 | register CCSGCTL { |
| @@ -1186,11 +1266,13 @@ register CCSGCTL { | |||
| 1186 | field CCSGEN 0x08 | 1266 | field CCSGEN 0x08 |
| 1187 | field SG_FETCH_NEEDED 0x02 /* Bit used for software state */ | 1267 | field SG_FETCH_NEEDED 0x02 /* Bit used for software state */ |
| 1188 | field CCSGRESET 0x01 | 1268 | field CCSGRESET 0x01 |
| 1269 | dont_generate_debug_code | ||
| 1189 | } | 1270 | } |
| 1190 | 1271 | ||
| 1191 | register CCSCBCNT { | 1272 | register CCSCBCNT { |
| 1192 | address 0xEF | 1273 | address 0xEF |
| 1193 | count 1 | 1274 | count 1 |
| 1275 | dont_generate_debug_code | ||
| 1194 | } | 1276 | } |
| 1195 | 1277 | ||
| 1196 | register CCSCBCTL { | 1278 | register CCSCBCTL { |
| @@ -1201,14 +1283,17 @@ register CCSCBCTL { | |||
| 1201 | field CCSCBEN 0x08 | 1283 | field CCSCBEN 0x08 |
| 1202 | field CCSCBDIR 0x04 | 1284 | field CCSCBDIR 0x04 |
| 1203 | field CCSCBRESET 0x01 | 1285 | field CCSCBRESET 0x01 |
| 1286 | dont_generate_debug_code | ||
| 1204 | } | 1287 | } |
| 1205 | 1288 | ||
| 1206 | register CCSCBADDR { | 1289 | register CCSCBADDR { |
| 1207 | address 0x0ED | 1290 | address 0x0ED |
| 1291 | dont_generate_debug_code | ||
| 1208 | } | 1292 | } |
| 1209 | 1293 | ||
| 1210 | register CCSCBRAM { | 1294 | register CCSCBRAM { |
| 1211 | address 0xEC | 1295 | address 0xEC |
| 1296 | dont_generate_debug_code | ||
| 1212 | } | 1297 | } |
| 1213 | 1298 | ||
| 1214 | /* | 1299 | /* |
| @@ -1218,23 +1303,28 @@ register SCBBADDR { | |||
| 1218 | address 0x0F0 | 1303 | address 0x0F0 |
| 1219 | access_mode RW | 1304 | access_mode RW |
| 1220 | count 3 | 1305 | count 3 |
| 1306 | dont_generate_debug_code | ||
| 1221 | } | 1307 | } |
| 1222 | 1308 | ||
| 1223 | register CCSCBPTR { | 1309 | register CCSCBPTR { |
| 1224 | address 0x0F1 | 1310 | address 0x0F1 |
| 1311 | dont_generate_debug_code | ||
| 1225 | } | 1312 | } |
| 1226 | 1313 | ||
| 1227 | register HNSCB_QOFF { | 1314 | register HNSCB_QOFF { |
| 1228 | address 0x0F4 | 1315 | address 0x0F4 |
| 1229 | count 4 | 1316 | count 4 |
| 1317 | dont_generate_debug_code | ||
| 1230 | } | 1318 | } |
| 1231 | 1319 | ||
| 1232 | register SNSCB_QOFF { | 1320 | register SNSCB_QOFF { |
| 1233 | address 0x0F6 | 1321 | address 0x0F6 |
| 1322 | dont_generate_debug_code | ||
| 1234 | } | 1323 | } |
| 1235 | 1324 | ||
| 1236 | register SDSCB_QOFF { | 1325 | register SDSCB_QOFF { |
| 1237 | address 0x0F8 | 1326 | address 0x0F8 |
| 1327 | dont_generate_debug_code | ||
| 1238 | } | 1328 | } |
| 1239 | 1329 | ||
| 1240 | register QOFF_CTLSTA { | 1330 | register QOFF_CTLSTA { |
| @@ -1244,6 +1334,7 @@ register QOFF_CTLSTA { | |||
| 1244 | field SDSCB_ROLLOVER 0x10 | 1334 | field SDSCB_ROLLOVER 0x10 |
| 1245 | mask SCB_QSIZE 0x07 | 1335 | mask SCB_QSIZE 0x07 |
| 1246 | mask SCB_QSIZE_256 0x06 | 1336 | mask SCB_QSIZE_256 0x06 |
| 1337 | dont_generate_debug_code | ||
| 1247 | } | 1338 | } |
| 1248 | 1339 | ||
| 1249 | register DFF_THRSH { | 1340 | register DFF_THRSH { |
| @@ -1267,6 +1358,7 @@ register DFF_THRSH { | |||
| 1267 | mask WR_DFTHRSH_90 0x60 | 1358 | mask WR_DFTHRSH_90 0x60 |
| 1268 | mask WR_DFTHRSH_MAX 0x70 | 1359 | mask WR_DFTHRSH_MAX 0x70 |
| 1269 | count 4 | 1360 | count 4 |
| 1361 | dont_generate_debug_code | ||
| 1270 | } | 1362 | } |
| 1271 | 1363 | ||
| 1272 | register SG_CACHE_PRE { | 1364 | register SG_CACHE_PRE { |
| @@ -1275,6 +1367,7 @@ register SG_CACHE_PRE { | |||
| 1275 | mask SG_ADDR_MASK 0xf8 | 1367 | mask SG_ADDR_MASK 0xf8 |
| 1276 | field LAST_SEG 0x02 | 1368 | field LAST_SEG 0x02 |
| 1277 | field LAST_SEG_DONE 0x01 | 1369 | field LAST_SEG_DONE 0x01 |
| 1370 | dont_generate_debug_code | ||
| 1278 | } | 1371 | } |
| 1279 | 1372 | ||
| 1280 | register SG_CACHE_SHADOW { | 1373 | register SG_CACHE_SHADOW { |
| @@ -1283,6 +1376,7 @@ register SG_CACHE_SHADOW { | |||
| 1283 | mask SG_ADDR_MASK 0xf8 | 1376 | mask SG_ADDR_MASK 0xf8 |
| 1284 | field LAST_SEG 0x02 | 1377 | field LAST_SEG 0x02 |
| 1285 | field LAST_SEG_DONE 0x01 | 1378 | field LAST_SEG_DONE 0x01 |
| 1379 | dont_generate_debug_code | ||
| 1286 | } | 1380 | } |
| 1287 | /* ---------------------- Scratch RAM Offsets ------------------------- */ | 1381 | /* ---------------------- Scratch RAM Offsets ------------------------- */ |
| 1288 | /* These offsets are either to values that are initialized by the board's | 1382 | /* These offsets are either to values that are initialized by the board's |
| @@ -1309,6 +1403,7 @@ scratch_ram { | |||
| 1309 | BUSY_TARGETS { | 1403 | BUSY_TARGETS { |
| 1310 | alias TARG_SCSIRATE | 1404 | alias TARG_SCSIRATE |
| 1311 | size 16 | 1405 | size 16 |
| 1406 | dont_generate_debug_code | ||
| 1312 | } | 1407 | } |
| 1313 | /* | 1408 | /* |
| 1314 | * Bit vector of targets that have ULTRA enabled as set by | 1409 | * Bit vector of targets that have ULTRA enabled as set by |
| @@ -1321,6 +1416,7 @@ scratch_ram { | |||
| 1321 | alias CMDSIZE_TABLE | 1416 | alias CMDSIZE_TABLE |
| 1322 | size 2 | 1417 | size 2 |
| 1323 | count 2 | 1418 | count 2 |
| 1419 | dont_generate_debug_code | ||
| 1324 | } | 1420 | } |
| 1325 | /* | 1421 | /* |
| 1326 | * Bit vector of targets that have disconnection disabled as set by | 1422 | * Bit vector of targets that have disconnection disabled as set by |
| @@ -1331,6 +1427,7 @@ scratch_ram { | |||
| 1331 | DISC_DSB { | 1427 | DISC_DSB { |
| 1332 | size 2 | 1428 | size 2 |
| 1333 | count 6 | 1429 | count 6 |
| 1430 | dont_generate_debug_code | ||
| 1334 | } | 1431 | } |
| 1335 | CMDSIZE_TABLE_TAIL { | 1432 | CMDSIZE_TABLE_TAIL { |
| 1336 | size 4 | 1433 | size 4 |
| @@ -1341,12 +1438,14 @@ scratch_ram { | |||
| 1341 | */ | 1438 | */ |
| 1342 | MWI_RESIDUAL { | 1439 | MWI_RESIDUAL { |
| 1343 | size 1 | 1440 | size 1 |
| 1441 | dont_generate_debug_code | ||
| 1344 | } | 1442 | } |
| 1345 | /* | 1443 | /* |
| 1346 | * SCBID of the next SCB to be started by the controller. | 1444 | * SCBID of the next SCB to be started by the controller. |
| 1347 | */ | 1445 | */ |
| 1348 | NEXT_QUEUED_SCB { | 1446 | NEXT_QUEUED_SCB { |
| 1349 | size 1 | 1447 | size 1 |
| 1448 | dont_generate_debug_code | ||
| 1350 | } | 1449 | } |
| 1351 | /* | 1450 | /* |
| 1352 | * Single byte buffer used to designate the type or message | 1451 | * Single byte buffer used to designate the type or message |
| @@ -1354,6 +1453,7 @@ scratch_ram { | |||
| 1354 | */ | 1453 | */ |
| 1355 | MSG_OUT { | 1454 | MSG_OUT { |
| 1356 | size 1 | 1455 | size 1 |
| 1456 | dont_generate_debug_code | ||
| 1357 | } | 1457 | } |
| 1358 | /* Parameters for DMA Logic */ | 1458 | /* Parameters for DMA Logic */ |
| 1359 | DMAPARAMS { | 1459 | DMAPARAMS { |
| @@ -1369,6 +1469,7 @@ scratch_ram { | |||
| 1369 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ | 1469 | field DIRECTION 0x04 /* Set indicates PCI->SCSI */ |
| 1370 | field FIFOFLUSH 0x02 | 1470 | field FIFOFLUSH 0x02 |
| 1371 | field FIFORESET 0x01 | 1471 | field FIFORESET 0x01 |
| 1472 | dont_generate_debug_code | ||
| 1372 | } | 1473 | } |
| 1373 | SEQ_FLAGS { | 1474 | SEQ_FLAGS { |
| 1374 | size 1 | 1475 | size 1 |
| @@ -1390,9 +1491,11 @@ scratch_ram { | |||
| 1390 | */ | 1491 | */ |
| 1391 | SAVED_SCSIID { | 1492 | SAVED_SCSIID { |
| 1392 | size 1 | 1493 | size 1 |
| 1494 | dont_generate_debug_code | ||
| 1393 | } | 1495 | } |
| 1394 | SAVED_LUN { | 1496 | SAVED_LUN { |
| 1395 | size 1 | 1497 | size 1 |
| 1498 | dont_generate_debug_code | ||
| 1396 | } | 1499 | } |
| 1397 | /* | 1500 | /* |
| 1398 | * The last bus phase as seen by the sequencer. | 1501 | * The last bus phase as seen by the sequencer. |
| @@ -1417,6 +1520,7 @@ scratch_ram { | |||
| 1417 | */ | 1520 | */ |
| 1418 | WAITING_SCBH { | 1521 | WAITING_SCBH { |
| 1419 | size 1 | 1522 | size 1 |
| 1523 | dont_generate_debug_code | ||
| 1420 | } | 1524 | } |
| 1421 | /* | 1525 | /* |
| 1422 | * head of list of SCBs that are | 1526 | * head of list of SCBs that are |
| @@ -1425,6 +1529,7 @@ scratch_ram { | |||
| 1425 | */ | 1529 | */ |
| 1426 | DISCONNECTED_SCBH { | 1530 | DISCONNECTED_SCBH { |
| 1427 | size 1 | 1531 | size 1 |
| 1532 | dont_generate_debug_code | ||
| 1428 | } | 1533 | } |
| 1429 | /* | 1534 | /* |
| 1430 | * head of list of SCBs that are | 1535 | * head of list of SCBs that are |
| @@ -1432,6 +1537,7 @@ scratch_ram { | |||
| 1432 | */ | 1537 | */ |
| 1433 | FREE_SCBH { | 1538 | FREE_SCBH { |
| 1434 | size 1 | 1539 | size 1 |
| 1540 | dont_generate_debug_code | ||
| 1435 | } | 1541 | } |
| 1436 | /* | 1542 | /* |
| 1437 | * head of list of SCBs that have | 1543 | * head of list of SCBs that have |
| @@ -1446,6 +1552,7 @@ scratch_ram { | |||
| 1446 | */ | 1552 | */ |
| 1447 | HSCB_ADDR { | 1553 | HSCB_ADDR { |
| 1448 | size 4 | 1554 | size 4 |
| 1555 | dont_generate_debug_code | ||
| 1449 | } | 1556 | } |
| 1450 | /* | 1557 | /* |
| 1451 | * Base address of our shared data with the kernel driver in host | 1558 | * Base address of our shared data with the kernel driver in host |
| @@ -1454,15 +1561,19 @@ scratch_ram { | |||
| 1454 | */ | 1561 | */ |
| 1455 | SHARED_DATA_ADDR { | 1562 | SHARED_DATA_ADDR { |
| 1456 | size 4 | 1563 | size 4 |
| 1564 | dont_generate_debug_code | ||
| 1457 | } | 1565 | } |
| 1458 | KERNEL_QINPOS { | 1566 | KERNEL_QINPOS { |
| 1459 | size 1 | 1567 | size 1 |
| 1568 | dont_generate_debug_code | ||
| 1460 | } | 1569 | } |
| 1461 | QINPOS { | 1570 | QINPOS { |
| 1462 | size 1 | 1571 | size 1 |
| 1572 | dont_generate_debug_code | ||
| 1463 | } | 1573 | } |
| 1464 | QOUTPOS { | 1574 | QOUTPOS { |
| 1465 | size 1 | 1575 | size 1 |
| 1576 | dont_generate_debug_code | ||
| 1466 | } | 1577 | } |
| 1467 | /* | 1578 | /* |
| 1468 | * Kernel and sequencer offsets into the queue of | 1579 | * Kernel and sequencer offsets into the queue of |
| @@ -1471,9 +1582,11 @@ scratch_ram { | |||
| 1471 | */ | 1582 | */ |
| 1472 | KERNEL_TQINPOS { | 1583 | KERNEL_TQINPOS { |
| 1473 | size 1 | 1584 | size 1 |
| 1585 | dont_generate_debug_code | ||
| 1474 | } | 1586 | } |
| 1475 | TQINPOS { | 1587 | TQINPOS { |
| 1476 | size 1 | 1588 | size 1 |
| 1589 | dont_generate_debug_code | ||
| 1477 | } | 1590 | } |
| 1478 | ARG_1 { | 1591 | ARG_1 { |
| 1479 | size 1 | 1592 | size 1 |
| @@ -1486,10 +1599,12 @@ scratch_ram { | |||
| 1486 | mask CONT_MSG_LOOP 0x04 | 1599 | mask CONT_MSG_LOOP 0x04 |
| 1487 | mask CONT_TARG_SESSION 0x02 | 1600 | mask CONT_TARG_SESSION 0x02 |
| 1488 | alias RETURN_1 | 1601 | alias RETURN_1 |
| 1602 | dont_generate_debug_code | ||
| 1489 | } | 1603 | } |
| 1490 | ARG_2 { | 1604 | ARG_2 { |
| 1491 | size 1 | 1605 | size 1 |
| 1492 | alias RETURN_2 | 1606 | alias RETURN_2 |
| 1607 | dont_generate_debug_code | ||
| 1493 | } | 1608 | } |
| 1494 | 1609 | ||
| 1495 | /* | 1610 | /* |
| @@ -1498,6 +1613,7 @@ scratch_ram { | |||
| 1498 | LAST_MSG { | 1613 | LAST_MSG { |
| 1499 | size 1 | 1614 | size 1 |
| 1500 | alias TARG_IMMEDIATE_SCB | 1615 | alias TARG_IMMEDIATE_SCB |
| 1616 | dont_generate_debug_code | ||
| 1501 | } | 1617 | } |
| 1502 | 1618 | ||
| 1503 | /* | 1619 | /* |
| @@ -1513,6 +1629,7 @@ scratch_ram { | |||
| 1513 | field ENAUTOATNO 0x08 | 1629 | field ENAUTOATNO 0x08 |
| 1514 | field ENAUTOATNI 0x04 | 1630 | field ENAUTOATNI 0x04 |
| 1515 | field ENAUTOATNP 0x02 | 1631 | field ENAUTOATNP 0x02 |
| 1632 | dont_generate_debug_code | ||
| 1516 | } | 1633 | } |
| 1517 | } | 1634 | } |
| 1518 | 1635 | ||
| @@ -1533,12 +1650,14 @@ scratch_ram { | |||
| 1533 | field HA_274_EXTENDED_TRANS 0x01 | 1650 | field HA_274_EXTENDED_TRANS 0x01 |
| 1534 | alias INITIATOR_TAG | 1651 | alias INITIATOR_TAG |
| 1535 | count 1 | 1652 | count 1 |
| 1653 | dont_generate_debug_code | ||
| 1536 | } | 1654 | } |
| 1537 | 1655 | ||
| 1538 | SEQ_FLAGS2 { | 1656 | SEQ_FLAGS2 { |
| 1539 | size 1 | 1657 | size 1 |
| 1540 | field SCB_DMA 0x01 | 1658 | field SCB_DMA 0x01 |
| 1541 | field TARGET_MSG_PENDING 0x02 | 1659 | field TARGET_MSG_PENDING 0x02 |
| 1660 | dont_generate_debug_code | ||
| 1542 | } | 1661 | } |
| 1543 | } | 1662 | } |
| 1544 | 1663 | ||
| @@ -1562,6 +1681,7 @@ scratch_ram { | |||
| 1562 | field ENSPCHK 0x20 | 1681 | field ENSPCHK 0x20 |
| 1563 | mask HSCSIID 0x07 /* our SCSI ID */ | 1682 | mask HSCSIID 0x07 /* our SCSI ID */ |
| 1564 | mask HWSCSIID 0x0f /* our SCSI ID if Wide Bus */ | 1683 | mask HWSCSIID 0x0f /* our SCSI ID if Wide Bus */ |
| 1684 | dont_generate_debug_code | ||
| 1565 | } | 1685 | } |
| 1566 | INTDEF { | 1686 | INTDEF { |
| 1567 | address 0x05c | 1687 | address 0x05c |
| @@ -1569,11 +1689,13 @@ scratch_ram { | |||
| 1569 | count 1 | 1689 | count 1 |
| 1570 | field EDGE_TRIG 0x80 | 1690 | field EDGE_TRIG 0x80 |
| 1571 | mask VECTOR 0x0f | 1691 | mask VECTOR 0x0f |
| 1692 | dont_generate_debug_code | ||
| 1572 | } | 1693 | } |
| 1573 | HOSTCONF { | 1694 | HOSTCONF { |
| 1574 | address 0x05d | 1695 | address 0x05d |
| 1575 | size 1 | 1696 | size 1 |
| 1576 | count 1 | 1697 | count 1 |
| 1698 | dont_generate_debug_code | ||
| 1577 | } | 1699 | } |
| 1578 | HA_274_BIOSCTRL { | 1700 | HA_274_BIOSCTRL { |
| 1579 | address 0x05f | 1701 | address 0x05f |
| @@ -1582,6 +1704,7 @@ scratch_ram { | |||
| 1582 | mask BIOSMODE 0x30 | 1704 | mask BIOSMODE 0x30 |
| 1583 | mask BIOSDISABLED 0x30 | 1705 | mask BIOSDISABLED 0x30 |
| 1584 | field CHANNEL_B_PRIMARY 0x08 | 1706 | field CHANNEL_B_PRIMARY 0x08 |
| 1707 | dont_generate_debug_code | ||
| 1585 | } | 1708 | } |
| 1586 | } | 1709 | } |
| 1587 | 1710 | ||
| @@ -1595,6 +1718,7 @@ scratch_ram { | |||
| 1595 | TARG_OFFSET { | 1718 | TARG_OFFSET { |
| 1596 | size 16 | 1719 | size 16 |
| 1597 | count 1 | 1720 | count 1 |
| 1721 | dont_generate_debug_code | ||
| 1598 | } | 1722 | } |
| 1599 | } | 1723 | } |
| 1600 | 1724 | ||
diff --git a/drivers/scsi/aic7xxx/aic7xxx_core.c b/drivers/scsi/aic7xxx/aic7xxx_core.c index 0ae2b4605d09..e6f2bb7365e6 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_core.c +++ b/drivers/scsi/aic7xxx/aic7xxx_core.c | |||
| @@ -814,6 +814,7 @@ ahc_intr(struct ahc_softc *ahc) | |||
| 814 | static void | 814 | static void |
| 815 | ahc_restart(struct ahc_softc *ahc) | 815 | ahc_restart(struct ahc_softc *ahc) |
| 816 | { | 816 | { |
| 817 | uint8_t sblkctl; | ||
| 817 | 818 | ||
| 818 | ahc_pause(ahc); | 819 | ahc_pause(ahc); |
| 819 | 820 | ||
| @@ -868,6 +869,12 @@ ahc_restart(struct ahc_softc *ahc) | |||
| 868 | ahc_outb(ahc, SEQADDR0, 0); | 869 | ahc_outb(ahc, SEQADDR0, 0); |
| 869 | ahc_outb(ahc, SEQADDR1, 0); | 870 | ahc_outb(ahc, SEQADDR1, 0); |
| 870 | 871 | ||
| 872 | /* | ||
| 873 | * Take the LED out of diagnostic mode on PM resume, too | ||
| 874 | */ | ||
| 875 | sblkctl = ahc_inb(ahc, SBLKCTL); | ||
| 876 | ahc_outb(ahc, SBLKCTL, (sblkctl & ~(DIAGLEDEN|DIAGLEDON))); | ||
| 877 | |||
| 871 | ahc_unpause(ahc); | 878 | ahc_unpause(ahc); |
| 872 | } | 879 | } |
| 873 | 880 | ||
diff --git a/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped b/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped index 2ce1febca207..e821082a4f47 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped +++ b/drivers/scsi/aic7xxx/aic7xxx_reg.h_shipped | |||
| @@ -27,20 +27,6 @@ ahc_reg_print_t ahc_sxfrctl0_print; | |||
| 27 | #endif | 27 | #endif |
| 28 | 28 | ||
| 29 | #if AIC_DEBUG_REGISTERS | 29 | #if AIC_DEBUG_REGISTERS |
| 30 | ahc_reg_print_t ahc_sxfrctl1_print; | ||
| 31 | #else | ||
| 32 | #define ahc_sxfrctl1_print(regvalue, cur_col, wrap) \ | ||
| 33 | ahc_print_register(NULL, 0, "SXFRCTL1", 0x02, regvalue, cur_col, wrap) | ||
| 34 | #endif | ||
| 35 | |||
| 36 | #if AIC_DEBUG_REGISTERS | ||
| 37 | ahc_reg_print_t ahc_scsisigo_print; | ||
| 38 | #else | ||
| 39 | #define ahc_scsisigo_print(regvalue, cur_col, wrap) \ | ||
| 40 | ahc_print_register(NULL, 0, "SCSISIGO", 0x03, regvalue, cur_col, wrap) | ||
| 41 | #endif | ||
| 42 | |||
| 43 | #if AIC_DEBUG_REGISTERS | ||
| 44 | ahc_reg_print_t ahc_scsisigi_print; | 30 | ahc_reg_print_t ahc_scsisigi_print; |
| 45 | #else | 31 | #else |
| 46 | #define ahc_scsisigi_print(regvalue, cur_col, wrap) \ | 32 | #define ahc_scsisigi_print(regvalue, cur_col, wrap) \ |
| @@ -55,55 +41,6 @@ ahc_reg_print_t ahc_scsirate_print; | |||
| 55 | #endif | 41 | #endif |
| 56 | 42 | ||
| 57 | #if AIC_DEBUG_REGISTERS | 43 | #if AIC_DEBUG_REGISTERS |
| 58 | ahc_reg_print_t ahc_scsiid_print; | ||
| 59 | #else | ||
| 60 | #define ahc_scsiid_print(regvalue, cur_col, wrap) \ | ||
| 61 | ahc_print_register(NULL, 0, "SCSIID", 0x05, regvalue, cur_col, wrap) | ||
| 62 | #endif | ||
| 63 | |||
| 64 | #if AIC_DEBUG_REGISTERS | ||
| 65 | ahc_reg_print_t ahc_scsidatl_print; | ||
| 66 | #else | ||
| 67 | #define ahc_scsidatl_print(regvalue, cur_col, wrap) \ | ||
| 68 | ahc_print_register(NULL, 0, "SCSIDATL", 0x06, regvalue, cur_col, wrap) | ||
| 69 | #endif | ||
| 70 | |||
| 71 | #if AIC_DEBUG_REGISTERS | ||
| 72 | ahc_reg_print_t ahc_scsidath_print; | ||
| 73 | #else | ||
| 74 | #define ahc_scsidath_print(regvalue, cur_col, wrap) \ | ||
| 75 | ahc_print_register(NULL, 0, "SCSIDATH", 0x07, regvalue, cur_col, wrap) | ||
| 76 | #endif | ||
| 77 | |||
| 78 | #if AIC_DEBUG_REGISTERS | ||
| 79 | ahc_reg_print_t ahc_stcnt_print; | ||
| 80 | #else | ||
| 81 | #define ahc_stcnt_print(regvalue, cur_col, wrap) \ | ||
| 82 | ahc_print_register(NULL, 0, "STCNT", 0x08, regvalue, cur_col, wrap) | ||
| 83 | #endif | ||
| 84 | |||
| 85 | #if AIC_DEBUG_REGISTERS | ||
| 86 | ahc_reg_print_t ahc_optionmode_print; | ||
| 87 | #else | ||
| 88 | #define ahc_optionmode_print(regvalue, cur_col, wrap) \ | ||
| 89 | ahc_print_register(NULL, 0, "OPTIONMODE", 0x08, regvalue, cur_col, wrap) | ||
| 90 | #endif | ||
| 91 | |||
| 92 | #if AIC_DEBUG_REGISTERS | ||
| 93 | ahc_reg_print_t ahc_targcrccnt_print; | ||
| 94 | #else | ||
| 95 | #define ahc_targcrccnt_print(regvalue, cur_col, wrap) \ | ||
| 96 | ahc_print_register(NULL, 0, "TARGCRCCNT", 0x0a, regvalue, cur_col, wrap) | ||
| 97 | #endif | ||
| 98 | |||
| 99 | #if AIC_DEBUG_REGISTERS | ||
| 100 | ahc_reg_print_t ahc_clrsint0_print; | ||
| 101 | #else | ||
| 102 | #define ahc_clrsint0_print(regvalue, cur_col, wrap) \ | ||
| 103 | ahc_print_register(NULL, 0, "CLRSINT0", 0x0b, regvalue, cur_col, wrap) | ||
| 104 | #endif | ||
| 105 | |||
| 106 | #if AIC_DEBUG_REGISTERS | ||
| 107 | ahc_reg_print_t ahc_sstat0_print; | 44 | ahc_reg_print_t ahc_sstat0_print; |
| 108 | #else | 45 | #else |
| 109 | #define ahc_sstat0_print(regvalue, cur_col, wrap) \ | 46 | #define ahc_sstat0_print(regvalue, cur_col, wrap) \ |
| @@ -111,13 +48,6 @@ ahc_reg_print_t ahc_sstat0_print; | |||
| 111 | #endif | 48 | #endif |
| 112 | 49 | ||
| 113 | #if AIC_DEBUG_REGISTERS | 50 | #if AIC_DEBUG_REGISTERS |
| 114 | ahc_reg_print_t ahc_clrsint1_print; | ||
| 115 | #else | ||
| 116 | #define ahc_clrsint1_print(regvalue, cur_col, wrap) \ | ||
| 117 | ahc_print_register(NULL, 0, "CLRSINT1", 0x0c, regvalue, cur_col, wrap) | ||
| 118 | #endif | ||
| 119 | |||
| 120 | #if AIC_DEBUG_REGISTERS | ||
| 121 | ahc_reg_print_t ahc_sstat1_print; | 51 | ahc_reg_print_t ahc_sstat1_print; |
| 122 | #else | 52 | #else |
| 123 | #define ahc_sstat1_print(regvalue, cur_col, wrap) \ | 53 | #define ahc_sstat1_print(regvalue, cur_col, wrap) \ |
| @@ -139,13 +69,6 @@ ahc_reg_print_t ahc_sstat3_print; | |||
| 139 | #endif | 69 | #endif |
| 140 | 70 | ||
| 141 | #if AIC_DEBUG_REGISTERS | 71 | #if AIC_DEBUG_REGISTERS |
| 142 | ahc_reg_print_t ahc_scsiid_ultra2_print; | ||
| 143 | #else | ||
| 144 | #define ahc_scsiid_ultra2_print(regvalue, cur_col, wrap) \ | ||
| 145 | ahc_print_register(NULL, 0, "SCSIID_ULTRA2", 0x0f, regvalue, cur_col, wrap) | ||
| 146 | #endif | ||
| 147 | |||
| 148 | #if AIC_DEBUG_REGISTERS | ||
| 149 | ahc_reg_print_t ahc_simode0_print; | 72 | ahc_reg_print_t ahc_simode0_print; |
| 150 | #else | 73 | #else |
| 151 | #define ahc_simode0_print(regvalue, cur_col, wrap) \ | 74 | #define ahc_simode0_print(regvalue, cur_col, wrap) \ |
| @@ -167,76 +90,6 @@ ahc_reg_print_t ahc_scsibusl_print; | |||
| 167 | #endif | 90 | #endif |
| 168 | 91 | ||
| 169 | #if AIC_DEBUG_REGISTERS | 92 | #if AIC_DEBUG_REGISTERS |
| 170 | ahc_reg_print_t ahc_scsibush_print; | ||
| 171 | #else | ||
| 172 | #define ahc_scsibush_print(regvalue, cur_col, wrap) \ | ||
| 173 | ahc_print_register(NULL, 0, "SCSIBUSH", 0x13, regvalue, cur_col, wrap) | ||
| 174 | #endif | ||
| 175 | |||
| 176 | #if AIC_DEBUG_REGISTERS | ||
| 177 | ahc_reg_print_t ahc_sxfrctl2_print; | ||
| 178 | #else | ||
| 179 | #define ahc_sxfrctl2_print(regvalue, cur_col, wrap) \ | ||
| 180 | ahc_print_register(NULL, 0, "SXFRCTL2", 0x13, regvalue, cur_col, wrap) | ||
| 181 | #endif | ||
| 182 | |||
| 183 | #if AIC_DEBUG_REGISTERS | ||
| 184 | ahc_reg_print_t ahc_shaddr_print; | ||
| 185 | #else | ||
| 186 | #define ahc_shaddr_print(regvalue, cur_col, wrap) \ | ||
| 187 | ahc_print_register(NULL, 0, "SHADDR", 0x14, regvalue, cur_col, wrap) | ||
| 188 | #endif | ||
| 189 | |||
| 190 | #if AIC_DEBUG_REGISTERS | ||
| 191 | ahc_reg_print_t ahc_seltimer_print; | ||
| 192 | #else | ||
| 193 | #define ahc_seltimer_print(regvalue, cur_col, wrap) \ | ||
| 194 | ahc_print_register(NULL, 0, "SELTIMER", 0x18, regvalue, cur_col, wrap) | ||
| 195 | #endif | ||
| 196 | |||
| 197 | #if AIC_DEBUG_REGISTERS | ||
| 198 | ahc_reg_print_t ahc_selid_print; | ||
| 199 | #else | ||
| 200 | #define ahc_selid_print(regvalue, cur_col, wrap) \ | ||
| 201 | ahc_print_register(NULL, 0, "SELID", 0x19, regvalue, cur_col, wrap) | ||
| 202 | #endif | ||
| 203 | |||
| 204 | #if AIC_DEBUG_REGISTERS | ||
| 205 | ahc_reg_print_t ahc_scamctl_print; | ||
| 206 | #else | ||
| 207 | #define ahc_scamctl_print(regvalue, cur_col, wrap) \ | ||
| 208 | ahc_print_register(NULL, 0, "SCAMCTL", 0x1a, regvalue, cur_col, wrap) | ||
| 209 | #endif | ||
| 210 | |||
| 211 | #if AIC_DEBUG_REGISTERS | ||
| 212 | ahc_reg_print_t ahc_targid_print; | ||
| 213 | #else | ||
| 214 | #define ahc_targid_print(regvalue, cur_col, wrap) \ | ||
| 215 | ahc_print_register(NULL, 0, "TARGID", 0x1b, regvalue, cur_col, wrap) | ||
| 216 | #endif | ||
| 217 | |||
| 218 | #if AIC_DEBUG_REGISTERS | ||
| 219 | ahc_reg_print_t ahc_spiocap_print; | ||
| 220 | #else | ||
| 221 | #define ahc_spiocap_print(regvalue, cur_col, wrap) \ | ||
| 222 | ahc_print_register(NULL, 0, "SPIOCAP", 0x1b, regvalue, cur_col, wrap) | ||
| 223 | #endif | ||
| 224 | |||
| 225 | #if AIC_DEBUG_REGISTERS | ||
| 226 | ahc_reg_print_t ahc_brdctl_print; | ||
| 227 | #else | ||
| 228 | #define ahc_brdctl_print(regvalue, cur_col, wrap) \ | ||
| 229 | ahc_print_register(NULL, 0, "BRDCTL", 0x1d, regvalue, cur_col, wrap) | ||
| 230 | #endif | ||
| 231 | |||
| 232 | #if AIC_DEBUG_REGISTERS | ||
| 233 | ahc_reg_print_t ahc_seectl_print; | ||
| 234 | #else | ||
| 235 | #define ahc_seectl_print(regvalue, cur_col, wrap) \ | ||
| 236 | ahc_print_register(NULL, 0, "SEECTL", 0x1e, regvalue, cur_col, wrap) | ||
| 237 | #endif | ||
| 238 | |||
| 239 | #if AIC_DEBUG_REGISTERS | ||
| 240 | ahc_reg_print_t ahc_sblkctl_print; | 93 | ahc_reg_print_t ahc_sblkctl_print; |
| 241 | #else | 94 | #else |
| 242 | #define ahc_sblkctl_print(regvalue, cur_col, wrap) \ | 95 | #define ahc_sblkctl_print(regvalue, cur_col, wrap) \ |
| @@ -244,62 +97,6 @@ ahc_reg_print_t ahc_sblkctl_print; | |||
| 244 | #endif | 97 | #endif |
| 245 | 98 | ||
| 246 | #if AIC_DEBUG_REGISTERS | 99 | #if AIC_DEBUG_REGISTERS |
| 247 | ahc_reg_print_t ahc_busy_targets_print; | ||
| 248 | #else | ||
| 249 | #define ahc_busy_targets_print(regvalue, cur_col, wrap) \ | ||
| 250 | ahc_print_register(NULL, 0, "BUSY_TARGETS", 0x20, regvalue, cur_col, wrap) | ||
| 251 | #endif | ||
| 252 | |||
| 253 | #if AIC_DEBUG_REGISTERS | ||
| 254 | ahc_reg_print_t ahc_ultra_enb_print; | ||
| 255 | #else | ||
| 256 | #define ahc_ultra_enb_print(regvalue, cur_col, wrap) \ | ||
| 257 | ahc_print_register(NULL, 0, "ULTRA_ENB", 0x30, regvalue, cur_col, wrap) | ||
| 258 | #endif | ||
| 259 | |||
| 260 | #if AIC_DEBUG_REGISTERS | ||
| 261 | ahc_reg_print_t ahc_disc_dsb_print; | ||
| 262 | #else | ||
| 263 | #define ahc_disc_dsb_print(regvalue, cur_col, wrap) \ | ||
| 264 | ahc_print_register(NULL, 0, "DISC_DSB", 0x32, regvalue, cur_col, wrap) | ||
| 265 | #endif | ||
| 266 | |||
| 267 | #if AIC_DEBUG_REGISTERS | ||
| 268 | ahc_reg_print_t ahc_cmdsize_table_tail_print; | ||
| 269 | #else | ||
| 270 | #define ahc_cmdsize_table_tail_print(regvalue, cur_col, wrap) \ | ||
| 271 | ahc_print_register(NULL, 0, "CMDSIZE_TABLE_TAIL", 0x34, regvalue, cur_col, wrap) | ||
| 272 | #endif | ||
| 273 | |||
| 274 | #if AIC_DEBUG_REGISTERS | ||
| 275 | ahc_reg_print_t ahc_mwi_residual_print; | ||
| 276 | #else | ||
| 277 | #define ahc_mwi_residual_print(regvalue, cur_col, wrap) \ | ||
| 278 | ahc_print_register(NULL, 0, "MWI_RESIDUAL", 0x38, regvalue, cur_col, wrap) | ||
| 279 | #endif | ||
| 280 | |||
| 281 | #if AIC_DEBUG_REGISTERS | ||
| 282 | ahc_reg_print_t ahc_next_queued_scb_print; | ||
| 283 | #else | ||
| 284 | #define ahc_next_queued_scb_print(regvalue, cur_col, wrap) \ | ||
| 285 | ahc_print_register(NULL, 0, "NEXT_QUEUED_SCB", 0x39, regvalue, cur_col, wrap) | ||
| 286 | #endif | ||
| 287 | |||
| 288 | #if AIC_DEBUG_REGISTERS | ||
| 289 | ahc_reg_print_t ahc_msg_out_print; | ||
| 290 | #else | ||
| 291 | #define ahc_msg_out_print(regvalue, cur_col, wrap) \ | ||
| 292 | ahc_print_register(NULL, 0, "MSG_OUT", 0x3a, regvalue, cur_col, wrap) | ||
| 293 | #endif | ||
| 294 | |||
| 295 | #if AIC_DEBUG_REGISTERS | ||
| 296 | ahc_reg_print_t ahc_dmaparams_print; | ||
| 297 | #else | ||
| 298 | #define ahc_dmaparams_print(regvalue, cur_col, wrap) \ | ||
| 299 | ahc_print_register(NULL, 0, "DMAPARAMS", 0x3b, regvalue, cur_col, wrap) | ||
| 300 | #endif | ||
| 301 | |||
| 302 | #if AIC_DEBUG_REGISTERS | ||
| 303 | ahc_reg_print_t ahc_seq_flags_print; | 100 | ahc_reg_print_t ahc_seq_flags_print; |
| 304 | #else | 101 | #else |
| 305 | #define ahc_seq_flags_print(regvalue, cur_col, wrap) \ | 102 | #define ahc_seq_flags_print(regvalue, cur_col, wrap) \ |
| @@ -307,20 +104,6 @@ ahc_reg_print_t ahc_seq_flags_print; | |||
| 307 | #endif | 104 | #endif |
| 308 | 105 | ||
| 309 | #if AIC_DEBUG_REGISTERS | 106 | #if AIC_DEBUG_REGISTERS |
| 310 | ahc_reg_print_t ahc_saved_scsiid_print; | ||
| 311 | #else | ||
| 312 | #define ahc_saved_scsiid_print(regvalue, cur_col, wrap) \ | ||
| 313 | ahc_print_register(NULL, 0, "SAVED_SCSIID", 0x3d, regvalue, cur_col, wrap) | ||
| 314 | #endif | ||
| 315 | |||
| 316 | #if AIC_DEBUG_REGISTERS | ||
| 317 | ahc_reg_print_t ahc_saved_lun_print; | ||
| 318 | #else | ||
| 319 | #define ahc_saved_lun_print(regvalue, cur_col, wrap) \ | ||
| 320 | ahc_print_register(NULL, 0, "SAVED_LUN", 0x3e, regvalue, cur_col, wrap) | ||
| 321 | #endif | ||
| 322 | |||
| 323 | #if AIC_DEBUG_REGISTERS | ||
| 324 | ahc_reg_print_t ahc_lastphase_print; | 107 | ahc_reg_print_t ahc_lastphase_print; |
| 325 | #else | 108 | #else |
| 326 | #define ahc_lastphase_print(regvalue, cur_col, wrap) \ | 109 | #define ahc_lastphase_print(regvalue, cur_col, wrap) \ |
| @@ -328,153 +111,6 @@ ahc_reg_print_t ahc_lastphase_print; | |||
| 328 | #endif | 111 | #endif |
| 329 | 112 | ||
| 330 | #if AIC_DEBUG_REGISTERS | 113 | #if AIC_DEBUG_REGISTERS |
| 331 | ahc_reg_print_t ahc_waiting_scbh_print; | ||
| 332 | #else | ||
| 333 | #define ahc_waiting_scbh_print(regvalue, cur_col, wrap) \ | ||
| 334 | ahc_print_register(NULL, 0, "WAITING_SCBH", 0x40, regvalue, cur_col, wrap) | ||
| 335 | #endif | ||
| 336 | |||
| 337 | #if AIC_DEBUG_REGISTERS | ||
| 338 | ahc_reg_print_t ahc_disconnected_scbh_print; | ||
| 339 | #else | ||
| 340 | #define ahc_disconnected_scbh_print(regvalue, cur_col, wrap) \ | ||
| 341 | ahc_print_register(NULL, 0, "DISCONNECTED_SCBH", 0x41, regvalue, cur_col, wrap) | ||
| 342 | #endif | ||
| 343 | |||
| 344 | #if AIC_DEBUG_REGISTERS | ||
| 345 | ahc_reg_print_t ahc_free_scbh_print; | ||
| 346 | #else | ||
| 347 | #define ahc_free_scbh_print(regvalue, cur_col, wrap) \ | ||
| 348 | ahc_print_register(NULL, 0, "FREE_SCBH", 0x42, regvalue, cur_col, wrap) | ||
| 349 | #endif | ||
| 350 | |||
| 351 | #if AIC_DEBUG_REGISTERS | ||
| 352 | ahc_reg_print_t ahc_complete_scbh_print; | ||
| 353 | #else | ||
| 354 | #define ahc_complete_scbh_print(regvalue, cur_col, wrap) \ | ||
| 355 | ahc_print_register(NULL, 0, "COMPLETE_SCBH", 0x43, regvalue, cur_col, wrap) | ||
| 356 | #endif | ||
| 357 | |||
| 358 | #if AIC_DEBUG_REGISTERS | ||
| 359 | ahc_reg_print_t ahc_hscb_addr_print; | ||
| 360 | #else | ||
| 361 | #define ahc_hscb_addr_print(regvalue, cur_col, wrap) \ | ||
| 362 | ahc_print_register(NULL, 0, "HSCB_ADDR", 0x44, regvalue, cur_col, wrap) | ||
| 363 | #endif | ||
| 364 | |||
| 365 | #if AIC_DEBUG_REGISTERS | ||
| 366 | ahc_reg_print_t ahc_shared_data_addr_print; | ||
| 367 | #else | ||
| 368 | #define ahc_shared_data_addr_print(regvalue, cur_col, wrap) \ | ||
| 369 | ahc_print_register(NULL, 0, "SHARED_DATA_ADDR", 0x48, regvalue, cur_col, wrap) | ||
| 370 | #endif | ||
| 371 | |||
| 372 | #if AIC_DEBUG_REGISTERS | ||
| 373 | ahc_reg_print_t ahc_kernel_qinpos_print; | ||
| 374 | #else | ||
| 375 | #define ahc_kernel_qinpos_print(regvalue, cur_col, wrap) \ | ||
| 376 | ahc_print_register(NULL, 0, "KERNEL_QINPOS", 0x4c, regvalue, cur_col, wrap) | ||
| 377 | #endif | ||
| 378 | |||
| 379 | #if AIC_DEBUG_REGISTERS | ||
| 380 | ahc_reg_print_t ahc_qinpos_print; | ||
| 381 | #else | ||
| 382 | #define ahc_qinpos_print(regvalue, cur_col, wrap) \ | ||
| 383 | ahc_print_register(NULL, 0, "QINPOS", 0x4d, regvalue, cur_col, wrap) | ||
| 384 | #endif | ||
| 385 | |||
| 386 | #if AIC_DEBUG_REGISTERS | ||
| 387 | ahc_reg_print_t ahc_qoutpos_print; | ||
| 388 | #else | ||
| 389 | #define ahc_qoutpos_print(regvalue, cur_col, wrap) \ | ||
| 390 | ahc_print_register(NULL, 0, "QOUTPOS", 0x4e, regvalue, cur_col, wrap) | ||
| 391 | #endif | ||
| 392 | |||
| 393 | #if AIC_DEBUG_REGISTERS | ||
| 394 | ahc_reg_print_t ahc_kernel_tqinpos_print; | ||
| 395 | #else | ||
| 396 | #define ahc_kernel_tqinpos_print(regvalue, cur_col, wrap) \ | ||
| 397 | ahc_print_register(NULL, 0, "KERNEL_TQINPOS", 0x4f, regvalue, cur_col, wrap) | ||
| 398 | #endif | ||
| 399 | |||
| 400 | #if AIC_DEBUG_REGISTERS | ||
| 401 | ahc_reg_print_t ahc_tqinpos_print; | ||
| 402 | #else | ||
| 403 | #define ahc_tqinpos_print(regvalue, cur_col, wrap) \ | ||
| 404 | ahc_print_register(NULL, 0, "TQINPOS", 0x50, regvalue, cur_col, wrap) | ||
| 405 | #endif | ||
| 406 | |||
| 407 | #if AIC_DEBUG_REGISTERS | ||
| 408 | ahc_reg_print_t ahc_arg_1_print; | ||
| 409 | #else | ||
| 410 | #define ahc_arg_1_print(regvalue, cur_col, wrap) \ | ||
| 411 | ahc_print_register(NULL, 0, "ARG_1", 0x51, regvalue, cur_col, wrap) | ||
| 412 | #endif | ||
| 413 | |||
| 414 | #if AIC_DEBUG_REGISTERS | ||
| 415 | ahc_reg_print_t ahc_arg_2_print; | ||
| 416 | #else | ||
| 417 | #define ahc_arg_2_print(regvalue, cur_col, wrap) \ | ||
| 418 | ahc_print_register(NULL, 0, "ARG_2", 0x52, regvalue, cur_col, wrap) | ||
| 419 | #endif | ||
| 420 | |||
| 421 | #if AIC_DEBUG_REGISTERS | ||
| 422 | ahc_reg_print_t ahc_last_msg_print; | ||
| 423 | #else | ||
| 424 | #define ahc_last_msg_print(regvalue, cur_col, wrap) \ | ||
| 425 | ahc_print_register(NULL, 0, "LAST_MSG", 0x53, regvalue, cur_col, wrap) | ||
| 426 | #endif | ||
| 427 | |||
| 428 | #if AIC_DEBUG_REGISTERS | ||
| 429 | ahc_reg_print_t ahc_scsiseq_template_print; | ||
| 430 | #else | ||
| 431 | #define ahc_scsiseq_template_print(regvalue, cur_col, wrap) \ | ||
| 432 | ahc_print_register(NULL, 0, "SCSISEQ_TEMPLATE", 0x54, regvalue, cur_col, wrap) | ||
| 433 | #endif | ||
| 434 | |||
| 435 | #if AIC_DEBUG_REGISTERS | ||
| 436 | ahc_reg_print_t ahc_ha_274_biosglobal_print; | ||
| 437 | #else | ||
| 438 | #define ahc_ha_274_biosglobal_print(regvalue, cur_col, wrap) \ | ||
| 439 | ahc_print_register(NULL, 0, "HA_274_BIOSGLOBAL", 0x56, regvalue, cur_col, wrap) | ||
| 440 | #endif | ||
| 441 | |||
| 442 | #if AIC_DEBUG_REGISTERS | ||
| 443 | ahc_reg_print_t ahc_seq_flags2_print; | ||
| 444 | #else | ||
| 445 | #define ahc_seq_flags2_print(regvalue, cur_col, wrap) \ | ||
| 446 | ahc_print_register(NULL, 0, "SEQ_FLAGS2", 0x57, regvalue, cur_col, wrap) | ||
| 447 | #endif | ||
| 448 | |||
| 449 | #if AIC_DEBUG_REGISTERS | ||
| 450 | ahc_reg_print_t ahc_scsiconf_print; | ||
| 451 | #else | ||
| 452 | #define ahc_scsiconf_print(regvalue, cur_col, wrap) \ | ||
| 453 | ahc_print_register(NULL, 0, "SCSICONF", 0x5a, regvalue, cur_col, wrap) | ||
| 454 | #endif | ||
| 455 | |||
| 456 | #if AIC_DEBUG_REGISTERS | ||
| 457 | ahc_reg_print_t ahc_intdef_print; | ||
| 458 | #else | ||
| 459 | #define ahc_intdef_print(regvalue, cur_col, wrap) \ | ||
| 460 | ahc_print_register(NULL, 0, "INTDEF", 0x5c, regvalue, cur_col, wrap) | ||
| 461 | #endif | ||
| 462 | |||
| 463 | #if AIC_DEBUG_REGISTERS | ||
| 464 | ahc_reg_print_t ahc_hostconf_print; | ||
| 465 | #else | ||
| 466 | #define ahc_hostconf_print(regvalue, cur_col, wrap) \ | ||
| 467 | ahc_print_register(NULL, 0, "HOSTCONF", 0x5d, regvalue, cur_col, wrap) | ||
| 468 | #endif | ||
| 469 | |||
| 470 | #if AIC_DEBUG_REGISTERS | ||
| 471 | ahc_reg_print_t ahc_ha_274_biosctrl_print; | ||
| 472 | #else | ||
| 473 | #define ahc_ha_274_biosctrl_print(regvalue, cur_col, wrap) \ | ||
| 474 | ahc_print_register(NULL, 0, "HA_274_BIOSCTRL", 0x5f, regvalue, cur_col, wrap) | ||
| 475 | #endif | ||
| 476 | |||
| 477 | #if AIC_DEBUG_REGISTERS | ||
| 478 | ahc_reg_print_t ahc_seqctl_print; | 114 | ahc_reg_print_t ahc_seqctl_print; |
| 479 | #else | 115 | #else |
| 480 | #define ahc_seqctl_print(regvalue, cur_col, wrap) \ | 116 | #define ahc_seqctl_print(regvalue, cur_col, wrap) \ |
| @@ -482,111 +118,6 @@ ahc_reg_print_t ahc_seqctl_print; | |||
| 482 | #endif | 118 | #endif |
| 483 | 119 | ||
| 484 | #if AIC_DEBUG_REGISTERS | 120 | #if AIC_DEBUG_REGISTERS |
| 485 | ahc_reg_print_t ahc_seqram_print; | ||
| 486 | #else | ||
| 487 | #define ahc_seqram_print(regvalue, cur_col, wrap) \ | ||
| 488 | ahc_print_register(NULL, 0, "SEQRAM", 0x61, regvalue, cur_col, wrap) | ||
| 489 | #endif | ||
| 490 | |||
| 491 | #if AIC_DEBUG_REGISTERS | ||
| 492 | ahc_reg_print_t ahc_seqaddr0_print; | ||
| 493 | #else | ||
| 494 | #define ahc_seqaddr0_print(regvalue, cur_col, wrap) \ | ||
| 495 | ahc_print_register(NULL, 0, "SEQADDR0", 0x62, regvalue, cur_col, wrap) | ||
| 496 | #endif | ||
| 497 | |||
| 498 | #if AIC_DEBUG_REGISTERS | ||
| 499 | ahc_reg_print_t ahc_seqaddr1_print; | ||
| 500 | #else | ||
| 501 | #define ahc_seqaddr1_print(regvalue, cur_col, wrap) \ | ||
| 502 | ahc_print_register(NULL, 0, "SEQADDR1", 0x63, regvalue, cur_col, wrap) | ||
| 503 | #endif | ||
| 504 | |||
| 505 | #if AIC_DEBUG_REGISTERS | ||
| 506 | ahc_reg_print_t ahc_accum_print; | ||
| 507 | #else | ||
| 508 | #define ahc_accum_print(regvalue, cur_col, wrap) \ | ||
| 509 | ahc_print_register(NULL, 0, "ACCUM", 0x64, regvalue, cur_col, wrap) | ||
| 510 | #endif | ||
| 511 | |||
| 512 | #if AIC_DEBUG_REGISTERS | ||
| 513 | ahc_reg_print_t ahc_sindex_print; | ||
| 514 | #else | ||
| 515 | #define ahc_sindex_print(regvalue, cur_col, wrap) \ | ||
| 516 | ahc_print_register(NULL, 0, "SINDEX", 0x65, regvalue, cur_col, wrap) | ||
| 517 | #endif | ||
| 518 | |||
| 519 | #if AIC_DEBUG_REGISTERS | ||
| 520 | ahc_reg_print_t ahc_dindex_print; | ||
| 521 | #else | ||
| 522 | #define ahc_dindex_print(regvalue, cur_col, wrap) \ | ||
| 523 | ahc_print_register(NULL, 0, "DINDEX", 0x66, regvalue, cur_col, wrap) | ||
| 524 | #endif | ||
| 525 | |||
| 526 | #if AIC_DEBUG_REGISTERS | ||
| 527 | ahc_reg_print_t ahc_allones_print; | ||
| 528 | #else | ||
| 529 | #define ahc_allones_print(regvalue, cur_col, wrap) \ | ||
| 530 | ahc_print_register(NULL, 0, "ALLONES", 0x69, regvalue, cur_col, wrap) | ||
| 531 | #endif | ||
| 532 | |||
| 533 | #if AIC_DEBUG_REGISTERS | ||
| 534 | ahc_reg_print_t ahc_allzeros_print; | ||
| 535 | #else | ||
| 536 | #define ahc_allzeros_print(regvalue, cur_col, wrap) \ | ||
| 537 | ahc_print_register(NULL, 0, "ALLZEROS", 0x6a, regvalue, cur_col, wrap) | ||
| 538 | #endif | ||
| 539 | |||
| 540 | #if AIC_DEBUG_REGISTERS | ||
| 541 | ahc_reg_print_t ahc_none_print; | ||
| 542 | #else | ||
| 543 | #define ahc_none_print(regvalue, cur_col, wrap) \ | ||
| 544 | ahc_print_register(NULL, 0, "NONE", 0x6a, regvalue, cur_col, wrap) | ||
| 545 | #endif | ||
| 546 | |||
| 547 | #if AIC_DEBUG_REGISTERS | ||
| 548 | ahc_reg_print_t ahc_flags_print; | ||
| 549 | #else | ||
| 550 | #define ahc_flags_print(regvalue, cur_col, wrap) \ | ||
| 551 | ahc_print_register(NULL, 0, "FLAGS", 0x6b, regvalue, cur_col, wrap) | ||
| 552 | #endif | ||
| 553 | |||
| 554 | #if AIC_DEBUG_REGISTERS | ||
| 555 | ahc_reg_print_t ahc_sindir_print; | ||
| 556 | #else | ||
| 557 | #define ahc_sindir_print(regvalue, cur_col, wrap) \ | ||
| 558 | ahc_print_register(NULL, 0, "SINDIR", 0x6c, regvalue, cur_col, wrap) | ||
| 559 | #endif | ||
| 560 | |||
| 561 | #if AIC_DEBUG_REGISTERS | ||
| 562 | ahc_reg_print_t ahc_dindir_print; | ||
| 563 | #else | ||
| 564 | #define ahc_dindir_print(regvalue, cur_col, wrap) \ | ||
| 565 | ahc_print_register(NULL, 0, "DINDIR", 0x6d, regvalue, cur_col, wrap) | ||
| 566 | #endif | ||
| 567 | |||
| 568 | #if AIC_DEBUG_REGISTERS | ||
| 569 | ahc_reg_print_t ahc_function1_print; | ||
| 570 | #else | ||
| 571 | #define ahc_function1_print(regvalue, cur_col, wrap) \ | ||
| 572 | ahc_print_register(NULL, 0, "FUNCTION1", 0x6e, regvalue, cur_col, wrap) | ||
| 573 | #endif | ||
| 574 | |||
| 575 | #if AIC_DEBUG_REGISTERS | ||
| 576 | ahc_reg_print_t ahc_stack_print; | ||
| 577 | #else | ||
| 578 | #define ahc_stack_print(regvalue, cur_col, wrap) \ | ||
| 579 | ahc_print_register(NULL, 0, "STACK", 0x6f, regvalue, cur_col, wrap) | ||
| 580 | #endif | ||
| 581 | |||
| 582 | #if AIC_DEBUG_REGISTERS | ||
| 583 | ahc_reg_print_t ahc_targ_offset_print; | ||
| 584 | #else | ||
| 585 | #define ahc_targ_offset_print(regvalue, cur_col, wrap) \ | ||
| 586 | ahc_print_register(NULL, 0, "TARG_OFFSET", 0x70, regvalue, cur_col, wrap) | ||
| 587 | #endif | ||
| 588 | |||
| 589 | #if AIC_DEBUG_REGISTERS | ||
| 590 | ahc_reg_print_t ahc_sram_base_print; | 121 | ahc_reg_print_t ahc_sram_base_print; |
| 591 | #else | 122 | #else |
| 592 | #define ahc_sram_base_print(regvalue, cur_col, wrap) \ | 123 | #define ahc_sram_base_print(regvalue, cur_col, wrap) \ |
| @@ -594,97 +125,6 @@ ahc_reg_print_t ahc_sram_base_print; | |||
| 594 | #endif | 125 | #endif |
| 595 | 126 | ||
| 596 | #if AIC_DEBUG_REGISTERS | 127 | #if AIC_DEBUG_REGISTERS |
| 597 | ahc_reg_print_t ahc_bctl_print; | ||
| 598 | #else | ||
| 599 | #define ahc_bctl_print(regvalue, cur_col, wrap) \ | ||
| 600 | ahc_print_register(NULL, 0, "BCTL", 0x84, regvalue, cur_col, wrap) | ||
| 601 | #endif | ||
| 602 | |||
| 603 | #if AIC_DEBUG_REGISTERS | ||
| 604 | ahc_reg_print_t ahc_dscommand0_print; | ||
| 605 | #else | ||
| 606 | #define ahc_dscommand0_print(regvalue, cur_col, wrap) \ | ||
| 607 | ahc_print_register(NULL, 0, "DSCOMMAND0", 0x84, regvalue, cur_col, wrap) | ||
| 608 | #endif | ||
| 609 | |||
| 610 | #if AIC_DEBUG_REGISTERS | ||
| 611 | ahc_reg_print_t ahc_bustime_print; | ||
| 612 | #else | ||
| 613 | #define ahc_bustime_print(regvalue, cur_col, wrap) \ | ||
| 614 | ahc_print_register(NULL, 0, "BUSTIME", 0x85, regvalue, cur_col, wrap) | ||
| 615 | #endif | ||
| 616 | |||
| 617 | #if AIC_DEBUG_REGISTERS | ||
| 618 | ahc_reg_print_t ahc_dscommand1_print; | ||
| 619 | #else | ||
| 620 | #define ahc_dscommand1_print(regvalue, cur_col, wrap) \ | ||
| 621 | ahc_print_register(NULL, 0, "DSCOMMAND1", 0x85, regvalue, cur_col, wrap) | ||
| 622 | #endif | ||
| 623 | |||
| 624 | #if AIC_DEBUG_REGISTERS | ||
| 625 | ahc_reg_print_t ahc_busspd_print; | ||
| 626 | #else | ||
| 627 | #define ahc_busspd_print(regvalue, cur_col, wrap) \ | ||
| 628 | ahc_print_register(NULL, 0, "BUSSPD", 0x86, regvalue, cur_col, wrap) | ||
| 629 | #endif | ||
| 630 | |||
| 631 | #if AIC_DEBUG_REGISTERS | ||
| 632 | ahc_reg_print_t ahc_hs_mailbox_print; | ||
| 633 | #else | ||
| 634 | #define ahc_hs_mailbox_print(regvalue, cur_col, wrap) \ | ||
| 635 | ahc_print_register(NULL, 0, "HS_MAILBOX", 0x86, regvalue, cur_col, wrap) | ||
| 636 | #endif | ||
| 637 | |||
| 638 | #if AIC_DEBUG_REGISTERS | ||
| 639 | ahc_reg_print_t ahc_dspcistatus_print; | ||
| 640 | #else | ||
| 641 | #define ahc_dspcistatus_print(regvalue, cur_col, wrap) \ | ||
| 642 | ahc_print_register(NULL, 0, "DSPCISTATUS", 0x86, regvalue, cur_col, wrap) | ||
| 643 | #endif | ||
| 644 | |||
| 645 | #if AIC_DEBUG_REGISTERS | ||
| 646 | ahc_reg_print_t ahc_hcntrl_print; | ||
| 647 | #else | ||
| 648 | #define ahc_hcntrl_print(regvalue, cur_col, wrap) \ | ||
| 649 | ahc_print_register(NULL, 0, "HCNTRL", 0x87, regvalue, cur_col, wrap) | ||
| 650 | #endif | ||
| 651 | |||
| 652 | #if AIC_DEBUG_REGISTERS | ||
| 653 | ahc_reg_print_t ahc_haddr_print; | ||
| 654 | #else | ||
| 655 | #define ahc_haddr_print(regvalue, cur_col, wrap) \ | ||
| 656 | ahc_print_register(NULL, 0, "HADDR", 0x88, regvalue, cur_col, wrap) | ||
| 657 | #endif | ||
| 658 | |||
| 659 | #if AIC_DEBUG_REGISTERS | ||
| 660 | ahc_reg_print_t ahc_hcnt_print; | ||
| 661 | #else | ||
| 662 | #define ahc_hcnt_print(regvalue, cur_col, wrap) \ | ||
| 663 | ahc_print_register(NULL, 0, "HCNT", 0x8c, regvalue, cur_col, wrap) | ||
| 664 | #endif | ||
| 665 | |||
| 666 | #if AIC_DEBUG_REGISTERS | ||
| 667 | ahc_reg_print_t ahc_scbptr_print; | ||
| 668 | #else | ||
| 669 | #define ahc_scbptr_print(regvalue, cur_col, wrap) \ | ||
| 670 | ahc_print_register(NULL, 0, "SCBPTR", 0x90, regvalue, cur_col, wrap) | ||
| 671 | #endif | ||
| 672 | |||
| 673 | #if AIC_DEBUG_REGISTERS | ||
| 674 | ahc_reg_print_t ahc_intstat_print; | ||
| 675 | #else | ||
| 676 | #define ahc_intstat_print(regvalue, cur_col, wrap) \ | ||
| 677 | ahc_print_register(NULL, 0, "INTSTAT", 0x91, regvalue, cur_col, wrap) | ||
| 678 | #endif | ||
| 679 | |||
| 680 | #if AIC_DEBUG_REGISTERS | ||
| 681 | ahc_reg_print_t ahc_clrint_print; | ||
| 682 | #else | ||
| 683 | #define ahc_clrint_print(regvalue, cur_col, wrap) \ | ||
| 684 | ahc_print_register(NULL, 0, "CLRINT", 0x92, regvalue, cur_col, wrap) | ||
| 685 | #endif | ||
| 686 | |||
| 687 | #if AIC_DEBUG_REGISTERS | ||
| 688 | ahc_reg_print_t ahc_error_print; | 128 | ahc_reg_print_t ahc_error_print; |
| 689 | #else | 129 | #else |
| 690 | #define ahc_error_print(regvalue, cur_col, wrap) \ | 130 | #define ahc_error_print(regvalue, cur_col, wrap) \ |
| @@ -706,69 +146,6 @@ ahc_reg_print_t ahc_dfstatus_print; | |||
| 706 | #endif | 146 | #endif |
| 707 | 147 | ||
| 708 | #if AIC_DEBUG_REGISTERS | 148 | #if AIC_DEBUG_REGISTERS |
| 709 | ahc_reg_print_t ahc_dfwaddr_print; | ||
| 710 | #else | ||
| 711 | #define ahc_dfwaddr_print(regvalue, cur_col, wrap) \ | ||
| 712 | ahc_print_register(NULL, 0, "DFWADDR", 0x95, regvalue, cur_col, wrap) | ||
| 713 | #endif | ||
| 714 | |||
| 715 | #if AIC_DEBUG_REGISTERS | ||
| 716 | ahc_reg_print_t ahc_dfraddr_print; | ||
| 717 | #else | ||
| 718 | #define ahc_dfraddr_print(regvalue, cur_col, wrap) \ | ||
| 719 | ahc_print_register(NULL, 0, "DFRADDR", 0x97, regvalue, cur_col, wrap) | ||
| 720 | #endif | ||
| 721 | |||
| 722 | #if AIC_DEBUG_REGISTERS | ||
| 723 | ahc_reg_print_t ahc_dfdat_print; | ||
| 724 | #else | ||
| 725 | #define ahc_dfdat_print(regvalue, cur_col, wrap) \ | ||
| 726 | ahc_print_register(NULL, 0, "DFDAT", 0x99, regvalue, cur_col, wrap) | ||
| 727 | #endif | ||
| 728 | |||
| 729 | #if AIC_DEBUG_REGISTERS | ||
| 730 | ahc_reg_print_t ahc_scbcnt_print; | ||
| 731 | #else | ||
| 732 | #define ahc_scbcnt_print(regvalue, cur_col, wrap) \ | ||
| 733 | ahc_print_register(NULL, 0, "SCBCNT", 0x9a, regvalue, cur_col, wrap) | ||
| 734 | #endif | ||
| 735 | |||
| 736 | #if AIC_DEBUG_REGISTERS | ||
| 737 | ahc_reg_print_t ahc_qinfifo_print; | ||
| 738 | #else | ||
| 739 | #define ahc_qinfifo_print(regvalue, cur_col, wrap) \ | ||
| 740 | ahc_print_register(NULL, 0, "QINFIFO", 0x9b, regvalue, cur_col, wrap) | ||
| 741 | #endif | ||
| 742 | |||
| 743 | #if AIC_DEBUG_REGISTERS | ||
| 744 | ahc_reg_print_t ahc_qincnt_print; | ||
| 745 | #else | ||
| 746 | #define ahc_qincnt_print(regvalue, cur_col, wrap) \ | ||
| 747 | ahc_print_register(NULL, 0, "QINCNT", 0x9c, regvalue, cur_col, wrap) | ||
| 748 | #endif | ||
| 749 | |||
| 750 | #if AIC_DEBUG_REGISTERS | ||
| 751 | ahc_reg_print_t ahc_qoutfifo_print; | ||
| 752 | #else | ||
| 753 | #define ahc_qoutfifo_print(regvalue, cur_col, wrap) \ | ||
| 754 | ahc_print_register(NULL, 0, "QOUTFIFO", 0x9d, regvalue, cur_col, wrap) | ||
| 755 | #endif | ||
| 756 | |||
| 757 | #if AIC_DEBUG_REGISTERS | ||
| 758 | ahc_reg_print_t ahc_crccontrol1_print; | ||
| 759 | #else | ||
| 760 | #define ahc_crccontrol1_print(regvalue, cur_col, wrap) \ | ||
| 761 | ahc_print_register(NULL, 0, "CRCCONTROL1", 0x9d, regvalue, cur_col, wrap) | ||
| 762 | #endif | ||
| 763 | |||
| 764 | #if AIC_DEBUG_REGISTERS | ||
| 765 | ahc_reg_print_t ahc_qoutcnt_print; | ||
| 766 | #else | ||
| 767 | #define ahc_qoutcnt_print(regvalue, cur_col, wrap) \ | ||
| 768 | ahc_print_register(NULL, 0, "QOUTCNT", 0x9e, regvalue, cur_col, wrap) | ||
| 769 | #endif | ||
| 770 | |||
| 771 | #if AIC_DEBUG_REGISTERS | ||
| 772 | ahc_reg_print_t ahc_scsiphase_print; | 149 | ahc_reg_print_t ahc_scsiphase_print; |
| 773 | #else | 150 | #else |
| 774 | #define ahc_scsiphase_print(regvalue, cur_col, wrap) \ | 151 | #define ahc_scsiphase_print(regvalue, cur_col, wrap) \ |
| @@ -776,13 +153,6 @@ ahc_reg_print_t ahc_scsiphase_print; | |||
| 776 | #endif | 153 | #endif |
| 777 | 154 | ||
| 778 | #if AIC_DEBUG_REGISTERS | 155 | #if AIC_DEBUG_REGISTERS |
| 779 | ahc_reg_print_t ahc_sfunct_print; | ||
| 780 | #else | ||
| 781 | #define ahc_sfunct_print(regvalue, cur_col, wrap) \ | ||
| 782 | ahc_print_register(NULL, 0, "SFUNCT", 0x9f, regvalue, cur_col, wrap) | ||
| 783 | #endif | ||
| 784 | |||
| 785 | #if AIC_DEBUG_REGISTERS | ||
| 786 | ahc_reg_print_t ahc_scb_base_print; | 156 | ahc_reg_print_t ahc_scb_base_print; |
| 787 | #else | 157 | #else |
| 788 | #define ahc_scb_base_print(regvalue, cur_col, wrap) \ | 158 | #define ahc_scb_base_print(regvalue, cur_col, wrap) \ |
| @@ -790,69 +160,6 @@ ahc_reg_print_t ahc_scb_base_print; | |||
| 790 | #endif | 160 | #endif |
| 791 | 161 | ||
| 792 | #if AIC_DEBUG_REGISTERS | 162 | #if AIC_DEBUG_REGISTERS |
| 793 | ahc_reg_print_t ahc_scb_cdb_ptr_print; | ||
| 794 | #else | ||
| 795 | #define ahc_scb_cdb_ptr_print(regvalue, cur_col, wrap) \ | ||
| 796 | ahc_print_register(NULL, 0, "SCB_CDB_PTR", 0xa0, regvalue, cur_col, wrap) | ||
| 797 | #endif | ||
| 798 | |||
| 799 | #if AIC_DEBUG_REGISTERS | ||
| 800 | ahc_reg_print_t ahc_scb_residual_sgptr_print; | ||
| 801 | #else | ||
| 802 | #define ahc_scb_residual_sgptr_print(regvalue, cur_col, wrap) \ | ||
| 803 | ahc_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", 0xa4, regvalue, cur_col, wrap) | ||
| 804 | #endif | ||
| 805 | |||
| 806 | #if AIC_DEBUG_REGISTERS | ||
| 807 | ahc_reg_print_t ahc_scb_scsi_status_print; | ||
| 808 | #else | ||
| 809 | #define ahc_scb_scsi_status_print(regvalue, cur_col, wrap) \ | ||
| 810 | ahc_print_register(NULL, 0, "SCB_SCSI_STATUS", 0xa8, regvalue, cur_col, wrap) | ||
| 811 | #endif | ||
| 812 | |||
| 813 | #if AIC_DEBUG_REGISTERS | ||
| 814 | ahc_reg_print_t ahc_scb_target_phases_print; | ||
| 815 | #else | ||
| 816 | #define ahc_scb_target_phases_print(regvalue, cur_col, wrap) \ | ||
| 817 | ahc_print_register(NULL, 0, "SCB_TARGET_PHASES", 0xa9, regvalue, cur_col, wrap) | ||
| 818 | #endif | ||
| 819 | |||
| 820 | #if AIC_DEBUG_REGISTERS | ||
| 821 | ahc_reg_print_t ahc_scb_target_data_dir_print; | ||
| 822 | #else | ||
| 823 | #define ahc_scb_target_data_dir_print(regvalue, cur_col, wrap) \ | ||
| 824 | ahc_print_register(NULL, 0, "SCB_TARGET_DATA_DIR", 0xaa, regvalue, cur_col, wrap) | ||
| 825 | #endif | ||
| 826 | |||
| 827 | #if AIC_DEBUG_REGISTERS | ||
| 828 | ahc_reg_print_t ahc_scb_target_itag_print; | ||
| 829 | #else | ||
| 830 | #define ahc_scb_target_itag_print(regvalue, cur_col, wrap) \ | ||
| 831 | ahc_print_register(NULL, 0, "SCB_TARGET_ITAG", 0xab, regvalue, cur_col, wrap) | ||
| 832 | #endif | ||
| 833 | |||
| 834 | #if AIC_DEBUG_REGISTERS | ||
| 835 | ahc_reg_print_t ahc_scb_dataptr_print; | ||
| 836 | #else | ||
| 837 | #define ahc_scb_dataptr_print(regvalue, cur_col, wrap) \ | ||
| 838 | ahc_print_register(NULL, 0, "SCB_DATAPTR", 0xac, regvalue, cur_col, wrap) | ||
| 839 | #endif | ||
| 840 | |||
| 841 | #if AIC_DEBUG_REGISTERS | ||
| 842 | ahc_reg_print_t ahc_scb_datacnt_print; | ||
| 843 | #else | ||
| 844 | #define ahc_scb_datacnt_print(regvalue, cur_col, wrap) \ | ||
| 845 | ahc_print_register(NULL, 0, "SCB_DATACNT", 0xb0, regvalue, cur_col, wrap) | ||
| 846 | #endif | ||
| 847 | |||
| 848 | #if AIC_DEBUG_REGISTERS | ||
| 849 | ahc_reg_print_t ahc_scb_sgptr_print; | ||
| 850 | #else | ||
| 851 | #define ahc_scb_sgptr_print(regvalue, cur_col, wrap) \ | ||
| 852 | ahc_print_register(NULL, 0, "SCB_SGPTR", 0xb4, regvalue, cur_col, wrap) | ||
| 853 | #endif | ||
| 854 | |||
| 855 | #if AIC_DEBUG_REGISTERS | ||
| 856 | ahc_reg_print_t ahc_scb_control_print; | 163 | ahc_reg_print_t ahc_scb_control_print; |
| 857 | #else | 164 | #else |
| 858 | #define ahc_scb_control_print(regvalue, cur_col, wrap) \ | 165 | #define ahc_scb_control_print(regvalue, cur_col, wrap) \ |
| @@ -880,188 +187,6 @@ ahc_reg_print_t ahc_scb_tag_print; | |||
| 880 | ahc_print_register(NULL, 0, "SCB_TAG", 0xbb, regvalue, cur_col, wrap) | 187 | ahc_print_register(NULL, 0, "SCB_TAG", 0xbb, regvalue, cur_col, wrap) |
| 881 | #endif | 188 | #endif |
| 882 | 189 | ||
| 883 | #if AIC_DEBUG_REGISTERS | ||
| 884 | ahc_reg_print_t ahc_scb_cdb_len_print; | ||
| 885 | #else | ||
| 886 | #define ahc_scb_cdb_len_print(regvalue, cur_col, wrap) \ | ||
| 887 | ahc_print_register(NULL, 0, "SCB_CDB_LEN", 0xbc, regvalue, cur_col, wrap) | ||
| 888 | #endif | ||
| 889 | |||
| 890 | #if AIC_DEBUG_REGISTERS | ||
| 891 | ahc_reg_print_t ahc_scb_scsirate_print; | ||
| 892 | #else | ||
| 893 | #define ahc_scb_scsirate_print(regvalue, cur_col, wrap) \ | ||
| 894 | ahc_print_register(NULL, 0, "SCB_SCSIRATE", 0xbd, regvalue, cur_col, wrap) | ||
| 895 | #endif | ||
| 896 | |||
| 897 | #if AIC_DEBUG_REGISTERS | ||
| 898 | ahc_reg_print_t ahc_scb_scsioffset_print; | ||
| 899 | #else | ||
| 900 | #define ahc_scb_scsioffset_print(regvalue, cur_col, wrap) \ | ||
| 901 | ahc_print_register(NULL, 0, "SCB_SCSIOFFSET", 0xbe, regvalue, cur_col, wrap) | ||
| 902 | #endif | ||
| 903 | |||
| 904 | #if AIC_DEBUG_REGISTERS | ||
| 905 | ahc_reg_print_t ahc_scb_next_print; | ||
| 906 | #else | ||
| 907 | #define ahc_scb_next_print(regvalue, cur_col, wrap) \ | ||
| 908 | ahc_print_register(NULL, 0, "SCB_NEXT", 0xbf, regvalue, cur_col, wrap) | ||
| 909 | #endif | ||
| 910 | |||
| 911 | #if AIC_DEBUG_REGISTERS | ||
| 912 | ahc_reg_print_t ahc_scb_64_spare_print; | ||
| 913 | #else | ||
| 914 | #define ahc_scb_64_spare_print(regvalue, cur_col, wrap) \ | ||
| 915 | ahc_print_register(NULL, 0, "SCB_64_SPARE", 0xc0, regvalue, cur_col, wrap) | ||
| 916 | #endif | ||
| 917 | |||
| 918 | #if AIC_DEBUG_REGISTERS | ||
| 919 | ahc_reg_print_t ahc_seectl_2840_print; | ||
| 920 | #else | ||
| 921 | #define ahc_seectl_2840_print(regvalue, cur_col, wrap) \ | ||
| 922 | ahc_print_register(NULL, 0, "SEECTL_2840", 0xc0, regvalue, cur_col, wrap) | ||
| 923 | #endif | ||
| 924 | |||
| 925 | #if AIC_DEBUG_REGISTERS | ||
| 926 | ahc_reg_print_t ahc_status_2840_print; | ||
| 927 | #else | ||
| 928 | #define ahc_status_2840_print(regvalue, cur_col, wrap) \ | ||
| 929 | ahc_print_register(NULL, 0, "STATUS_2840", 0xc1, regvalue, cur_col, wrap) | ||
| 930 | #endif | ||
| 931 | |||
| 932 | #if AIC_DEBUG_REGISTERS | ||
| 933 | ahc_reg_print_t ahc_scb_64_btt_print; | ||
| 934 | #else | ||
| 935 | #define ahc_scb_64_btt_print(regvalue, cur_col, wrap) \ | ||
| 936 | ahc_print_register(NULL, 0, "SCB_64_BTT", 0xd0, regvalue, cur_col, wrap) | ||
| 937 | #endif | ||
| 938 | |||
| 939 | #if AIC_DEBUG_REGISTERS | ||
| 940 | ahc_reg_print_t ahc_cchaddr_print; | ||
| 941 | #else | ||
| 942 | #define ahc_cchaddr_print(regvalue, cur_col, wrap) \ | ||
| 943 | ahc_print_register(NULL, 0, "CCHADDR", 0xe0, regvalue, cur_col, wrap) | ||
| 944 | #endif | ||
| 945 | |||
| 946 | #if AIC_DEBUG_REGISTERS | ||
| 947 | ahc_reg_print_t ahc_cchcnt_print; | ||
| 948 | #else | ||
| 949 | #define ahc_cchcnt_print(regvalue, cur_col, wrap) \ | ||
| 950 | ahc_print_register(NULL, 0, "CCHCNT", 0xe8, regvalue, cur_col, wrap) | ||
| 951 | #endif | ||
| 952 | |||
| 953 | #if AIC_DEBUG_REGISTERS | ||
| 954 | ahc_reg_print_t ahc_ccsgram_print; | ||
| 955 | #else | ||
| 956 | #define ahc_ccsgram_print(regvalue, cur_col, wrap) \ | ||
| 957 | ahc_print_register(NULL, 0, "CCSGRAM", 0xe9, regvalue, cur_col, wrap) | ||
| 958 | #endif | ||
| 959 | |||
| 960 | #if AIC_DEBUG_REGISTERS | ||
| 961 | ahc_reg_print_t ahc_ccsgaddr_print; | ||
| 962 | #else | ||
| 963 | #define ahc_ccsgaddr_print(regvalue, cur_col, wrap) \ | ||
| 964 | ahc_print_register(NULL, 0, "CCSGADDR", 0xea, regvalue, cur_col, wrap) | ||
| 965 | #endif | ||
| 966 | |||
| 967 | #if AIC_DEBUG_REGISTERS | ||
| 968 | ahc_reg_print_t ahc_ccsgctl_print; | ||
| 969 | #else | ||
| 970 | #define ahc_ccsgctl_print(regvalue, cur_col, wrap) \ | ||
| 971 | ahc_print_register(NULL, 0, "CCSGCTL", 0xeb, regvalue, cur_col, wrap) | ||
| 972 | #endif | ||
| 973 | |||
| 974 | #if AIC_DEBUG_REGISTERS | ||
| 975 | ahc_reg_print_t ahc_ccscbram_print; | ||
| 976 | #else | ||
| 977 | #define ahc_ccscbram_print(regvalue, cur_col, wrap) \ | ||
| 978 | ahc_print_register(NULL, 0, "CCSCBRAM", 0xec, regvalue, cur_col, wrap) | ||
| 979 | #endif | ||
| 980 | |||
| 981 | #if AIC_DEBUG_REGISTERS | ||
| 982 | ahc_reg_print_t ahc_ccscbaddr_print; | ||
| 983 | #else | ||
| 984 | #define ahc_ccscbaddr_print(regvalue, cur_col, wrap) \ | ||
| 985 | ahc_print_register(NULL, 0, "CCSCBADDR", 0xed, regvalue, cur_col, wrap) | ||
| 986 | #endif | ||
| 987 | |||
| 988 | #if AIC_DEBUG_REGISTERS | ||
| 989 | ahc_reg_print_t ahc_ccscbctl_print; | ||
| 990 | #else | ||
| 991 | #define ahc_ccscbctl_print(regvalue, cur_col, wrap) \ | ||
| 992 | ahc_print_register(NULL, 0, "CCSCBCTL", 0xee, regvalue, cur_col, wrap) | ||
| 993 | #endif | ||
| 994 | |||
| 995 | #if AIC_DEBUG_REGISTERS | ||
| 996 | ahc_reg_print_t ahc_ccscbcnt_print; | ||
| 997 | #else | ||
| 998 | #define ahc_ccscbcnt_print(regvalue, cur_col, wrap) \ | ||
| 999 | ahc_print_register(NULL, 0, "CCSCBCNT", 0xef, regvalue, cur_col, wrap) | ||
| 1000 | #endif | ||
| 1001 | |||
| 1002 | #if AIC_DEBUG_REGISTERS | ||
| 1003 | ahc_reg_print_t ahc_scbbaddr_print; | ||
| 1004 | #else | ||
| 1005 | #define ahc_scbbaddr_print(regvalue, cur_col, wrap) \ | ||
| 1006 | ahc_print_register(NULL, 0, "SCBBADDR", 0xf0, regvalue, cur_col, wrap) | ||
| 1007 | #endif | ||
| 1008 | |||
| 1009 | #if AIC_DEBUG_REGISTERS | ||
| 1010 | ahc_reg_print_t ahc_ccscbptr_print; | ||
| 1011 | #else | ||
| 1012 | #define ahc_ccscbptr_print(regvalue, cur_col, wrap) \ | ||
| 1013 | ahc_print_register(NULL, 0, "CCSCBPTR", 0xf1, regvalue, cur_col, wrap) | ||
| 1014 | #endif | ||
| 1015 | |||
| 1016 | #if AIC_DEBUG_REGISTERS | ||
| 1017 | ahc_reg_print_t ahc_hnscb_qoff_print; | ||
| 1018 | #else | ||
| 1019 | #define ahc_hnscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 1020 | ahc_print_register(NULL, 0, "HNSCB_QOFF", 0xf4, regvalue, cur_col, wrap) | ||
| 1021 | #endif | ||
| 1022 | |||
| 1023 | #if AIC_DEBUG_REGISTERS | ||
| 1024 | ahc_reg_print_t ahc_snscb_qoff_print; | ||
| 1025 | #else | ||
| 1026 | #define ahc_snscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 1027 | ahc_print_register(NULL, 0, "SNSCB_QOFF", 0xf6, regvalue, cur_col, wrap) | ||
| 1028 | #endif | ||
| 1029 | |||
| 1030 | #if AIC_DEBUG_REGISTERS | ||
| 1031 | ahc_reg_print_t ahc_sdscb_qoff_print; | ||
| 1032 | #else | ||
| 1033 | #define ahc_sdscb_qoff_print(regvalue, cur_col, wrap) \ | ||
| 1034 | ahc_print_register(NULL, 0, "SDSCB_QOFF", 0xf8, regvalue, cur_col, wrap) | ||
| 1035 | #endif | ||
| 1036 | |||
| 1037 | #if AIC_DEBUG_REGISTERS | ||
| 1038 | ahc_reg_print_t ahc_qoff_ctlsta_print; | ||
| 1039 | #else | ||
| 1040 | #define ahc_qoff_ctlsta_print(regvalue, cur_col, wrap) \ | ||
| 1041 | ahc_print_register(NULL, 0, "QOFF_CTLSTA", 0xfa, regvalue, cur_col, wrap) | ||
| 1042 | #endif | ||
| 1043 | |||
| 1044 | #if AIC_DEBUG_REGISTERS | ||
| 1045 | ahc_reg_print_t ahc_dff_thrsh_print; | ||
| 1046 | #else | ||
| 1047 | #define ahc_dff_thrsh_print(regvalue, cur_col, wrap) \ | ||
| 1048 | ahc_print_register(NULL, 0, "DFF_THRSH", 0xfb, regvalue, cur_col, wrap) | ||
| 1049 | #endif | ||
| 1050 | |||
| 1051 | #if AIC_DEBUG_REGISTERS | ||
| 1052 | ahc_reg_print_t ahc_sg_cache_shadow_print; | ||
| 1053 | #else | ||
| 1054 | #define ahc_sg_cache_shadow_print(regvalue, cur_col, wrap) \ | ||
| 1055 | ahc_print_register(NULL, 0, "SG_CACHE_SHADOW", 0xfc, regvalue, cur_col, wrap) | ||
| 1056 | #endif | ||
| 1057 | |||
| 1058 | #if AIC_DEBUG_REGISTERS | ||
| 1059 | ahc_reg_print_t ahc_sg_cache_pre_print; | ||
| 1060 | #else | ||
| 1061 | #define ahc_sg_cache_pre_print(regvalue, cur_col, wrap) \ | ||
| 1062 | ahc_print_register(NULL, 0, "SG_CACHE_PRE", 0xfc, regvalue, cur_col, wrap) | ||
| 1063 | #endif | ||
| 1064 | |||
| 1065 | 190 | ||
| 1066 | #define SCSISEQ 0x00 | 191 | #define SCSISEQ 0x00 |
| 1067 | #define TEMODE 0x80 | 192 | #define TEMODE 0x80 |
diff --git a/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped b/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped index 309a562b009e..9f9b88047d0c 100644 --- a/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped +++ b/drivers/scsi/aic7xxx/aic7xxx_reg_print.c_shipped | |||
| @@ -43,48 +43,6 @@ ahc_sxfrctl0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 43 | 0x01, regvalue, cur_col, wrap)); | 43 | 0x01, regvalue, cur_col, wrap)); |
| 44 | } | 44 | } |
| 45 | 45 | ||
| 46 | static const ahc_reg_parse_entry_t SXFRCTL1_parse_table[] = { | ||
| 47 | { "STPWEN", 0x01, 0x01 }, | ||
| 48 | { "ACTNEGEN", 0x02, 0x02 }, | ||
| 49 | { "ENSTIMER", 0x04, 0x04 }, | ||
| 50 | { "ENSPCHK", 0x20, 0x20 }, | ||
| 51 | { "SWRAPEN", 0x40, 0x40 }, | ||
| 52 | { "BITBUCKET", 0x80, 0x80 }, | ||
| 53 | { "STIMESEL", 0x18, 0x18 } | ||
| 54 | }; | ||
| 55 | |||
| 56 | int | ||
| 57 | ahc_sxfrctl1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 58 | { | ||
| 59 | return (ahc_print_register(SXFRCTL1_parse_table, 7, "SXFRCTL1", | ||
| 60 | 0x02, regvalue, cur_col, wrap)); | ||
| 61 | } | ||
| 62 | |||
| 63 | static const ahc_reg_parse_entry_t SCSISIGO_parse_table[] = { | ||
| 64 | { "ACKO", 0x01, 0x01 }, | ||
| 65 | { "REQO", 0x02, 0x02 }, | ||
| 66 | { "BSYO", 0x04, 0x04 }, | ||
| 67 | { "SELO", 0x08, 0x08 }, | ||
| 68 | { "ATNO", 0x10, 0x10 }, | ||
| 69 | { "MSGO", 0x20, 0x20 }, | ||
| 70 | { "IOO", 0x40, 0x40 }, | ||
| 71 | { "CDO", 0x80, 0x80 }, | ||
| 72 | { "P_DATAOUT", 0x00, 0x00 }, | ||
| 73 | { "P_DATAIN", 0x40, 0x40 }, | ||
| 74 | { "P_COMMAND", 0x80, 0x80 }, | ||
| 75 | { "P_MESGOUT", 0xa0, 0xa0 }, | ||
| 76 | { "P_STATUS", 0xc0, 0xc0 }, | ||
| 77 | { "PHASE_MASK", 0xe0, 0xe0 }, | ||
| 78 | { "P_MESGIN", 0xe0, 0xe0 } | ||
| 79 | }; | ||
| 80 | |||
| 81 | int | ||
| 82 | ahc_scsisigo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 83 | { | ||
| 84 | return (ahc_print_register(SCSISIGO_parse_table, 15, "SCSISIGO", | ||
| 85 | 0x03, regvalue, cur_col, wrap)); | ||
| 86 | } | ||
| 87 | |||
| 88 | static const ahc_reg_parse_entry_t SCSISIGI_parse_table[] = { | 46 | static const ahc_reg_parse_entry_t SCSISIGI_parse_table[] = { |
| 89 | { "ACKI", 0x01, 0x01 }, | 47 | { "ACKI", 0x01, 0x01 }, |
| 90 | { "REQI", 0x02, 0x02 }, | 48 | { "REQI", 0x02, 0x02 }, |
| @@ -128,77 +86,6 @@ ahc_scsirate_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 128 | 0x04, regvalue, cur_col, wrap)); | 86 | 0x04, regvalue, cur_col, wrap)); |
| 129 | } | 87 | } |
| 130 | 88 | ||
| 131 | static const ahc_reg_parse_entry_t SCSIID_parse_table[] = { | ||
| 132 | { "TWIN_CHNLB", 0x80, 0x80 }, | ||
| 133 | { "OID", 0x0f, 0x0f }, | ||
| 134 | { "TWIN_TID", 0x70, 0x70 }, | ||
| 135 | { "SOFS_ULTRA2", 0x7f, 0x7f }, | ||
| 136 | { "TID", 0xf0, 0xf0 } | ||
| 137 | }; | ||
| 138 | |||
| 139 | int | ||
| 140 | ahc_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 141 | { | ||
| 142 | return (ahc_print_register(SCSIID_parse_table, 5, "SCSIID", | ||
| 143 | 0x05, regvalue, cur_col, wrap)); | ||
| 144 | } | ||
| 145 | |||
| 146 | int | ||
| 147 | ahc_scsidatl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 148 | { | ||
| 149 | return (ahc_print_register(NULL, 0, "SCSIDATL", | ||
| 150 | 0x06, regvalue, cur_col, wrap)); | ||
| 151 | } | ||
| 152 | |||
| 153 | int | ||
| 154 | ahc_stcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 155 | { | ||
| 156 | return (ahc_print_register(NULL, 0, "STCNT", | ||
| 157 | 0x08, regvalue, cur_col, wrap)); | ||
| 158 | } | ||
| 159 | |||
| 160 | static const ahc_reg_parse_entry_t OPTIONMODE_parse_table[] = { | ||
| 161 | { "DIS_MSGIN_DUALEDGE", 0x01, 0x01 }, | ||
| 162 | { "AUTO_MSGOUT_DE", 0x02, 0x02 }, | ||
| 163 | { "SCSIDATL_IMGEN", 0x04, 0x04 }, | ||
| 164 | { "EXPPHASEDIS", 0x08, 0x08 }, | ||
| 165 | { "BUSFREEREV", 0x10, 0x10 }, | ||
| 166 | { "ATNMGMNTEN", 0x20, 0x20 }, | ||
| 167 | { "AUTOACKEN", 0x40, 0x40 }, | ||
| 168 | { "AUTORATEEN", 0x80, 0x80 }, | ||
| 169 | { "OPTIONMODE_DEFAULTS",0x03, 0x03 } | ||
| 170 | }; | ||
| 171 | |||
| 172 | int | ||
| 173 | ahc_optionmode_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 174 | { | ||
| 175 | return (ahc_print_register(OPTIONMODE_parse_table, 9, "OPTIONMODE", | ||
| 176 | 0x08, regvalue, cur_col, wrap)); | ||
| 177 | } | ||
| 178 | |||
| 179 | int | ||
| 180 | ahc_targcrccnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 181 | { | ||
| 182 | return (ahc_print_register(NULL, 0, "TARGCRCCNT", | ||
| 183 | 0x0a, regvalue, cur_col, wrap)); | ||
| 184 | } | ||
| 185 | |||
| 186 | static const ahc_reg_parse_entry_t CLRSINT0_parse_table[] = { | ||
| 187 | { "CLRSPIORDY", 0x02, 0x02 }, | ||
| 188 | { "CLRSWRAP", 0x08, 0x08 }, | ||
| 189 | { "CLRIOERR", 0x08, 0x08 }, | ||
| 190 | { "CLRSELINGO", 0x10, 0x10 }, | ||
| 191 | { "CLRSELDI", 0x20, 0x20 }, | ||
| 192 | { "CLRSELDO", 0x40, 0x40 } | ||
| 193 | }; | ||
| 194 | |||
| 195 | int | ||
| 196 | ahc_clrsint0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 197 | { | ||
| 198 | return (ahc_print_register(CLRSINT0_parse_table, 6, "CLRSINT0", | ||
| 199 | 0x0b, regvalue, cur_col, wrap)); | ||
| 200 | } | ||
| 201 | |||
| 202 | static const ahc_reg_parse_entry_t SSTAT0_parse_table[] = { | 89 | static const ahc_reg_parse_entry_t SSTAT0_parse_table[] = { |
| 203 | { "DMADONE", 0x01, 0x01 }, | 90 | { "DMADONE", 0x01, 0x01 }, |
| 204 | { "SPIORDY", 0x02, 0x02 }, | 91 | { "SPIORDY", 0x02, 0x02 }, |
| @@ -218,23 +105,6 @@ ahc_sstat0_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 218 | 0x0b, regvalue, cur_col, wrap)); | 105 | 0x0b, regvalue, cur_col, wrap)); |
| 219 | } | 106 | } |
| 220 | 107 | ||
| 221 | static const ahc_reg_parse_entry_t CLRSINT1_parse_table[] = { | ||
| 222 | { "CLRREQINIT", 0x01, 0x01 }, | ||
| 223 | { "CLRPHASECHG", 0x02, 0x02 }, | ||
| 224 | { "CLRSCSIPERR", 0x04, 0x04 }, | ||
| 225 | { "CLRBUSFREE", 0x08, 0x08 }, | ||
| 226 | { "CLRSCSIRSTI", 0x20, 0x20 }, | ||
| 227 | { "CLRATNO", 0x40, 0x40 }, | ||
| 228 | { "CLRSELTIMEO", 0x80, 0x80 } | ||
| 229 | }; | ||
| 230 | |||
| 231 | int | ||
| 232 | ahc_clrsint1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 233 | { | ||
| 234 | return (ahc_print_register(CLRSINT1_parse_table, 7, "CLRSINT1", | ||
| 235 | 0x0c, regvalue, cur_col, wrap)); | ||
| 236 | } | ||
| 237 | |||
| 238 | static const ahc_reg_parse_entry_t SSTAT1_parse_table[] = { | 108 | static const ahc_reg_parse_entry_t SSTAT1_parse_table[] = { |
| 239 | { "REQINIT", 0x01, 0x01 }, | 109 | { "REQINIT", 0x01, 0x01 }, |
| 240 | { "PHASECHG", 0x02, 0x02 }, | 110 | { "PHASECHG", 0x02, 0x02 }, |
| @@ -284,18 +154,6 @@ ahc_sstat3_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 284 | 0x0e, regvalue, cur_col, wrap)); | 154 | 0x0e, regvalue, cur_col, wrap)); |
| 285 | } | 155 | } |
| 286 | 156 | ||
| 287 | static const ahc_reg_parse_entry_t SCSIID_ULTRA2_parse_table[] = { | ||
| 288 | { "OID", 0x0f, 0x0f }, | ||
| 289 | { "TID", 0xf0, 0xf0 } | ||
| 290 | }; | ||
| 291 | |||
| 292 | int | ||
| 293 | ahc_scsiid_ultra2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 294 | { | ||
| 295 | return (ahc_print_register(SCSIID_ULTRA2_parse_table, 2, "SCSIID_ULTRA2", | ||
| 296 | 0x0f, regvalue, cur_col, wrap)); | ||
| 297 | } | ||
| 298 | |||
| 299 | static const ahc_reg_parse_entry_t SIMODE0_parse_table[] = { | 157 | static const ahc_reg_parse_entry_t SIMODE0_parse_table[] = { |
| 300 | { "ENDMADONE", 0x01, 0x01 }, | 158 | { "ENDMADONE", 0x01, 0x01 }, |
| 301 | { "ENSPIORDY", 0x02, 0x02 }, | 159 | { "ENSPIORDY", 0x02, 0x02 }, |
| @@ -339,107 +197,6 @@ ahc_scsibusl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 339 | 0x12, regvalue, cur_col, wrap)); | 197 | 0x12, regvalue, cur_col, wrap)); |
| 340 | } | 198 | } |
| 341 | 199 | ||
| 342 | int | ||
| 343 | ahc_shaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 344 | { | ||
| 345 | return (ahc_print_register(NULL, 0, "SHADDR", | ||
| 346 | 0x14, regvalue, cur_col, wrap)); | ||
| 347 | } | ||
| 348 | |||
| 349 | static const ahc_reg_parse_entry_t SELTIMER_parse_table[] = { | ||
| 350 | { "STAGE1", 0x01, 0x01 }, | ||
| 351 | { "STAGE2", 0x02, 0x02 }, | ||
| 352 | { "STAGE3", 0x04, 0x04 }, | ||
| 353 | { "STAGE4", 0x08, 0x08 }, | ||
| 354 | { "STAGE5", 0x10, 0x10 }, | ||
| 355 | { "STAGE6", 0x20, 0x20 } | ||
| 356 | }; | ||
| 357 | |||
| 358 | int | ||
| 359 | ahc_seltimer_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 360 | { | ||
| 361 | return (ahc_print_register(SELTIMER_parse_table, 6, "SELTIMER", | ||
| 362 | 0x18, regvalue, cur_col, wrap)); | ||
| 363 | } | ||
| 364 | |||
| 365 | static const ahc_reg_parse_entry_t SELID_parse_table[] = { | ||
| 366 | { "ONEBIT", 0x08, 0x08 }, | ||
| 367 | { "SELID_MASK", 0xf0, 0xf0 } | ||
| 368 | }; | ||
| 369 | |||
| 370 | int | ||
| 371 | ahc_selid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 372 | { | ||
| 373 | return (ahc_print_register(SELID_parse_table, 2, "SELID", | ||
| 374 | 0x19, regvalue, cur_col, wrap)); | ||
| 375 | } | ||
| 376 | |||
| 377 | int | ||
| 378 | ahc_targid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 379 | { | ||
| 380 | return (ahc_print_register(NULL, 0, "TARGID", | ||
| 381 | 0x1b, regvalue, cur_col, wrap)); | ||
| 382 | } | ||
| 383 | |||
| 384 | static const ahc_reg_parse_entry_t SPIOCAP_parse_table[] = { | ||
| 385 | { "SSPIOCPS", 0x01, 0x01 }, | ||
| 386 | { "ROM", 0x02, 0x02 }, | ||
| 387 | { "EEPROM", 0x04, 0x04 }, | ||
| 388 | { "SEEPROM", 0x08, 0x08 }, | ||
| 389 | { "EXT_BRDCTL", 0x10, 0x10 }, | ||
| 390 | { "SOFTCMDEN", 0x20, 0x20 }, | ||
| 391 | { "SOFT0", 0x40, 0x40 }, | ||
| 392 | { "SOFT1", 0x80, 0x80 } | ||
| 393 | }; | ||
| 394 | |||
| 395 | int | ||
| 396 | ahc_spiocap_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 397 | { | ||
| 398 | return (ahc_print_register(SPIOCAP_parse_table, 8, "SPIOCAP", | ||
| 399 | 0x1b, regvalue, cur_col, wrap)); | ||
| 400 | } | ||
| 401 | |||
| 402 | static const ahc_reg_parse_entry_t BRDCTL_parse_table[] = { | ||
| 403 | { "BRDCTL0", 0x01, 0x01 }, | ||
| 404 | { "BRDSTB_ULTRA2", 0x01, 0x01 }, | ||
| 405 | { "BRDCTL1", 0x02, 0x02 }, | ||
| 406 | { "BRDRW_ULTRA2", 0x02, 0x02 }, | ||
| 407 | { "BRDRW", 0x04, 0x04 }, | ||
| 408 | { "BRDDAT2", 0x04, 0x04 }, | ||
| 409 | { "BRDCS", 0x08, 0x08 }, | ||
| 410 | { "BRDDAT3", 0x08, 0x08 }, | ||
| 411 | { "BRDSTB", 0x10, 0x10 }, | ||
| 412 | { "BRDDAT4", 0x10, 0x10 }, | ||
| 413 | { "BRDDAT5", 0x20, 0x20 }, | ||
| 414 | { "BRDDAT6", 0x40, 0x40 }, | ||
| 415 | { "BRDDAT7", 0x80, 0x80 } | ||
| 416 | }; | ||
| 417 | |||
| 418 | int | ||
| 419 | ahc_brdctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 420 | { | ||
| 421 | return (ahc_print_register(BRDCTL_parse_table, 13, "BRDCTL", | ||
| 422 | 0x1d, regvalue, cur_col, wrap)); | ||
| 423 | } | ||
| 424 | |||
| 425 | static const ahc_reg_parse_entry_t SEECTL_parse_table[] = { | ||
| 426 | { "SEEDI", 0x01, 0x01 }, | ||
| 427 | { "SEEDO", 0x02, 0x02 }, | ||
| 428 | { "SEECK", 0x04, 0x04 }, | ||
| 429 | { "SEECS", 0x08, 0x08 }, | ||
| 430 | { "SEERDY", 0x10, 0x10 }, | ||
| 431 | { "SEEMS", 0x20, 0x20 }, | ||
| 432 | { "EXTARBREQ", 0x40, 0x40 }, | ||
| 433 | { "EXTARBACK", 0x80, 0x80 } | ||
| 434 | }; | ||
| 435 | |||
| 436 | int | ||
| 437 | ahc_seectl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 438 | { | ||
| 439 | return (ahc_print_register(SEECTL_parse_table, 8, "SEECTL", | ||
| 440 | 0x1e, regvalue, cur_col, wrap)); | ||
| 441 | } | ||
| 442 | |||
| 443 | static const ahc_reg_parse_entry_t SBLKCTL_parse_table[] = { | 200 | static const ahc_reg_parse_entry_t SBLKCTL_parse_table[] = { |
| 444 | { "XCVR", 0x01, 0x01 }, | 201 | { "XCVR", 0x01, 0x01 }, |
| 445 | { "SELWIDE", 0x02, 0x02 }, | 202 | { "SELWIDE", 0x02, 0x02 }, |
| @@ -458,68 +215,6 @@ ahc_sblkctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 458 | 0x1f, regvalue, cur_col, wrap)); | 215 | 0x1f, regvalue, cur_col, wrap)); |
| 459 | } | 216 | } |
| 460 | 217 | ||
| 461 | int | ||
| 462 | ahc_busy_targets_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 463 | { | ||
| 464 | return (ahc_print_register(NULL, 0, "BUSY_TARGETS", | ||
| 465 | 0x20, regvalue, cur_col, wrap)); | ||
| 466 | } | ||
| 467 | |||
| 468 | int | ||
| 469 | ahc_ultra_enb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 470 | { | ||
| 471 | return (ahc_print_register(NULL, 0, "ULTRA_ENB", | ||
| 472 | 0x30, regvalue, cur_col, wrap)); | ||
| 473 | } | ||
| 474 | |||
| 475 | int | ||
| 476 | ahc_disc_dsb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 477 | { | ||
| 478 | return (ahc_print_register(NULL, 0, "DISC_DSB", | ||
| 479 | 0x32, regvalue, cur_col, wrap)); | ||
| 480 | } | ||
| 481 | |||
| 482 | int | ||
| 483 | ahc_mwi_residual_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 484 | { | ||
| 485 | return (ahc_print_register(NULL, 0, "MWI_RESIDUAL", | ||
| 486 | 0x38, regvalue, cur_col, wrap)); | ||
| 487 | } | ||
| 488 | |||
| 489 | int | ||
| 490 | ahc_next_queued_scb_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 491 | { | ||
| 492 | return (ahc_print_register(NULL, 0, "NEXT_QUEUED_SCB", | ||
| 493 | 0x39, regvalue, cur_col, wrap)); | ||
| 494 | } | ||
| 495 | |||
| 496 | int | ||
| 497 | ahc_msg_out_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 498 | { | ||
| 499 | return (ahc_print_register(NULL, 0, "MSG_OUT", | ||
| 500 | 0x3a, regvalue, cur_col, wrap)); | ||
| 501 | } | ||
| 502 | |||
| 503 | static const ahc_reg_parse_entry_t DMAPARAMS_parse_table[] = { | ||
| 504 | { "FIFORESET", 0x01, 0x01 }, | ||
| 505 | { "FIFOFLUSH", 0x02, 0x02 }, | ||
| 506 | { "DIRECTION", 0x04, 0x04 }, | ||
| 507 | { "HDMAEN", 0x08, 0x08 }, | ||
| 508 | { "HDMAENACK", 0x08, 0x08 }, | ||
| 509 | { "SDMAEN", 0x10, 0x10 }, | ||
| 510 | { "SDMAENACK", 0x10, 0x10 }, | ||
| 511 | { "SCSIEN", 0x20, 0x20 }, | ||
| 512 | { "WIDEODD", 0x40, 0x40 }, | ||
| 513 | { "PRELOADEN", 0x80, 0x80 } | ||
| 514 | }; | ||
| 515 | |||
| 516 | int | ||
| 517 | ahc_dmaparams_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 518 | { | ||
| 519 | return (ahc_print_register(DMAPARAMS_parse_table, 10, "DMAPARAMS", | ||
| 520 | 0x3b, regvalue, cur_col, wrap)); | ||
| 521 | } | ||
| 522 | |||
| 523 | static const ahc_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { | 218 | static const ahc_reg_parse_entry_t SEQ_FLAGS_parse_table[] = { |
| 524 | { "NO_DISCONNECT", 0x01, 0x01 }, | 219 | { "NO_DISCONNECT", 0x01, 0x01 }, |
| 525 | { "SPHASE_PENDING", 0x02, 0x02 }, | 220 | { "SPHASE_PENDING", 0x02, 0x02 }, |
| @@ -539,20 +234,6 @@ ahc_seq_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 539 | 0x3c, regvalue, cur_col, wrap)); | 234 | 0x3c, regvalue, cur_col, wrap)); |
| 540 | } | 235 | } |
| 541 | 236 | ||
| 542 | int | ||
| 543 | ahc_saved_scsiid_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 544 | { | ||
| 545 | return (ahc_print_register(NULL, 0, "SAVED_SCSIID", | ||
| 546 | 0x3d, regvalue, cur_col, wrap)); | ||
| 547 | } | ||
| 548 | |||
| 549 | int | ||
| 550 | ahc_saved_lun_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 551 | { | ||
| 552 | return (ahc_print_register(NULL, 0, "SAVED_LUN", | ||
| 553 | 0x3e, regvalue, cur_col, wrap)); | ||
| 554 | } | ||
| 555 | |||
| 556 | static const ahc_reg_parse_entry_t LASTPHASE_parse_table[] = { | 237 | static const ahc_reg_parse_entry_t LASTPHASE_parse_table[] = { |
| 557 | { "MSGI", 0x20, 0x20 }, | 238 | { "MSGI", 0x20, 0x20 }, |
| 558 | { "IOI", 0x40, 0x40 }, | 239 | { "IOI", 0x40, 0x40 }, |
| @@ -574,193 +255,6 @@ ahc_lastphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 574 | 0x3f, regvalue, cur_col, wrap)); | 255 | 0x3f, regvalue, cur_col, wrap)); |
| 575 | } | 256 | } |
| 576 | 257 | ||
| 577 | int | ||
| 578 | ahc_waiting_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 579 | { | ||
| 580 | return (ahc_print_register(NULL, 0, "WAITING_SCBH", | ||
| 581 | 0x40, regvalue, cur_col, wrap)); | ||
| 582 | } | ||
| 583 | |||
| 584 | int | ||
| 585 | ahc_disconnected_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 586 | { | ||
| 587 | return (ahc_print_register(NULL, 0, "DISCONNECTED_SCBH", | ||
| 588 | 0x41, regvalue, cur_col, wrap)); | ||
| 589 | } | ||
| 590 | |||
| 591 | int | ||
| 592 | ahc_free_scbh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 593 | { | ||
| 594 | return (ahc_print_register(NULL, 0, "FREE_SCBH", | ||
| 595 | 0x42, regvalue, cur_col, wrap)); | ||
| 596 | } | ||
| 597 | |||
| 598 | int | ||
| 599 | ahc_hscb_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 600 | { | ||
| 601 | return (ahc_print_register(NULL, 0, "HSCB_ADDR", | ||
| 602 | 0x44, regvalue, cur_col, wrap)); | ||
| 603 | } | ||
| 604 | |||
| 605 | int | ||
| 606 | ahc_shared_data_addr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 607 | { | ||
| 608 | return (ahc_print_register(NULL, 0, "SHARED_DATA_ADDR", | ||
| 609 | 0x48, regvalue, cur_col, wrap)); | ||
| 610 | } | ||
| 611 | |||
| 612 | int | ||
| 613 | ahc_kernel_qinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 614 | { | ||
| 615 | return (ahc_print_register(NULL, 0, "KERNEL_QINPOS", | ||
| 616 | 0x4c, regvalue, cur_col, wrap)); | ||
| 617 | } | ||
| 618 | |||
| 619 | int | ||
| 620 | ahc_qinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 621 | { | ||
| 622 | return (ahc_print_register(NULL, 0, "QINPOS", | ||
| 623 | 0x4d, regvalue, cur_col, wrap)); | ||
| 624 | } | ||
| 625 | |||
| 626 | int | ||
| 627 | ahc_qoutpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 628 | { | ||
| 629 | return (ahc_print_register(NULL, 0, "QOUTPOS", | ||
| 630 | 0x4e, regvalue, cur_col, wrap)); | ||
| 631 | } | ||
| 632 | |||
| 633 | int | ||
| 634 | ahc_kernel_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 635 | { | ||
| 636 | return (ahc_print_register(NULL, 0, "KERNEL_TQINPOS", | ||
| 637 | 0x4f, regvalue, cur_col, wrap)); | ||
| 638 | } | ||
| 639 | |||
| 640 | int | ||
| 641 | ahc_tqinpos_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 642 | { | ||
| 643 | return (ahc_print_register(NULL, 0, "TQINPOS", | ||
| 644 | 0x50, regvalue, cur_col, wrap)); | ||
| 645 | } | ||
| 646 | |||
| 647 | static const ahc_reg_parse_entry_t ARG_1_parse_table[] = { | ||
| 648 | { "CONT_TARG_SESSION", 0x02, 0x02 }, | ||
| 649 | { "CONT_MSG_LOOP", 0x04, 0x04 }, | ||
| 650 | { "EXIT_MSG_LOOP", 0x08, 0x08 }, | ||
| 651 | { "MSGOUT_PHASEMIS", 0x10, 0x10 }, | ||
| 652 | { "SEND_REJ", 0x20, 0x20 }, | ||
| 653 | { "SEND_SENSE", 0x40, 0x40 }, | ||
| 654 | { "SEND_MSG", 0x80, 0x80 } | ||
| 655 | }; | ||
| 656 | |||
| 657 | int | ||
| 658 | ahc_arg_1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 659 | { | ||
| 660 | return (ahc_print_register(ARG_1_parse_table, 7, "ARG_1", | ||
| 661 | 0x51, regvalue, cur_col, wrap)); | ||
| 662 | } | ||
| 663 | |||
| 664 | int | ||
| 665 | ahc_arg_2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 666 | { | ||
| 667 | return (ahc_print_register(NULL, 0, "ARG_2", | ||
| 668 | 0x52, regvalue, cur_col, wrap)); | ||
| 669 | } | ||
| 670 | |||
| 671 | int | ||
| 672 | ahc_last_msg_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 673 | { | ||
| 674 | return (ahc_print_register(NULL, 0, "LAST_MSG", | ||
| 675 | 0x53, regvalue, cur_col, wrap)); | ||
| 676 | } | ||
| 677 | |||
| 678 | static const ahc_reg_parse_entry_t SCSISEQ_TEMPLATE_parse_table[] = { | ||
| 679 | { "ENAUTOATNP", 0x02, 0x02 }, | ||
| 680 | { "ENAUTOATNI", 0x04, 0x04 }, | ||
| 681 | { "ENAUTOATNO", 0x08, 0x08 }, | ||
| 682 | { "ENRSELI", 0x10, 0x10 }, | ||
| 683 | { "ENSELI", 0x20, 0x20 }, | ||
| 684 | { "ENSELO", 0x40, 0x40 } | ||
| 685 | }; | ||
| 686 | |||
| 687 | int | ||
| 688 | ahc_scsiseq_template_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 689 | { | ||
| 690 | return (ahc_print_register(SCSISEQ_TEMPLATE_parse_table, 6, "SCSISEQ_TEMPLATE", | ||
| 691 | 0x54, regvalue, cur_col, wrap)); | ||
| 692 | } | ||
| 693 | |||
| 694 | static const ahc_reg_parse_entry_t HA_274_BIOSGLOBAL_parse_table[] = { | ||
| 695 | { "HA_274_EXTENDED_TRANS",0x01, 0x01 } | ||
| 696 | }; | ||
| 697 | |||
| 698 | int | ||
| 699 | ahc_ha_274_biosglobal_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 700 | { | ||
| 701 | return (ahc_print_register(HA_274_BIOSGLOBAL_parse_table, 1, "HA_274_BIOSGLOBAL", | ||
| 702 | 0x56, regvalue, cur_col, wrap)); | ||
| 703 | } | ||
| 704 | |||
| 705 | static const ahc_reg_parse_entry_t SEQ_FLAGS2_parse_table[] = { | ||
| 706 | { "SCB_DMA", 0x01, 0x01 }, | ||
| 707 | { "TARGET_MSG_PENDING", 0x02, 0x02 } | ||
| 708 | }; | ||
| 709 | |||
| 710 | int | ||
| 711 | ahc_seq_flags2_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 712 | { | ||
| 713 | return (ahc_print_register(SEQ_FLAGS2_parse_table, 2, "SEQ_FLAGS2", | ||
| 714 | 0x57, regvalue, cur_col, wrap)); | ||
| 715 | } | ||
| 716 | |||
| 717 | static const ahc_reg_parse_entry_t SCSICONF_parse_table[] = { | ||
| 718 | { "ENSPCHK", 0x20, 0x20 }, | ||
| 719 | { "RESET_SCSI", 0x40, 0x40 }, | ||
| 720 | { "TERM_ENB", 0x80, 0x80 }, | ||
| 721 | { "HSCSIID", 0x07, 0x07 }, | ||
| 722 | { "HWSCSIID", 0x0f, 0x0f } | ||
| 723 | }; | ||
| 724 | |||
| 725 | int | ||
| 726 | ahc_scsiconf_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 727 | { | ||
| 728 | return (ahc_print_register(SCSICONF_parse_table, 5, "SCSICONF", | ||
| 729 | 0x5a, regvalue, cur_col, wrap)); | ||
| 730 | } | ||
| 731 | |||
| 732 | static const ahc_reg_parse_entry_t INTDEF_parse_table[] = { | ||
| 733 | { "EDGE_TRIG", 0x80, 0x80 }, | ||
| 734 | { "VECTOR", 0x0f, 0x0f } | ||
| 735 | }; | ||
| 736 | |||
| 737 | int | ||
| 738 | ahc_intdef_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 739 | { | ||
| 740 | return (ahc_print_register(INTDEF_parse_table, 2, "INTDEF", | ||
| 741 | 0x5c, regvalue, cur_col, wrap)); | ||
| 742 | } | ||
| 743 | |||
| 744 | int | ||
| 745 | ahc_hostconf_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 746 | { | ||
| 747 | return (ahc_print_register(NULL, 0, "HOSTCONF", | ||
| 748 | 0x5d, regvalue, cur_col, wrap)); | ||
| 749 | } | ||
| 750 | |||
| 751 | static const ahc_reg_parse_entry_t HA_274_BIOSCTRL_parse_table[] = { | ||
| 752 | { "CHANNEL_B_PRIMARY", 0x08, 0x08 }, | ||
| 753 | { "BIOSMODE", 0x30, 0x30 }, | ||
| 754 | { "BIOSDISABLED", 0x30, 0x30 } | ||
| 755 | }; | ||
| 756 | |||
| 757 | int | ||
| 758 | ahc_ha_274_biosctrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 759 | { | ||
| 760 | return (ahc_print_register(HA_274_BIOSCTRL_parse_table, 3, "HA_274_BIOSCTRL", | ||
| 761 | 0x5f, regvalue, cur_col, wrap)); | ||
| 762 | } | ||
| 763 | |||
| 764 | static const ahc_reg_parse_entry_t SEQCTL_parse_table[] = { | 258 | static const ahc_reg_parse_entry_t SEQCTL_parse_table[] = { |
| 765 | { "LOADRAM", 0x01, 0x01 }, | 259 | { "LOADRAM", 0x01, 0x01 }, |
| 766 | { "SEQRESET", 0x02, 0x02 }, | 260 | { "SEQRESET", 0x02, 0x02 }, |
| @@ -780,285 +274,12 @@ ahc_seqctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 780 | } | 274 | } |
| 781 | 275 | ||
| 782 | int | 276 | int |
| 783 | ahc_seqram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 784 | { | ||
| 785 | return (ahc_print_register(NULL, 0, "SEQRAM", | ||
| 786 | 0x61, regvalue, cur_col, wrap)); | ||
| 787 | } | ||
| 788 | |||
| 789 | int | ||
| 790 | ahc_seqaddr0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 791 | { | ||
| 792 | return (ahc_print_register(NULL, 0, "SEQADDR0", | ||
| 793 | 0x62, regvalue, cur_col, wrap)); | ||
| 794 | } | ||
| 795 | |||
| 796 | static const ahc_reg_parse_entry_t SEQADDR1_parse_table[] = { | ||
| 797 | { "SEQADDR1_MASK", 0x01, 0x01 } | ||
| 798 | }; | ||
| 799 | |||
| 800 | int | ||
| 801 | ahc_seqaddr1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 802 | { | ||
| 803 | return (ahc_print_register(SEQADDR1_parse_table, 1, "SEQADDR1", | ||
| 804 | 0x63, regvalue, cur_col, wrap)); | ||
| 805 | } | ||
| 806 | |||
| 807 | int | ||
| 808 | ahc_accum_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 809 | { | ||
| 810 | return (ahc_print_register(NULL, 0, "ACCUM", | ||
| 811 | 0x64, regvalue, cur_col, wrap)); | ||
| 812 | } | ||
| 813 | |||
| 814 | int | ||
| 815 | ahc_sindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 816 | { | ||
| 817 | return (ahc_print_register(NULL, 0, "SINDEX", | ||
| 818 | 0x65, regvalue, cur_col, wrap)); | ||
| 819 | } | ||
| 820 | |||
| 821 | int | ||
| 822 | ahc_dindex_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 823 | { | ||
| 824 | return (ahc_print_register(NULL, 0, "DINDEX", | ||
| 825 | 0x66, regvalue, cur_col, wrap)); | ||
| 826 | } | ||
| 827 | |||
| 828 | int | ||
| 829 | ahc_allones_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 830 | { | ||
| 831 | return (ahc_print_register(NULL, 0, "ALLONES", | ||
| 832 | 0x69, regvalue, cur_col, wrap)); | ||
| 833 | } | ||
| 834 | |||
| 835 | int | ||
| 836 | ahc_allzeros_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 837 | { | ||
| 838 | return (ahc_print_register(NULL, 0, "ALLZEROS", | ||
| 839 | 0x6a, regvalue, cur_col, wrap)); | ||
| 840 | } | ||
| 841 | |||
| 842 | int | ||
| 843 | ahc_none_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 844 | { | ||
| 845 | return (ahc_print_register(NULL, 0, "NONE", | ||
| 846 | 0x6a, regvalue, cur_col, wrap)); | ||
| 847 | } | ||
| 848 | |||
| 849 | static const ahc_reg_parse_entry_t FLAGS_parse_table[] = { | ||
| 850 | { "CARRY", 0x01, 0x01 }, | ||
| 851 | { "ZERO", 0x02, 0x02 } | ||
| 852 | }; | ||
| 853 | |||
| 854 | int | ||
| 855 | ahc_flags_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 856 | { | ||
| 857 | return (ahc_print_register(FLAGS_parse_table, 2, "FLAGS", | ||
| 858 | 0x6b, regvalue, cur_col, wrap)); | ||
| 859 | } | ||
| 860 | |||
| 861 | int | ||
| 862 | ahc_sindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 863 | { | ||
| 864 | return (ahc_print_register(NULL, 0, "SINDIR", | ||
| 865 | 0x6c, regvalue, cur_col, wrap)); | ||
| 866 | } | ||
| 867 | |||
| 868 | int | ||
| 869 | ahc_dindir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 870 | { | ||
| 871 | return (ahc_print_register(NULL, 0, "DINDIR", | ||
| 872 | 0x6d, regvalue, cur_col, wrap)); | ||
| 873 | } | ||
| 874 | |||
| 875 | int | ||
| 876 | ahc_stack_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 877 | { | ||
| 878 | return (ahc_print_register(NULL, 0, "STACK", | ||
| 879 | 0x6f, regvalue, cur_col, wrap)); | ||
| 880 | } | ||
| 881 | |||
| 882 | int | ||
| 883 | ahc_targ_offset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 884 | { | ||
| 885 | return (ahc_print_register(NULL, 0, "TARG_OFFSET", | ||
| 886 | 0x70, regvalue, cur_col, wrap)); | ||
| 887 | } | ||
| 888 | |||
| 889 | int | ||
| 890 | ahc_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 277 | ahc_sram_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 891 | { | 278 | { |
| 892 | return (ahc_print_register(NULL, 0, "SRAM_BASE", | 279 | return (ahc_print_register(NULL, 0, "SRAM_BASE", |
| 893 | 0x70, regvalue, cur_col, wrap)); | 280 | 0x70, regvalue, cur_col, wrap)); |
| 894 | } | 281 | } |
| 895 | 282 | ||
| 896 | static const ahc_reg_parse_entry_t DSCOMMAND0_parse_table[] = { | ||
| 897 | { "CIOPARCKEN", 0x01, 0x01 }, | ||
| 898 | { "USCBSIZE32", 0x02, 0x02 }, | ||
| 899 | { "RAMPS", 0x04, 0x04 }, | ||
| 900 | { "INTSCBRAMSEL", 0x08, 0x08 }, | ||
| 901 | { "EXTREQLCK", 0x10, 0x10 }, | ||
| 902 | { "MPARCKEN", 0x20, 0x20 }, | ||
| 903 | { "DPARCKEN", 0x40, 0x40 }, | ||
| 904 | { "CACHETHEN", 0x80, 0x80 } | ||
| 905 | }; | ||
| 906 | |||
| 907 | int | ||
| 908 | ahc_dscommand0_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 909 | { | ||
| 910 | return (ahc_print_register(DSCOMMAND0_parse_table, 8, "DSCOMMAND0", | ||
| 911 | 0x84, regvalue, cur_col, wrap)); | ||
| 912 | } | ||
| 913 | |||
| 914 | static const ahc_reg_parse_entry_t BUSTIME_parse_table[] = { | ||
| 915 | { "BON", 0x0f, 0x0f }, | ||
| 916 | { "BOFF", 0xf0, 0xf0 } | ||
| 917 | }; | ||
| 918 | |||
| 919 | int | ||
| 920 | ahc_bustime_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 921 | { | ||
| 922 | return (ahc_print_register(BUSTIME_parse_table, 2, "BUSTIME", | ||
| 923 | 0x85, regvalue, cur_col, wrap)); | ||
| 924 | } | ||
| 925 | |||
| 926 | static const ahc_reg_parse_entry_t DSCOMMAND1_parse_table[] = { | ||
| 927 | { "HADDLDSEL0", 0x01, 0x01 }, | ||
| 928 | { "HADDLDSEL1", 0x02, 0x02 }, | ||
| 929 | { "DSLATT", 0xfc, 0xfc } | ||
| 930 | }; | ||
| 931 | |||
| 932 | int | ||
| 933 | ahc_dscommand1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 934 | { | ||
| 935 | return (ahc_print_register(DSCOMMAND1_parse_table, 3, "DSCOMMAND1", | ||
| 936 | 0x85, regvalue, cur_col, wrap)); | ||
| 937 | } | ||
| 938 | |||
| 939 | static const ahc_reg_parse_entry_t BUSSPD_parse_table[] = { | ||
| 940 | { "STBON", 0x07, 0x07 }, | ||
| 941 | { "STBOFF", 0x38, 0x38 }, | ||
| 942 | { "DFTHRSH_75", 0x80, 0x80 }, | ||
| 943 | { "DFTHRSH", 0xc0, 0xc0 }, | ||
| 944 | { "DFTHRSH_100", 0xc0, 0xc0 } | ||
| 945 | }; | ||
| 946 | |||
| 947 | int | ||
| 948 | ahc_busspd_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 949 | { | ||
| 950 | return (ahc_print_register(BUSSPD_parse_table, 5, "BUSSPD", | ||
| 951 | 0x86, regvalue, cur_col, wrap)); | ||
| 952 | } | ||
| 953 | |||
| 954 | static const ahc_reg_parse_entry_t HS_MAILBOX_parse_table[] = { | ||
| 955 | { "SEQ_MAILBOX", 0x0f, 0x0f }, | ||
| 956 | { "HOST_TQINPOS", 0x80, 0x80 }, | ||
| 957 | { "HOST_MAILBOX", 0xf0, 0xf0 } | ||
| 958 | }; | ||
| 959 | |||
| 960 | int | ||
| 961 | ahc_hs_mailbox_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 962 | { | ||
| 963 | return (ahc_print_register(HS_MAILBOX_parse_table, 3, "HS_MAILBOX", | ||
| 964 | 0x86, regvalue, cur_col, wrap)); | ||
| 965 | } | ||
| 966 | |||
| 967 | static const ahc_reg_parse_entry_t DSPCISTATUS_parse_table[] = { | ||
| 968 | { "DFTHRSH_100", 0xc0, 0xc0 } | ||
| 969 | }; | ||
| 970 | |||
| 971 | int | ||
| 972 | ahc_dspcistatus_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 973 | { | ||
| 974 | return (ahc_print_register(DSPCISTATUS_parse_table, 1, "DSPCISTATUS", | ||
| 975 | 0x86, regvalue, cur_col, wrap)); | ||
| 976 | } | ||
| 977 | |||
| 978 | static const ahc_reg_parse_entry_t HCNTRL_parse_table[] = { | ||
| 979 | { "CHIPRST", 0x01, 0x01 }, | ||
| 980 | { "CHIPRSTACK", 0x01, 0x01 }, | ||
| 981 | { "INTEN", 0x02, 0x02 }, | ||
| 982 | { "PAUSE", 0x04, 0x04 }, | ||
| 983 | { "IRQMS", 0x08, 0x08 }, | ||
| 984 | { "SWINT", 0x10, 0x10 }, | ||
| 985 | { "POWRDN", 0x40, 0x40 } | ||
| 986 | }; | ||
| 987 | |||
| 988 | int | ||
| 989 | ahc_hcntrl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 990 | { | ||
| 991 | return (ahc_print_register(HCNTRL_parse_table, 7, "HCNTRL", | ||
| 992 | 0x87, regvalue, cur_col, wrap)); | ||
| 993 | } | ||
| 994 | |||
| 995 | int | ||
| 996 | ahc_haddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 997 | { | ||
| 998 | return (ahc_print_register(NULL, 0, "HADDR", | ||
| 999 | 0x88, regvalue, cur_col, wrap)); | ||
| 1000 | } | ||
| 1001 | |||
| 1002 | int | ||
| 1003 | ahc_hcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1004 | { | ||
| 1005 | return (ahc_print_register(NULL, 0, "HCNT", | ||
| 1006 | 0x8c, regvalue, cur_col, wrap)); | ||
| 1007 | } | ||
| 1008 | |||
| 1009 | int | ||
| 1010 | ahc_scbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1011 | { | ||
| 1012 | return (ahc_print_register(NULL, 0, "SCBPTR", | ||
| 1013 | 0x90, regvalue, cur_col, wrap)); | ||
| 1014 | } | ||
| 1015 | |||
| 1016 | static const ahc_reg_parse_entry_t INTSTAT_parse_table[] = { | ||
| 1017 | { "SEQINT", 0x01, 0x01 }, | ||
| 1018 | { "CMDCMPLT", 0x02, 0x02 }, | ||
| 1019 | { "SCSIINT", 0x04, 0x04 }, | ||
| 1020 | { "BRKADRINT", 0x08, 0x08 }, | ||
| 1021 | { "BAD_PHASE", 0x01, 0x01 }, | ||
| 1022 | { "INT_PEND", 0x0f, 0x0f }, | ||
| 1023 | { "SEND_REJECT", 0x11, 0x11 }, | ||
| 1024 | { "PROTO_VIOLATION", 0x21, 0x21 }, | ||
| 1025 | { "NO_MATCH", 0x31, 0x31 }, | ||
| 1026 | { "IGN_WIDE_RES", 0x41, 0x41 }, | ||
| 1027 | { "PDATA_REINIT", 0x51, 0x51 }, | ||
| 1028 | { "HOST_MSG_LOOP", 0x61, 0x61 }, | ||
| 1029 | { "BAD_STATUS", 0x71, 0x71 }, | ||
| 1030 | { "PERR_DETECTED", 0x81, 0x81 }, | ||
| 1031 | { "DATA_OVERRUN", 0x91, 0x91 }, | ||
| 1032 | { "MKMSG_FAILED", 0xa1, 0xa1 }, | ||
| 1033 | { "MISSED_BUSFREE", 0xb1, 0xb1 }, | ||
| 1034 | { "SCB_MISMATCH", 0xc1, 0xc1 }, | ||
| 1035 | { "NO_FREE_SCB", 0xd1, 0xd1 }, | ||
| 1036 | { "OUT_OF_RANGE", 0xe1, 0xe1 }, | ||
| 1037 | { "SEQINT_MASK", 0xf1, 0xf1 } | ||
| 1038 | }; | ||
| 1039 | |||
| 1040 | int | ||
| 1041 | ahc_intstat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1042 | { | ||
| 1043 | return (ahc_print_register(INTSTAT_parse_table, 21, "INTSTAT", | ||
| 1044 | 0x91, regvalue, cur_col, wrap)); | ||
| 1045 | } | ||
| 1046 | |||
| 1047 | static const ahc_reg_parse_entry_t CLRINT_parse_table[] = { | ||
| 1048 | { "CLRSEQINT", 0x01, 0x01 }, | ||
| 1049 | { "CLRCMDINT", 0x02, 0x02 }, | ||
| 1050 | { "CLRSCSIINT", 0x04, 0x04 }, | ||
| 1051 | { "CLRBRKADRINT", 0x08, 0x08 }, | ||
| 1052 | { "CLRPARERR", 0x10, 0x10 } | ||
| 1053 | }; | ||
| 1054 | |||
| 1055 | int | ||
| 1056 | ahc_clrint_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1057 | { | ||
| 1058 | return (ahc_print_register(CLRINT_parse_table, 5, "CLRINT", | ||
| 1059 | 0x92, regvalue, cur_col, wrap)); | ||
| 1060 | } | ||
| 1061 | |||
| 1062 | static const ahc_reg_parse_entry_t ERROR_parse_table[] = { | 283 | static const ahc_reg_parse_entry_t ERROR_parse_table[] = { |
| 1063 | { "ILLHADDR", 0x01, 0x01 }, | 284 | { "ILLHADDR", 0x01, 0x01 }, |
| 1064 | { "ILLSADDR", 0x02, 0x02 }, | 285 | { "ILLSADDR", 0x02, 0x02 }, |
| @@ -1115,62 +336,6 @@ ahc_dfstatus_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1115 | 0x94, regvalue, cur_col, wrap)); | 336 | 0x94, regvalue, cur_col, wrap)); |
| 1116 | } | 337 | } |
| 1117 | 338 | ||
| 1118 | int | ||
| 1119 | ahc_dfwaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1120 | { | ||
| 1121 | return (ahc_print_register(NULL, 0, "DFWADDR", | ||
| 1122 | 0x95, regvalue, cur_col, wrap)); | ||
| 1123 | } | ||
| 1124 | |||
| 1125 | int | ||
| 1126 | ahc_dfdat_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1127 | { | ||
| 1128 | return (ahc_print_register(NULL, 0, "DFDAT", | ||
| 1129 | 0x99, regvalue, cur_col, wrap)); | ||
| 1130 | } | ||
| 1131 | |||
| 1132 | static const ahc_reg_parse_entry_t SCBCNT_parse_table[] = { | ||
| 1133 | { "SCBAUTO", 0x80, 0x80 }, | ||
| 1134 | { "SCBCNT_MASK", 0x1f, 0x1f } | ||
| 1135 | }; | ||
| 1136 | |||
| 1137 | int | ||
| 1138 | ahc_scbcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1139 | { | ||
| 1140 | return (ahc_print_register(SCBCNT_parse_table, 2, "SCBCNT", | ||
| 1141 | 0x9a, regvalue, cur_col, wrap)); | ||
| 1142 | } | ||
| 1143 | |||
| 1144 | int | ||
| 1145 | ahc_qinfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1146 | { | ||
| 1147 | return (ahc_print_register(NULL, 0, "QINFIFO", | ||
| 1148 | 0x9b, regvalue, cur_col, wrap)); | ||
| 1149 | } | ||
| 1150 | |||
| 1151 | int | ||
| 1152 | ahc_qoutfifo_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1153 | { | ||
| 1154 | return (ahc_print_register(NULL, 0, "QOUTFIFO", | ||
| 1155 | 0x9d, regvalue, cur_col, wrap)); | ||
| 1156 | } | ||
| 1157 | |||
| 1158 | static const ahc_reg_parse_entry_t CRCCONTROL1_parse_table[] = { | ||
| 1159 | { "TARGCRCCNTEN", 0x04, 0x04 }, | ||
| 1160 | { "TARGCRCENDEN", 0x08, 0x08 }, | ||
| 1161 | { "CRCREQCHKEN", 0x10, 0x10 }, | ||
| 1162 | { "CRCENDCHKEN", 0x20, 0x20 }, | ||
| 1163 | { "CRCVALCHKEN", 0x40, 0x40 }, | ||
| 1164 | { "CRCONSEEN", 0x80, 0x80 } | ||
| 1165 | }; | ||
| 1166 | |||
| 1167 | int | ||
| 1168 | ahc_crccontrol1_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1169 | { | ||
| 1170 | return (ahc_print_register(CRCCONTROL1_parse_table, 6, "CRCCONTROL1", | ||
| 1171 | 0x9d, regvalue, cur_col, wrap)); | ||
| 1172 | } | ||
| 1173 | |||
| 1174 | static const ahc_reg_parse_entry_t SCSIPHASE_parse_table[] = { | 339 | static const ahc_reg_parse_entry_t SCSIPHASE_parse_table[] = { |
| 1175 | { "DATA_OUT_PHASE", 0x01, 0x01 }, | 340 | { "DATA_OUT_PHASE", 0x01, 0x01 }, |
| 1176 | { "DATA_IN_PHASE", 0x02, 0x02 }, | 341 | { "DATA_IN_PHASE", 0x02, 0x02 }, |
| @@ -1188,17 +353,6 @@ ahc_scsiphase_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1188 | 0x9e, regvalue, cur_col, wrap)); | 353 | 0x9e, regvalue, cur_col, wrap)); |
| 1189 | } | 354 | } |
| 1190 | 355 | ||
| 1191 | static const ahc_reg_parse_entry_t SFUNCT_parse_table[] = { | ||
| 1192 | { "ALT_MODE", 0x80, 0x80 } | ||
| 1193 | }; | ||
| 1194 | |||
| 1195 | int | ||
| 1196 | ahc_sfunct_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1197 | { | ||
| 1198 | return (ahc_print_register(SFUNCT_parse_table, 1, "SFUNCT", | ||
| 1199 | 0x9f, regvalue, cur_col, wrap)); | ||
| 1200 | } | ||
| 1201 | |||
| 1202 | int | 356 | int |
| 1203 | ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | 357 | ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) |
| 1204 | { | 358 | { |
| @@ -1206,80 +360,6 @@ ahc_scb_base_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1206 | 0xa0, regvalue, cur_col, wrap)); | 360 | 0xa0, regvalue, cur_col, wrap)); |
| 1207 | } | 361 | } |
| 1208 | 362 | ||
| 1209 | int | ||
| 1210 | ahc_scb_cdb_ptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1211 | { | ||
| 1212 | return (ahc_print_register(NULL, 0, "SCB_CDB_PTR", | ||
| 1213 | 0xa0, regvalue, cur_col, wrap)); | ||
| 1214 | } | ||
| 1215 | |||
| 1216 | int | ||
| 1217 | ahc_scb_residual_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1218 | { | ||
| 1219 | return (ahc_print_register(NULL, 0, "SCB_RESIDUAL_SGPTR", | ||
| 1220 | 0xa4, regvalue, cur_col, wrap)); | ||
| 1221 | } | ||
| 1222 | |||
| 1223 | int | ||
| 1224 | ahc_scb_scsi_status_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1225 | { | ||
| 1226 | return (ahc_print_register(NULL, 0, "SCB_SCSI_STATUS", | ||
| 1227 | 0xa8, regvalue, cur_col, wrap)); | ||
| 1228 | } | ||
| 1229 | |||
| 1230 | int | ||
| 1231 | ahc_scb_target_phases_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1232 | { | ||
| 1233 | return (ahc_print_register(NULL, 0, "SCB_TARGET_PHASES", | ||
| 1234 | 0xa9, regvalue, cur_col, wrap)); | ||
| 1235 | } | ||
| 1236 | |||
| 1237 | int | ||
| 1238 | ahc_scb_target_data_dir_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1239 | { | ||
| 1240 | return (ahc_print_register(NULL, 0, "SCB_TARGET_DATA_DIR", | ||
| 1241 | 0xaa, regvalue, cur_col, wrap)); | ||
| 1242 | } | ||
| 1243 | |||
| 1244 | int | ||
| 1245 | ahc_scb_target_itag_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1246 | { | ||
| 1247 | return (ahc_print_register(NULL, 0, "SCB_TARGET_ITAG", | ||
| 1248 | 0xab, regvalue, cur_col, wrap)); | ||
| 1249 | } | ||
| 1250 | |||
| 1251 | int | ||
| 1252 | ahc_scb_dataptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1253 | { | ||
| 1254 | return (ahc_print_register(NULL, 0, "SCB_DATAPTR", | ||
| 1255 | 0xac, regvalue, cur_col, wrap)); | ||
| 1256 | } | ||
| 1257 | |||
| 1258 | static const ahc_reg_parse_entry_t SCB_DATACNT_parse_table[] = { | ||
| 1259 | { "SG_LAST_SEG", 0x80, 0x80 }, | ||
| 1260 | { "SG_HIGH_ADDR_BITS", 0x7f, 0x7f } | ||
| 1261 | }; | ||
| 1262 | |||
| 1263 | int | ||
| 1264 | ahc_scb_datacnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1265 | { | ||
| 1266 | return (ahc_print_register(SCB_DATACNT_parse_table, 2, "SCB_DATACNT", | ||
| 1267 | 0xb0, regvalue, cur_col, wrap)); | ||
| 1268 | } | ||
| 1269 | |||
| 1270 | static const ahc_reg_parse_entry_t SCB_SGPTR_parse_table[] = { | ||
| 1271 | { "SG_LIST_NULL", 0x01, 0x01 }, | ||
| 1272 | { "SG_FULL_RESID", 0x02, 0x02 }, | ||
| 1273 | { "SG_RESID_VALID", 0x04, 0x04 } | ||
| 1274 | }; | ||
| 1275 | |||
| 1276 | int | ||
| 1277 | ahc_scb_sgptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1278 | { | ||
| 1279 | return (ahc_print_register(SCB_SGPTR_parse_table, 3, "SCB_SGPTR", | ||
| 1280 | 0xb4, regvalue, cur_col, wrap)); | ||
| 1281 | } | ||
| 1282 | |||
| 1283 | static const ahc_reg_parse_entry_t SCB_CONTROL_parse_table[] = { | 363 | static const ahc_reg_parse_entry_t SCB_CONTROL_parse_table[] = { |
| 1284 | { "DISCONNECTED", 0x04, 0x04 }, | 364 | { "DISCONNECTED", 0x04, 0x04 }, |
| 1285 | { "ULTRAENB", 0x08, 0x08 }, | 365 | { "ULTRAENB", 0x08, 0x08 }, |
| @@ -1331,248 +411,3 @@ ahc_scb_tag_print(u_int regvalue, u_int *cur_col, u_int wrap) | |||
| 1331 | 0xbb, regvalue, cur_col, wrap)); | 411 | 0xbb, regvalue, cur_col, wrap)); |
| 1332 | } | 412 | } |
| 1333 | 413 | ||
| 1334 | int | ||
| 1335 | ahc_scb_cdb_len_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1336 | { | ||
| 1337 | return (ahc_print_register(NULL, 0, "SCB_CDB_LEN", | ||
| 1338 | 0xbc, regvalue, cur_col, wrap)); | ||
| 1339 | } | ||
| 1340 | |||
| 1341 | int | ||
| 1342 | ahc_scb_scsirate_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1343 | { | ||
| 1344 | return (ahc_print_register(NULL, 0, "SCB_SCSIRATE", | ||
| 1345 | 0xbd, regvalue, cur_col, wrap)); | ||
| 1346 | } | ||
| 1347 | |||
| 1348 | int | ||
| 1349 | ahc_scb_scsioffset_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1350 | { | ||
| 1351 | return (ahc_print_register(NULL, 0, "SCB_SCSIOFFSET", | ||
| 1352 | 0xbe, regvalue, cur_col, wrap)); | ||
| 1353 | } | ||
| 1354 | |||
| 1355 | int | ||
| 1356 | ahc_scb_next_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1357 | { | ||
| 1358 | return (ahc_print_register(NULL, 0, "SCB_NEXT", | ||
| 1359 | 0xbf, regvalue, cur_col, wrap)); | ||
| 1360 | } | ||
| 1361 | |||
| 1362 | static const ahc_reg_parse_entry_t SEECTL_2840_parse_table[] = { | ||
| 1363 | { "DO_2840", 0x01, 0x01 }, | ||
| 1364 | { "CK_2840", 0x02, 0x02 }, | ||
| 1365 | { "CS_2840", 0x04, 0x04 } | ||
| 1366 | }; | ||
| 1367 | |||
| 1368 | int | ||
| 1369 | ahc_seectl_2840_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1370 | { | ||
| 1371 | return (ahc_print_register(SEECTL_2840_parse_table, 3, "SEECTL_2840", | ||
| 1372 | 0xc0, regvalue, cur_col, wrap)); | ||
| 1373 | } | ||
| 1374 | |||
| 1375 | static const ahc_reg_parse_entry_t STATUS_2840_parse_table[] = { | ||
| 1376 | { "DI_2840", 0x01, 0x01 }, | ||
| 1377 | { "EEPROM_TF", 0x80, 0x80 }, | ||
| 1378 | { "ADSEL", 0x1e, 0x1e }, | ||
| 1379 | { "BIOS_SEL", 0x60, 0x60 } | ||
| 1380 | }; | ||
| 1381 | |||
| 1382 | int | ||
| 1383 | ahc_status_2840_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1384 | { | ||
| 1385 | return (ahc_print_register(STATUS_2840_parse_table, 4, "STATUS_2840", | ||
| 1386 | 0xc1, regvalue, cur_col, wrap)); | ||
| 1387 | } | ||
| 1388 | |||
| 1389 | int | ||
| 1390 | ahc_scb_64_btt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1391 | { | ||
| 1392 | return (ahc_print_register(NULL, 0, "SCB_64_BTT", | ||
| 1393 | 0xd0, regvalue, cur_col, wrap)); | ||
| 1394 | } | ||
| 1395 | |||
| 1396 | int | ||
| 1397 | ahc_cchaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1398 | { | ||
| 1399 | return (ahc_print_register(NULL, 0, "CCHADDR", | ||
| 1400 | 0xe0, regvalue, cur_col, wrap)); | ||
| 1401 | } | ||
| 1402 | |||
| 1403 | int | ||
| 1404 | ahc_cchcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1405 | { | ||
| 1406 | return (ahc_print_register(NULL, 0, "CCHCNT", | ||
| 1407 | 0xe8, regvalue, cur_col, wrap)); | ||
| 1408 | } | ||
| 1409 | |||
| 1410 | int | ||
| 1411 | ahc_ccsgram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1412 | { | ||
| 1413 | return (ahc_print_register(NULL, 0, "CCSGRAM", | ||
| 1414 | 0xe9, regvalue, cur_col, wrap)); | ||
| 1415 | } | ||
| 1416 | |||
| 1417 | int | ||
| 1418 | ahc_ccsgaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1419 | { | ||
| 1420 | return (ahc_print_register(NULL, 0, "CCSGADDR", | ||
| 1421 | 0xea, regvalue, cur_col, wrap)); | ||
| 1422 | } | ||
| 1423 | |||
| 1424 | static const ahc_reg_parse_entry_t CCSGCTL_parse_table[] = { | ||
| 1425 | { "CCSGRESET", 0x01, 0x01 }, | ||
| 1426 | { "SG_FETCH_NEEDED", 0x02, 0x02 }, | ||
| 1427 | { "CCSGEN", 0x08, 0x08 }, | ||
| 1428 | { "CCSGDONE", 0x80, 0x80 } | ||
| 1429 | }; | ||
| 1430 | |||
| 1431 | int | ||
| 1432 | ahc_ccsgctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1433 | { | ||
| 1434 | return (ahc_print_register(CCSGCTL_parse_table, 4, "CCSGCTL", | ||
| 1435 | 0xeb, regvalue, cur_col, wrap)); | ||
| 1436 | } | ||
| 1437 | |||
| 1438 | int | ||
| 1439 | ahc_ccscbram_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1440 | { | ||
| 1441 | return (ahc_print_register(NULL, 0, "CCSCBRAM", | ||
| 1442 | 0xec, regvalue, cur_col, wrap)); | ||
| 1443 | } | ||
| 1444 | |||
| 1445 | int | ||
| 1446 | ahc_ccscbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1447 | { | ||
| 1448 | return (ahc_print_register(NULL, 0, "CCSCBADDR", | ||
| 1449 | 0xed, regvalue, cur_col, wrap)); | ||
| 1450 | } | ||
| 1451 | |||
| 1452 | static const ahc_reg_parse_entry_t CCSCBCTL_parse_table[] = { | ||
| 1453 | { "CCSCBRESET", 0x01, 0x01 }, | ||
| 1454 | { "CCSCBDIR", 0x04, 0x04 }, | ||
| 1455 | { "CCSCBEN", 0x08, 0x08 }, | ||
| 1456 | { "CCARREN", 0x10, 0x10 }, | ||
| 1457 | { "ARRDONE", 0x40, 0x40 }, | ||
| 1458 | { "CCSCBDONE", 0x80, 0x80 } | ||
| 1459 | }; | ||
| 1460 | |||
| 1461 | int | ||
| 1462 | ahc_ccscbctl_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1463 | { | ||
| 1464 | return (ahc_print_register(CCSCBCTL_parse_table, 6, "CCSCBCTL", | ||
| 1465 | 0xee, regvalue, cur_col, wrap)); | ||
| 1466 | } | ||
| 1467 | |||
| 1468 | int | ||
| 1469 | ahc_ccscbcnt_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1470 | { | ||
| 1471 | return (ahc_print_register(NULL, 0, "CCSCBCNT", | ||
| 1472 | 0xef, regvalue, cur_col, wrap)); | ||
| 1473 | } | ||
| 1474 | |||
| 1475 | int | ||
| 1476 | ahc_scbbaddr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1477 | { | ||
| 1478 | return (ahc_print_register(NULL, 0, "SCBBADDR", | ||
| 1479 | 0xf0, regvalue, cur_col, wrap)); | ||
| 1480 | } | ||
| 1481 | |||
| 1482 | int | ||
| 1483 | ahc_ccscbptr_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1484 | { | ||
| 1485 | return (ahc_print_register(NULL, 0, "CCSCBPTR", | ||
| 1486 | 0xf1, regvalue, cur_col, wrap)); | ||
| 1487 | } | ||
| 1488 | |||
| 1489 | int | ||
| 1490 | ahc_hnscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1491 | { | ||
| 1492 | return (ahc_print_register(NULL, 0, "HNSCB_QOFF", | ||
| 1493 | 0xf4, regvalue, cur_col, wrap)); | ||
| 1494 | } | ||
| 1495 | |||
| 1496 | int | ||
| 1497 | ahc_snscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1498 | { | ||
| 1499 | return (ahc_print_register(NULL, 0, "SNSCB_QOFF", | ||
| 1500 | 0xf6, regvalue, cur_col, wrap)); | ||
| 1501 | } | ||
| 1502 | |||
| 1503 | int | ||
| 1504 | ahc_sdscb_qoff_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1505 | { | ||
| 1506 | return (ahc_print_register(NULL, 0, "SDSCB_QOFF", | ||
| 1507 | 0xf8, regvalue, cur_col, wrap)); | ||
| 1508 | } | ||
| 1509 | |||
| 1510 | static const ahc_reg_parse_entry_t QOFF_CTLSTA_parse_table[] = { | ||
| 1511 | { "SDSCB_ROLLOVER", 0x10, 0x10 }, | ||
| 1512 | { "SNSCB_ROLLOVER", 0x20, 0x20 }, | ||
| 1513 | { "SCB_AVAIL", 0x40, 0x40 }, | ||
| 1514 | { "SCB_QSIZE_256", 0x06, 0x06 }, | ||
| 1515 | { "SCB_QSIZE", 0x07, 0x07 } | ||
| 1516 | }; | ||
| 1517 | |||
| 1518 | int | ||
| 1519 | ahc_qoff_ctlsta_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1520 | { | ||
| 1521 | return (ahc_print_register(QOFF_CTLSTA_parse_table, 5, "QOFF_CTLSTA", | ||
| 1522 | 0xfa, regvalue, cur_col, wrap)); | ||
| 1523 | } | ||
| 1524 | |||
| 1525 | static const ahc_reg_parse_entry_t DFF_THRSH_parse_table[] = { | ||
| 1526 | { "RD_DFTHRSH_MIN", 0x00, 0x00 }, | ||
| 1527 | { "WR_DFTHRSH_MIN", 0x00, 0x00 }, | ||
| 1528 | { "RD_DFTHRSH_25", 0x01, 0x01 }, | ||
| 1529 | { "RD_DFTHRSH_50", 0x02, 0x02 }, | ||
| 1530 | { "RD_DFTHRSH_63", 0x03, 0x03 }, | ||
| 1531 | { "RD_DFTHRSH_75", 0x04, 0x04 }, | ||
| 1532 | { "RD_DFTHRSH_85", 0x05, 0x05 }, | ||
| 1533 | { "RD_DFTHRSH_90", 0x06, 0x06 }, | ||
| 1534 | { "RD_DFTHRSH", 0x07, 0x07 }, | ||
| 1535 | { "RD_DFTHRSH_MAX", 0x07, 0x07 }, | ||
| 1536 | { "WR_DFTHRSH_25", 0x10, 0x10 }, | ||
| 1537 | { "WR_DFTHRSH_50", 0x20, 0x20 }, | ||
| 1538 | { "WR_DFTHRSH_63", 0x30, 0x30 }, | ||
| 1539 | { "WR_DFTHRSH_75", 0x40, 0x40 }, | ||
| 1540 | { "WR_DFTHRSH_85", 0x50, 0x50 }, | ||
| 1541 | { "WR_DFTHRSH_90", 0x60, 0x60 }, | ||
| 1542 | { "WR_DFTHRSH", 0x70, 0x70 }, | ||
| 1543 | { "WR_DFTHRSH_MAX", 0x70, 0x70 } | ||
| 1544 | }; | ||
| 1545 | |||
| 1546 | int | ||
| 1547 | ahc_dff_thrsh_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1548 | { | ||
| 1549 | return (ahc_print_register(DFF_THRSH_parse_table, 18, "DFF_THRSH", | ||
| 1550 | 0xfb, regvalue, cur_col, wrap)); | ||
| 1551 | } | ||
| 1552 | |||
| 1553 | static const ahc_reg_parse_entry_t SG_CACHE_SHADOW_parse_table[] = { | ||
| 1554 | { "LAST_SEG_DONE", 0x01, 0x01 }, | ||
| 1555 | { "LAST_SEG", 0x02, 0x02 }, | ||
| 1556 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
| 1557 | }; | ||
| 1558 | |||
| 1559 | int | ||
| 1560 | ahc_sg_cache_shadow_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1561 | { | ||
| 1562 | return (ahc_print_register(SG_CACHE_SHADOW_parse_table, 3, "SG_CACHE_SHADOW", | ||
| 1563 | 0xfc, regvalue, cur_col, wrap)); | ||
| 1564 | } | ||
| 1565 | |||
| 1566 | static const ahc_reg_parse_entry_t SG_CACHE_PRE_parse_table[] = { | ||
| 1567 | { "LAST_SEG_DONE", 0x01, 0x01 }, | ||
| 1568 | { "LAST_SEG", 0x02, 0x02 }, | ||
| 1569 | { "SG_ADDR_MASK", 0xf8, 0xf8 } | ||
| 1570 | }; | ||
| 1571 | |||
| 1572 | int | ||
| 1573 | ahc_sg_cache_pre_print(u_int regvalue, u_int *cur_col, u_int wrap) | ||
| 1574 | { | ||
| 1575 | return (ahc_print_register(SG_CACHE_PRE_parse_table, 3, "SG_CACHE_PRE", | ||
| 1576 | 0xfc, regvalue, cur_col, wrap)); | ||
| 1577 | } | ||
| 1578 | |||
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y b/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y index 81be6a261cc8..e4064433842e 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_gram.y | |||
| @@ -147,6 +147,8 @@ void yyerror(const char *string); | |||
| 147 | 147 | ||
| 148 | %token T_ACCESS_MODE | 148 | %token T_ACCESS_MODE |
| 149 | 149 | ||
| 150 | %token T_DONT_GENERATE_DEBUG_CODE | ||
| 151 | |||
| 150 | %token T_MODES | 152 | %token T_MODES |
| 151 | 153 | ||
| 152 | %token T_DEFINE | 154 | %token T_DEFINE |
| @@ -357,6 +359,7 @@ reg_attribute: | |||
| 357 | | size | 359 | | size |
| 358 | | count | 360 | | count |
| 359 | | access_mode | 361 | | access_mode |
| 362 | | dont_generate_debug_code | ||
| 360 | | modes | 363 | | modes |
| 361 | | field_defn | 364 | | field_defn |
| 362 | | enum_defn | 365 | | enum_defn |
| @@ -410,6 +413,13 @@ access_mode: | |||
| 410 | } | 413 | } |
| 411 | ; | 414 | ; |
| 412 | 415 | ||
| 416 | dont_generate_debug_code: | ||
| 417 | T_DONT_GENERATE_DEBUG_CODE | ||
| 418 | { | ||
| 419 | cur_symbol->dont_generate_debug_code = 1; | ||
| 420 | } | ||
| 421 | ; | ||
| 422 | |||
| 413 | modes: | 423 | modes: |
| 414 | T_MODES mode_list | 424 | T_MODES mode_list |
| 415 | { | 425 | { |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l b/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l index 2c7f02daf88d..93c8667cd704 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_scan.l | |||
| @@ -164,6 +164,7 @@ download { return T_DOWNLOAD; } | |||
| 164 | address { return T_ADDRESS; } | 164 | address { return T_ADDRESS; } |
| 165 | count { return T_COUNT; } | 165 | count { return T_COUNT; } |
| 166 | access_mode { return T_ACCESS_MODE; } | 166 | access_mode { return T_ACCESS_MODE; } |
| 167 | dont_generate_debug_code { return T_DONT_GENERATE_DEBUG_CODE; } | ||
| 167 | modes { return T_MODES; } | 168 | modes { return T_MODES; } |
| 168 | RW|RO|WO { | 169 | RW|RO|WO { |
| 169 | if (strcmp(yytext, "RW") == 0) | 170 | if (strcmp(yytext, "RW") == 0) |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c index fcd357872b43..078ed600f47a 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.c | |||
| @@ -539,6 +539,9 @@ symtable_dump(FILE *ofile, FILE *dfile) | |||
| 539 | aic_print_include(dfile, stock_include_file); | 539 | aic_print_include(dfile, stock_include_file); |
| 540 | SLIST_FOREACH(curnode, ®isters, links) { | 540 | SLIST_FOREACH(curnode, ®isters, links) { |
| 541 | 541 | ||
| 542 | if (curnode->symbol->dont_generate_debug_code) | ||
| 543 | continue; | ||
| 544 | |||
| 542 | switch(curnode->symbol->type) { | 545 | switch(curnode->symbol->type) { |
| 543 | case REGISTER: | 546 | case REGISTER: |
| 544 | case SCBLOC: | 547 | case SCBLOC: |
diff --git a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h index 05190c1a2fb7..2ba73ae7c777 100644 --- a/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h +++ b/drivers/scsi/aic7xxx/aicasm/aicasm_symbol.h | |||
| @@ -137,7 +137,8 @@ typedef struct symbol { | |||
| 137 | struct label_info *linfo; | 137 | struct label_info *linfo; |
| 138 | struct cond_info *condinfo; | 138 | struct cond_info *condinfo; |
| 139 | struct macro_info *macroinfo; | 139 | struct macro_info *macroinfo; |
| 140 | }info; | 140 | } info; |
| 141 | int dont_generate_debug_code; | ||
| 141 | } symbol_t; | 142 | } symbol_t; |
| 142 | 143 | ||
| 143 | typedef struct symbol_ref { | 144 | typedef struct symbol_ref { |
diff --git a/drivers/scsi/device_handler/scsi_dh_rdac.c b/drivers/scsi/device_handler/scsi_dh_rdac.c index a43c3ed4df28..3d50cabca7ee 100644 --- a/drivers/scsi/device_handler/scsi_dh_rdac.c +++ b/drivers/scsi/device_handler/scsi_dh_rdac.c | |||
| @@ -401,6 +401,9 @@ static int check_ownership(struct scsi_device *sdev, struct rdac_dh_data *h) | |||
| 401 | } | 401 | } |
| 402 | } | 402 | } |
| 403 | 403 | ||
| 404 | if (h->lun_state == RDAC_LUN_UNOWNED) | ||
| 405 | h->state = RDAC_STATE_PASSIVE; | ||
| 406 | |||
| 404 | return err; | 407 | return err; |
| 405 | } | 408 | } |
| 406 | 409 | ||
diff --git a/drivers/scsi/ipr.c b/drivers/scsi/ipr.c index 098739deb02e..ded854a6dd35 100644 --- a/drivers/scsi/ipr.c +++ b/drivers/scsi/ipr.c | |||
| @@ -2456,20 +2456,14 @@ static ssize_t ipr_read_trace(struct kobject *kobj, | |||
| 2456 | struct Scsi_Host *shost = class_to_shost(dev); | 2456 | struct Scsi_Host *shost = class_to_shost(dev); |
| 2457 | struct ipr_ioa_cfg *ioa_cfg = (struct ipr_ioa_cfg *)shost->hostdata; | 2457 | struct ipr_ioa_cfg *ioa_cfg = (struct ipr_ioa_cfg *)shost->hostdata; |
| 2458 | unsigned long lock_flags = 0; | 2458 | unsigned long lock_flags = 0; |
| 2459 | int size = IPR_TRACE_SIZE; | 2459 | ssize_t ret; |
| 2460 | char *src = (char *)ioa_cfg->trace; | ||
| 2461 | |||
| 2462 | if (off > size) | ||
| 2463 | return 0; | ||
| 2464 | if (off + count > size) { | ||
| 2465 | size -= off; | ||
| 2466 | count = size; | ||
| 2467 | } | ||
| 2468 | 2460 | ||
| 2469 | spin_lock_irqsave(ioa_cfg->host->host_lock, lock_flags); | 2461 | spin_lock_irqsave(ioa_cfg->host->host_lock, lock_flags); |
| 2470 | memcpy(buf, &src[off], count); | 2462 | ret = memory_read_from_buffer(buf, count, &off, ioa_cfg->trace, |
| 2463 | IPR_TRACE_SIZE); | ||
| 2471 | spin_unlock_irqrestore(ioa_cfg->host->host_lock, lock_flags); | 2464 | spin_unlock_irqrestore(ioa_cfg->host->host_lock, lock_flags); |
| 2472 | return count; | 2465 | |
| 2466 | return ret; | ||
| 2473 | } | 2467 | } |
| 2474 | 2468 | ||
| 2475 | static struct bin_attribute ipr_trace_attr = { | 2469 | static struct bin_attribute ipr_trace_attr = { |
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c index e5a9526d2037..f5d3b96890dc 100644 --- a/drivers/scsi/scsi_lib.c +++ b/drivers/scsi/scsi_lib.c | |||
| @@ -529,6 +529,14 @@ static void scsi_single_lun_run(struct scsi_device *current_sdev) | |||
| 529 | spin_unlock_irqrestore(shost->host_lock, flags); | 529 | spin_unlock_irqrestore(shost->host_lock, flags); |
| 530 | } | 530 | } |
| 531 | 531 | ||
| 532 | static inline int scsi_device_is_busy(struct scsi_device *sdev) | ||
| 533 | { | ||
| 534 | if (sdev->device_busy >= sdev->queue_depth || sdev->device_blocked) | ||
| 535 | return 1; | ||
| 536 | |||
| 537 | return 0; | ||
| 538 | } | ||
| 539 | |||
| 532 | static inline int scsi_target_is_busy(struct scsi_target *starget) | 540 | static inline int scsi_target_is_busy(struct scsi_target *starget) |
| 533 | { | 541 | { |
| 534 | return ((starget->can_queue > 0 && | 542 | return ((starget->can_queue > 0 && |
| @@ -536,6 +544,15 @@ static inline int scsi_target_is_busy(struct scsi_target *starget) | |||
| 536 | starget->target_blocked); | 544 | starget->target_blocked); |
| 537 | } | 545 | } |
| 538 | 546 | ||
| 547 | static inline int scsi_host_is_busy(struct Scsi_Host *shost) | ||
| 548 | { | ||
| 549 | if ((shost->can_queue > 0 && shost->host_busy >= shost->can_queue) || | ||
| 550 | shost->host_blocked || shost->host_self_blocked) | ||
| 551 | return 1; | ||
| 552 | |||
| 553 | return 0; | ||
| 554 | } | ||
| 555 | |||
| 539 | /* | 556 | /* |
| 540 | * Function: scsi_run_queue() | 557 | * Function: scsi_run_queue() |
| 541 | * | 558 | * |
| @@ -558,11 +575,7 @@ static void scsi_run_queue(struct request_queue *q) | |||
| 558 | scsi_single_lun_run(sdev); | 575 | scsi_single_lun_run(sdev); |
| 559 | 576 | ||
| 560 | spin_lock_irqsave(shost->host_lock, flags); | 577 | spin_lock_irqsave(shost->host_lock, flags); |
| 561 | while (!list_empty(&shost->starved_list) && | 578 | while (!list_empty(&shost->starved_list) && !scsi_host_is_busy(shost)) { |
| 562 | !shost->host_blocked && !shost->host_self_blocked && | ||
| 563 | !((shost->can_queue > 0) && | ||
| 564 | (shost->host_busy >= shost->can_queue))) { | ||
| 565 | |||
| 566 | int flagset; | 579 | int flagset; |
| 567 | 580 | ||
| 568 | /* | 581 | /* |
| @@ -1348,8 +1361,6 @@ int scsi_prep_fn(struct request_queue *q, struct request *req) | |||
| 1348 | static inline int scsi_dev_queue_ready(struct request_queue *q, | 1361 | static inline int scsi_dev_queue_ready(struct request_queue *q, |
| 1349 | struct scsi_device *sdev) | 1362 | struct scsi_device *sdev) |
| 1350 | { | 1363 | { |
| 1351 | if (sdev->device_busy >= sdev->queue_depth) | ||
| 1352 | return 0; | ||
| 1353 | if (sdev->device_busy == 0 && sdev->device_blocked) { | 1364 | if (sdev->device_busy == 0 && sdev->device_blocked) { |
| 1354 | /* | 1365 | /* |
| 1355 | * unblock after device_blocked iterates to zero | 1366 | * unblock after device_blocked iterates to zero |
| @@ -1363,7 +1374,7 @@ static inline int scsi_dev_queue_ready(struct request_queue *q, | |||
| 1363 | return 0; | 1374 | return 0; |
| 1364 | } | 1375 | } |
| 1365 | } | 1376 | } |
| 1366 | if (sdev->device_blocked) | 1377 | if (scsi_device_is_busy(sdev)) |
| 1367 | return 0; | 1378 | return 0; |
| 1368 | 1379 | ||
| 1369 | return 1; | 1380 | return 1; |
| @@ -1440,8 +1451,7 @@ static inline int scsi_host_queue_ready(struct request_queue *q, | |||
| 1440 | return 0; | 1451 | return 0; |
| 1441 | } | 1452 | } |
| 1442 | } | 1453 | } |
| 1443 | if ((shost->can_queue > 0 && shost->host_busy >= shost->can_queue) || | 1454 | if (scsi_host_is_busy(shost)) { |
| 1444 | shost->host_blocked || shost->host_self_blocked) { | ||
| 1445 | if (list_empty(&sdev->starved_entry)) | 1455 | if (list_empty(&sdev->starved_entry)) |
| 1446 | list_add_tail(&sdev->starved_entry, &shost->starved_list); | 1456 | list_add_tail(&sdev->starved_entry, &shost->starved_list); |
| 1447 | return 0; | 1457 | return 0; |
| @@ -1455,6 +1465,37 @@ static inline int scsi_host_queue_ready(struct request_queue *q, | |||
| 1455 | } | 1465 | } |
| 1456 | 1466 | ||
| 1457 | /* | 1467 | /* |
| 1468 | * Busy state exporting function for request stacking drivers. | ||
| 1469 | * | ||
| 1470 | * For efficiency, no lock is taken to check the busy state of | ||
| 1471 | * shost/starget/sdev, since the returned value is not guaranteed and | ||
| 1472 | * may be changed after request stacking drivers call the function, | ||
| 1473 | * regardless of taking lock or not. | ||
| 1474 | * | ||
| 1475 | * When scsi can't dispatch I/Os anymore and needs to kill I/Os | ||
| 1476 | * (e.g. !sdev), scsi needs to return 'not busy'. | ||
| 1477 | * Otherwise, request stacking drivers may hold requests forever. | ||
| 1478 | */ | ||
| 1479 | static int scsi_lld_busy(struct request_queue *q) | ||
| 1480 | { | ||
| 1481 | struct scsi_device *sdev = q->queuedata; | ||
| 1482 | struct Scsi_Host *shost; | ||
| 1483 | struct scsi_target *starget; | ||
| 1484 | |||
| 1485 | if (!sdev) | ||
| 1486 | return 0; | ||
| 1487 | |||
| 1488 | shost = sdev->host; | ||
| 1489 | starget = scsi_target(sdev); | ||
| 1490 | |||
| 1491 | if (scsi_host_in_recovery(shost) || scsi_host_is_busy(shost) || | ||
| 1492 | scsi_target_is_busy(starget) || scsi_device_is_busy(sdev)) | ||
| 1493 | return 1; | ||
| 1494 | |||
| 1495 | return 0; | ||
| 1496 | } | ||
| 1497 | |||
| 1498 | /* | ||
| 1458 | * Kill a request for a dead device | 1499 | * Kill a request for a dead device |
| 1459 | */ | 1500 | */ |
| 1460 | static void scsi_kill_request(struct request *req, struct request_queue *q) | 1501 | static void scsi_kill_request(struct request *req, struct request_queue *q) |
| @@ -1757,6 +1798,7 @@ struct request_queue *scsi_alloc_queue(struct scsi_device *sdev) | |||
| 1757 | blk_queue_prep_rq(q, scsi_prep_fn); | 1798 | blk_queue_prep_rq(q, scsi_prep_fn); |
| 1758 | blk_queue_softirq_done(q, scsi_softirq_done); | 1799 | blk_queue_softirq_done(q, scsi_softirq_done); |
| 1759 | blk_queue_rq_timed_out(q, scsi_times_out); | 1800 | blk_queue_rq_timed_out(q, scsi_times_out); |
| 1801 | blk_queue_lld_busy(q, scsi_lld_busy); | ||
| 1760 | return q; | 1802 | return q; |
| 1761 | } | 1803 | } |
| 1762 | 1804 | ||
| @@ -2105,22 +2147,21 @@ scsi_test_unit_ready(struct scsi_device *sdev, int timeout, int retries, | |||
| 2105 | do { | 2147 | do { |
| 2106 | result = scsi_execute_req(sdev, cmd, DMA_NONE, NULL, 0, sshdr, | 2148 | result = scsi_execute_req(sdev, cmd, DMA_NONE, NULL, 0, sshdr, |
| 2107 | timeout, retries); | 2149 | timeout, retries); |
| 2108 | } while ((driver_byte(result) & DRIVER_SENSE) && | 2150 | if (sdev->removable && scsi_sense_valid(sshdr) && |
| 2109 | sshdr && sshdr->sense_key == UNIT_ATTENTION && | 2151 | sshdr->sense_key == UNIT_ATTENTION) |
| 2110 | --retries); | 2152 | sdev->changed = 1; |
| 2153 | } while (scsi_sense_valid(sshdr) && | ||
| 2154 | sshdr->sense_key == UNIT_ATTENTION && --retries); | ||
| 2111 | 2155 | ||
| 2112 | if (!sshdr) | 2156 | if (!sshdr) |
| 2113 | /* could not allocate sense buffer, so can't process it */ | 2157 | /* could not allocate sense buffer, so can't process it */ |
| 2114 | return result; | 2158 | return result; |
| 2115 | 2159 | ||
| 2116 | if ((driver_byte(result) & DRIVER_SENSE) && sdev->removable) { | 2160 | if (sdev->removable && scsi_sense_valid(sshdr) && |
| 2117 | 2161 | (sshdr->sense_key == UNIT_ATTENTION || | |
| 2118 | if ((scsi_sense_valid(sshdr)) && | 2162 | sshdr->sense_key == NOT_READY)) { |
| 2119 | ((sshdr->sense_key == UNIT_ATTENTION) || | 2163 | sdev->changed = 1; |
| 2120 | (sshdr->sense_key == NOT_READY))) { | 2164 | result = 0; |
| 2121 | sdev->changed = 1; | ||
| 2122 | result = 0; | ||
| 2123 | } | ||
| 2124 | } | 2165 | } |
| 2125 | if (!sshdr_external) | 2166 | if (!sshdr_external) |
| 2126 | kfree(sshdr); | 2167 | kfree(sshdr); |
diff --git a/drivers/scsi/scsi_netlink.c b/drivers/scsi/scsi_netlink.c index b37e133de805..723fdecd91bd 100644 --- a/drivers/scsi/scsi_netlink.c +++ b/drivers/scsi/scsi_netlink.c | |||
| @@ -205,16 +205,13 @@ static struct notifier_block scsi_netlink_notifier = { | |||
| 205 | }; | 205 | }; |
| 206 | 206 | ||
| 207 | 207 | ||
| 208 | /** | 208 | /* |
| 209 | * GENERIC SCSI transport receive and event handlers | 209 | * GENERIC SCSI transport receive and event handlers |
| 210 | **/ | 210 | */ |
| 211 | 211 | ||
| 212 | /** | 212 | /** |
| 213 | * scsi_generic_msg_handler - receive message handler for GENERIC transport | 213 | * scsi_generic_msg_handler - receive message handler for GENERIC transport messages |
| 214 | * messages | ||
| 215 | * | ||
| 216 | * @skb: socket receive buffer | 214 | * @skb: socket receive buffer |
| 217 | * | ||
| 218 | **/ | 215 | **/ |
| 219 | static int | 216 | static int |
| 220 | scsi_generic_msg_handler(struct sk_buff *skb) | 217 | scsi_generic_msg_handler(struct sk_buff *skb) |
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 43f34c73df12..c9e1242eaf25 100644 --- a/drivers/scsi/sd.c +++ b/drivers/scsi/sd.c | |||
| @@ -1049,7 +1049,6 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
| 1049 | good_bytes = sd_completed_bytes(SCpnt); | 1049 | good_bytes = sd_completed_bytes(SCpnt); |
| 1050 | break; | 1050 | break; |
| 1051 | case RECOVERED_ERROR: | 1051 | case RECOVERED_ERROR: |
| 1052 | case NO_SENSE: | ||
| 1053 | /* Inform the user, but make sure that it's not treated | 1052 | /* Inform the user, but make sure that it's not treated |
| 1054 | * as a hard error. | 1053 | * as a hard error. |
| 1055 | */ | 1054 | */ |
| @@ -1058,6 +1057,15 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
| 1058 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); | 1057 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); |
| 1059 | good_bytes = scsi_bufflen(SCpnt); | 1058 | good_bytes = scsi_bufflen(SCpnt); |
| 1060 | break; | 1059 | break; |
| 1060 | case NO_SENSE: | ||
| 1061 | /* This indicates a false check condition, so ignore it. An | ||
| 1062 | * unknown amount of data was transferred so treat it as an | ||
| 1063 | * error. | ||
| 1064 | */ | ||
| 1065 | scsi_print_sense("sd", SCpnt); | ||
| 1066 | SCpnt->result = 0; | ||
| 1067 | memset(SCpnt->sense_buffer, 0, SCSI_SENSE_BUFFERSIZE); | ||
| 1068 | break; | ||
| 1061 | case ABORTED_COMMAND: | 1069 | case ABORTED_COMMAND: |
| 1062 | if (sshdr.asc == 0x10) { /* DIF: Disk detected corruption */ | 1070 | if (sshdr.asc == 0x10) { /* DIF: Disk detected corruption */ |
| 1063 | scsi_print_result(SCpnt); | 1071 | scsi_print_result(SCpnt); |
| @@ -1071,15 +1079,6 @@ static int sd_done(struct scsi_cmnd *SCpnt) | |||
| 1071 | scsi_print_sense("sd", SCpnt); | 1079 | scsi_print_sense("sd", SCpnt); |
| 1072 | good_bytes = sd_completed_bytes(SCpnt); | 1080 | good_bytes = sd_completed_bytes(SCpnt); |
| 1073 | } | 1081 | } |
| 1074 | if (!scsi_device_protection(SCpnt->device) && | ||
| 1075 | SCpnt->device->use_10_for_rw && | ||
| 1076 | (SCpnt->cmnd[0] == READ_10 || | ||
| 1077 | SCpnt->cmnd[0] == WRITE_10)) | ||
| 1078 | SCpnt->device->use_10_for_rw = 0; | ||
| 1079 | if (SCpnt->device->use_10_for_ms && | ||
| 1080 | (SCpnt->cmnd[0] == MODE_SENSE_10 || | ||
| 1081 | SCpnt->cmnd[0] == MODE_SELECT_10)) | ||
| 1082 | SCpnt->device->use_10_for_ms = 0; | ||
| 1083 | break; | 1082 | break; |
| 1084 | default: | 1083 | default: |
| 1085 | break; | 1084 | break; |
| @@ -1432,7 +1431,7 @@ got_data: | |||
| 1432 | 1431 | ||
| 1433 | { | 1432 | { |
| 1434 | char cap_str_2[10], cap_str_10[10]; | 1433 | char cap_str_2[10], cap_str_10[10]; |
| 1435 | u64 sz = sdkp->capacity << ffz(~sector_size); | 1434 | u64 sz = (u64)sdkp->capacity << ilog2(sector_size); |
| 1436 | 1435 | ||
| 1437 | string_get_size(sz, STRING_UNITS_2, cap_str_2, | 1436 | string_get_size(sz, STRING_UNITS_2, cap_str_2, |
| 1438 | sizeof(cap_str_2)); | 1437 | sizeof(cap_str_2)); |
diff --git a/drivers/scsi/sun3x_esp.c b/drivers/scsi/sun3x_esp.c index 7514b3a0390e..34a99620e5bd 100644 --- a/drivers/scsi/sun3x_esp.c +++ b/drivers/scsi/sun3x_esp.c | |||
| @@ -213,7 +213,7 @@ static int __devinit esp_sun3x_probe(struct platform_device *dev) | |||
| 213 | esp->ops = &sun3x_esp_ops; | 213 | esp->ops = &sun3x_esp_ops; |
| 214 | 214 | ||
| 215 | res = platform_get_resource(dev, IORESOURCE_MEM, 0); | 215 | res = platform_get_resource(dev, IORESOURCE_MEM, 0); |
| 216 | if (!res && !res->start) | 216 | if (!res || !res->start) |
| 217 | goto fail_unlink; | 217 | goto fail_unlink; |
| 218 | 218 | ||
| 219 | esp->regs = ioremap_nocache(res->start, 0x20); | 219 | esp->regs = ioremap_nocache(res->start, 0x20); |
| @@ -221,7 +221,7 @@ static int __devinit esp_sun3x_probe(struct platform_device *dev) | |||
| 221 | goto fail_unmap_regs; | 221 | goto fail_unmap_regs; |
| 222 | 222 | ||
| 223 | res = platform_get_resource(dev, IORESOURCE_MEM, 1); | 223 | res = platform_get_resource(dev, IORESOURCE_MEM, 1); |
| 224 | if (!res && !res->start) | 224 | if (!res || !res->start) |
| 225 | goto fail_unmap_regs; | 225 | goto fail_unmap_regs; |
| 226 | 226 | ||
| 227 | esp->dma_regs = ioremap_nocache(res->start, 0x10); | 227 | esp->dma_regs = ioremap_nocache(res->start, 0x10); |
diff --git a/drivers/staging/Kconfig b/drivers/staging/Kconfig index c4eff44c9f27..e1654f59eb70 100644 --- a/drivers/staging/Kconfig +++ b/drivers/staging/Kconfig | |||
| @@ -43,8 +43,6 @@ source "drivers/staging/echo/Kconfig" | |||
| 43 | 43 | ||
| 44 | source "drivers/staging/at76_usb/Kconfig" | 44 | source "drivers/staging/at76_usb/Kconfig" |
| 45 | 45 | ||
| 46 | source "drivers/staging/pcc-acpi/Kconfig" | ||
| 47 | |||
| 48 | source "drivers/staging/poch/Kconfig" | 46 | source "drivers/staging/poch/Kconfig" |
| 49 | 47 | ||
| 50 | endif # STAGING | 48 | endif # STAGING |
diff --git a/drivers/staging/Makefile b/drivers/staging/Makefile index 7cb8701d96d4..71c4d53760b8 100644 --- a/drivers/staging/Makefile +++ b/drivers/staging/Makefile | |||
| @@ -13,5 +13,4 @@ obj-$(CONFIG_W35UND) += winbond/ | |||
| 13 | obj-$(CONFIG_PRISM2_USB) += wlan-ng/ | 13 | obj-$(CONFIG_PRISM2_USB) += wlan-ng/ |
| 14 | obj-$(CONFIG_ECHO) += echo/ | 14 | obj-$(CONFIG_ECHO) += echo/ |
| 15 | obj-$(CONFIG_USB_ATMEL) += at76_usb/ | 15 | obj-$(CONFIG_USB_ATMEL) += at76_usb/ |
| 16 | obj-$(CONFIG_PCC_ACPI) += pcc-acpi/ | ||
| 17 | obj-$(CONFIG_POCH) += poch/ | 16 | obj-$(CONFIG_POCH) += poch/ |
diff --git a/drivers/staging/pcc-acpi/Kconfig b/drivers/staging/pcc-acpi/Kconfig deleted file mode 100644 index 6720d4086baf..000000000000 --- a/drivers/staging/pcc-acpi/Kconfig +++ /dev/null | |||
| @@ -1,11 +0,0 @@ | |||
| 1 | config PCC_ACPI | ||
| 2 | tristate "Panasonic ACPI Hotkey support" | ||
| 3 | depends on ACPI | ||
| 4 | default n | ||
| 5 | ---help--- | ||
| 6 | This driver provides support for Panasonic hotkeys through the | ||
| 7 | ACPI interface. This works for the Panasonic R1 (N variant), | ||
| 8 | R2, R3, T2, W2, and Y2 laptops. | ||
| 9 | |||
| 10 | To compile this driver as a module, choose M here. The module | ||
| 11 | will be called pcc-acpi. | ||
diff --git a/drivers/staging/pcc-acpi/Makefile b/drivers/staging/pcc-acpi/Makefile deleted file mode 100644 index f93b29edf61e..000000000000 --- a/drivers/staging/pcc-acpi/Makefile +++ /dev/null | |||
| @@ -1 +0,0 @@ | |||
| 1 | obj-$(CONFIG_PCC_ACPI) += pcc-acpi.o | ||
diff --git a/drivers/staging/pcc-acpi/TODO b/drivers/staging/pcc-acpi/TODO deleted file mode 100644 index fab240982286..000000000000 --- a/drivers/staging/pcc-acpi/TODO +++ /dev/null | |||
| @@ -1,7 +0,0 @@ | |||
| 1 | TODO: | ||
| 2 | - Lindent fixes | ||
| 3 | - checkpatch.pl fixes | ||
| 4 | - verify that the acpi interface is correct | ||
| 5 | - remove /proc dependancy if needed (not sure yet.) | ||
| 6 | |||
| 7 | Please send any patches for this driver to Greg Kroah-Hartman <greg@kroah.com> | ||
diff --git a/drivers/staging/pcc-acpi/pcc-acpi.c b/drivers/staging/pcc-acpi/pcc-acpi.c deleted file mode 100644 index 7715c31f2731..000000000000 --- a/drivers/staging/pcc-acpi/pcc-acpi.c +++ /dev/null | |||
| @@ -1,1111 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * Panasonic HotKey and lcd brightness control Extra driver | ||
| 3 | * (C) 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 4 | * (C) 2004 NTT DATA Intellilink Co. http://www.intellilink.co.jp/ | ||
| 5 | * (C) YOKOTA Hiroshi <yokota (at) netlab. is. tsukuba. ac. jp> | ||
| 6 | * (C) 2004 David Bronaugh <dbronaugh> | ||
| 7 | * | ||
| 8 | * derived from toshiba_acpi.c, Copyright (C) 2002-2004 John Belmonte | ||
| 9 | * | ||
| 10 | * This program is free software; you can redistribute it and/or modify | ||
| 11 | * it under the terms of the GNU General Public License version 2 as | ||
| 12 | * publicshed by the Free Software Foundation. | ||
| 13 | * | ||
| 14 | * This program is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * You should have received a copy of the GNU General Public License | ||
| 20 | * along with this program; if not, write to the Free Software | ||
| 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 22 | * | ||
| 23 | *--------------------------------------------------------------------------- | ||
| 24 | * | ||
| 25 | * ChangeLog: | ||
| 26 | * | ||
| 27 | * Nov.04, 2006 Hiroshi Miura <miura@da-cha.org> | ||
| 28 | * -v0.9 remove warning about section reference. | ||
| 29 | * remove acpi_os_free | ||
| 30 | * add /proc/acpi/pcc/brightness interface to | ||
| 31 | * allow HAL to access. | ||
| 32 | * merge dbronaugh's enhancement | ||
| 33 | * Aug.17, 2004 David Bronaugh (dbronaugh) | ||
| 34 | * - Added screen brightness setting interface | ||
| 35 | * Thanks to the FreeBSD crew | ||
| 36 | * (acpi_panasonic.c authors) | ||
| 37 | * for the ideas I needed to accomplish it | ||
| 38 | * | ||
| 39 | * May.29, 2006 Hiroshi Miura <miura@da-cha.org> | ||
| 40 | * -v0.8.4 follow to change keyinput structure | ||
| 41 | * thanks Fabian Yamaguchi <fabs@cs.tu-berlin.de>, | ||
| 42 | * Jacob Bower <jacob.bower@ic.ac.uk> and | ||
| 43 | * Hiroshi Yokota for providing solutions. | ||
| 44 | * | ||
| 45 | * Oct.02, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 46 | * -v0.8.2 merge code of YOKOTA Hiroshi | ||
| 47 | * <yokota@netlab.is.tsukuba.ac.jp>. | ||
| 48 | * Add sticky key mode interface. | ||
| 49 | * Refactoring acpi_pcc_generete_keyinput(). | ||
| 50 | * | ||
| 51 | * Sep.15, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 52 | * -v0.8 Generate key input event on input subsystem. | ||
| 53 | * This is based on yet another driver | ||
| 54 | * written by Ryuta Nakanishi. | ||
| 55 | * | ||
| 56 | * Sep.10, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 57 | * -v0.7 Change proc interface functions using seq_file | ||
| 58 | * facility as same as other ACPI drivers. | ||
| 59 | * | ||
| 60 | * Aug.28, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 61 | * -v0.6.4 Fix a silly error with status checking | ||
| 62 | * | ||
| 63 | * Aug.25, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 64 | * -v0.6.3 replace read_acpi_int by standard | ||
| 65 | * function acpi_evaluate_integer | ||
| 66 | * some clean up and make smart copyright notice. | ||
| 67 | * fix return value of pcc_acpi_get_key() | ||
| 68 | * fix checking return value of acpi_bus_register_driver() | ||
| 69 | * | ||
| 70 | * Aug.22, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
| 71 | * -v0.6.2 Add check on ACPI data (num_sifr) | ||
| 72 | * Coding style cleanups, better error messages/handling | ||
| 73 | * Fixed an off-by-one error in memory allocation | ||
| 74 | * | ||
| 75 | * Aug.21, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
| 76 | * -v0.6.1 Fix a silly error with status checking | ||
| 77 | * | ||
| 78 | * Aug.20, 2004 David Bronaugh <dbronaugh@linuxboxen.org> | ||
| 79 | * - v0.6 Correct brightness controls to reflect reality | ||
| 80 | * based on information gleaned by Hiroshi Miura | ||
| 81 | * and discussions with Hiroshi Miura | ||
| 82 | * | ||
| 83 | * Aug.10, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 84 | * - v0.5 support LCD brightness control | ||
| 85 | * based on the disclosed information by MEI. | ||
| 86 | * | ||
| 87 | * Jul.25, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 88 | * - v0.4 first post version | ||
| 89 | * add function to retrive SIFR | ||
| 90 | * | ||
| 91 | * Jul.24, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 92 | * - v0.3 get proper status of hotkey | ||
| 93 | * | ||
| 94 | * Jul.22, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 95 | * - v0.2 add HotKey handler | ||
| 96 | * | ||
| 97 | * Jul.17, 2004 Hiroshi Miura <miura@da-cha.org> | ||
| 98 | * - v0.1 start from toshiba_acpi driver written by John Belmonte | ||
| 99 | * | ||
| 100 | */ | ||
| 101 | |||
| 102 | #define ACPI_PCC_VERSION "0.9+hy" | ||
| 103 | |||
| 104 | #include <linux/kernel.h> | ||
| 105 | #include <linux/module.h> | ||
| 106 | #include <linux/types.h> | ||
| 107 | #include <linux/ctype.h> | ||
| 108 | #include <linux/init.h> | ||
| 109 | #include <linux/input.h> | ||
| 110 | #include <linux/proc_fs.h> | ||
| 111 | #include <linux/seq_file.h> | ||
| 112 | #include <linux/slab.h> | ||
| 113 | #include <linux/uaccess.h> | ||
| 114 | #include <acpi/acpi_bus.h> | ||
| 115 | #include <acpi/acpi_drivers.h> | ||
| 116 | |||
| 117 | |||
| 118 | /************************************************************************* | ||
| 119 | * "seq" file template definition. | ||
| 120 | */ | ||
| 121 | /* "seq" initializer */ | ||
| 122 | #define SEQ_OPEN_FS(_open_func_name_, _show_func_name_) \ | ||
| 123 | static int _open_func_name_(struct inode *inode, struct file *file) \ | ||
| 124 | { \ | ||
| 125 | return single_open(file, _show_func_name_, PDE(inode)->data); \ | ||
| 126 | } | ||
| 127 | |||
| 128 | /*------------------------------------------------------------------------- | ||
| 129 | * "seq" fops template for read-only files. | ||
| 130 | */ | ||
| 131 | #define SEQ_FILEOPS_R(_open_func_name_) \ | ||
| 132 | { \ | ||
| 133 | .open = _open_func_name_, \ | ||
| 134 | .read = seq_read, \ | ||
| 135 | .llseek = seq_lseek, \ | ||
| 136 | .release = single_release, \ | ||
| 137 | } | ||
| 138 | |||
| 139 | /*------------------------------------------------------------------------ | ||
| 140 | * "seq" fops template for read-write files. | ||
| 141 | */ | ||
| 142 | #define SEQ_FILEOPS_RW(_open_func_name_, _write_func_name_) \ | ||
| 143 | { \ | ||
| 144 | .open = _open_func_name_ , \ | ||
| 145 | .read = seq_read, \ | ||
| 146 | .write = _write_func_name_, \ | ||
| 147 | .llseek = seq_lseek, \ | ||
| 148 | .release = single_release, \ | ||
| 149 | } | ||
| 150 | |||
| 151 | /* | ||
| 152 | * "seq" file template definition ended. | ||
| 153 | *************************************************************************** | ||
| 154 | */ | ||
| 155 | #ifndef ACPI_HOTKEY_COMPONENT | ||
| 156 | #define ACPI_HOTKEY_COMPONENT 0x10000000 | ||
| 157 | #endif | ||
| 158 | |||
| 159 | #define _COMPONENT ACPI_HOTKEY_COMPONENT | ||
| 160 | ACPI_MODULE_NAME("pcc_acpi"); | ||
| 161 | |||
| 162 | MODULE_AUTHOR("Hiroshi Miura, Hiroshi Yokota"); | ||
| 163 | MODULE_DESCRIPTION("ACPI HotKey driver for Panasonic Let's Note laptops"); | ||
| 164 | MODULE_LICENSE("GPL"); | ||
| 165 | |||
| 166 | #define LOGPREFIX "pcc_acpi: " | ||
| 167 | |||
| 168 | /**************************************************** | ||
| 169 | * Define ACPI PATHs | ||
| 170 | ****************************************************/ | ||
| 171 | /* Lets note hotkeys */ | ||
| 172 | #define METHOD_HKEY_QUERY "HINF" | ||
| 173 | #define METHOD_HKEY_SQTY "SQTY" | ||
| 174 | #define METHOD_HKEY_SINF "SINF" | ||
| 175 | #define METHOD_HKEY_SSET "SSET" | ||
| 176 | #define HKEY_NOTIFY 0x80 | ||
| 177 | |||
| 178 | /* for brightness control */ | ||
| 179 | #define LCD_MAX_BRIGHTNESS 255 | ||
| 180 | /* This may be magical -- beware */ | ||
| 181 | #define LCD_BRIGHTNESS_INCREMENT 17 | ||
| 182 | /* Registers of SINF */ | ||
| 183 | #define SINF_LCD_BRIGHTNESS 4 | ||
| 184 | |||
| 185 | /******************************************************************* | ||
| 186 | * | ||
| 187 | * definitions for /proc/ interface | ||
| 188 | * | ||
| 189 | *******************************************************************/ | ||
| 190 | #define ACPI_PCC_DRIVER_NAME "pcc_acpi" | ||
| 191 | #define ACPI_PCC_DEVICE_NAME "PCCExtra" | ||
| 192 | #define ACPI_PCC_CLASS "pcc" | ||
| 193 | #define PROC_PCC ACPI_PCC_CLASS | ||
| 194 | |||
| 195 | #define ACPI_PCC_INPUT_PHYS "panasonic/hkey0" | ||
| 196 | |||
| 197 | /* This is transitional definition */ | ||
| 198 | #ifndef KEY_BATT | ||
| 199 | # define KEY_BATT 227 | ||
| 200 | #endif | ||
| 201 | |||
| 202 | #define PROC_STR_MAX_LEN 8 | ||
| 203 | |||
| 204 | #define BUS_PCC_HOTKEY BUS_I8042 /*0x1a*/ /* FIXME: BUS_I8042? */ | ||
| 205 | |||
| 206 | /* Fn+F4/F5 confricts with Shift+F1/F2 */ | ||
| 207 | /* This hack avoids key number confrict */ | ||
| 208 | #define PCC_KEYINPUT_MODE (0) | ||
| 209 | |||
| 210 | /* LCD_TYPEs: 0 = Normal, 1 = Semi-transparent | ||
| 211 | ENV_STATEs: Normal temp=0x01, High temp=0x81, N/A=0x00 | ||
| 212 | */ | ||
| 213 | enum SINF_BITS { SINF_NUM_BATTERIES = 0, | ||
| 214 | SINF_LCD_TYPE, | ||
| 215 | SINF_AC_MAX_BRIGHT, | ||
| 216 | SINF_AC_MIN_BRIGHT, | ||
| 217 | SINF_AC_CUR_BRIGHT, | ||
| 218 | /* 4 = R1 only handle SINF_AC_CUR_BRIGHT | ||
| 219 | * as SINF_CUR_BRIGHT and don't know AC state */ | ||
| 220 | SINF_DC_MAX_BRIGHT, | ||
| 221 | SINF_DC_MIN_BRIGHT, | ||
| 222 | SINF_DC_CUR_BRIGHT, | ||
| 223 | SINF_MUTE, | ||
| 224 | SINF_RESERVED, | ||
| 225 | SINF_ENV_STATE, /* 10 */ | ||
| 226 | SINF_STICKY_KEY = 0x80, | ||
| 227 | }; | ||
| 228 | |||
| 229 | static struct acpi_device_id pcc_device_ids[] = { | ||
| 230 | {"MAT0012", 0}, | ||
| 231 | {"MAT0013", 0}, | ||
| 232 | {"MAT0018", 0}, | ||
| 233 | {"MAT0019", 0}, | ||
| 234 | {"", 0}, | ||
| 235 | }; | ||
| 236 | MODULE_DEVICE_TABLE(acpi, pcc_device_ids); | ||
| 237 | |||
| 238 | |||
| 239 | static int __devinit acpi_pcc_hotkey_add(struct acpi_device *device); | ||
| 240 | static int __devexit acpi_pcc_hotkey_remove(struct acpi_device *device, | ||
| 241 | int type); | ||
| 242 | static int acpi_pcc_hotkey_resume(struct acpi_device *device); | ||
| 243 | |||
| 244 | |||
| 245 | static struct acpi_driver acpi_pcc_driver = { | ||
| 246 | .name = ACPI_PCC_DRIVER_NAME, | ||
| 247 | .class = ACPI_PCC_CLASS, | ||
| 248 | .ids = pcc_device_ids, | ||
| 249 | .ops = { | ||
| 250 | .add = acpi_pcc_hotkey_add, | ||
| 251 | .remove = __devexit_p(acpi_pcc_hotkey_remove), | ||
| 252 | #ifdef CONFIG_PM | ||
| 253 | /*.suspend = acpi_pcc_hotkey_suspend,*/ | ||
| 254 | .resume = acpi_pcc_hotkey_resume, | ||
| 255 | #endif | ||
| 256 | }, | ||
| 257 | }; | ||
| 258 | |||
| 259 | struct acpi_hotkey { | ||
| 260 | acpi_handle handle; | ||
| 261 | struct acpi_device *device; | ||
| 262 | struct proc_dir_entry *proc_dir_entry; | ||
| 263 | unsigned long num_sifr; | ||
| 264 | unsigned long status; | ||
| 265 | struct input_dev *input_dev; | ||
| 266 | int sticky_mode; | ||
| 267 | }; | ||
| 268 | |||
| 269 | struct pcc_keyinput { | ||
| 270 | struct acpi_hotkey *hotkey; | ||
| 271 | int key_mode; | ||
| 272 | }; | ||
| 273 | |||
| 274 | /* ************************************************************************* | ||
| 275 | Hotkey driver core | ||
| 276 | ************************************************************************* */ | ||
| 277 | /* ------------------------------------------------------------------------- | ||
| 278 | method access functions | ||
| 279 | ------------------------------------------------------------------------- */ | ||
| 280 | static int acpi_pcc_write_sset(struct acpi_hotkey *hotkey, int func, int val) | ||
| 281 | { | ||
| 282 | union acpi_object in_objs[] = { | ||
| 283 | { .integer.type = ACPI_TYPE_INTEGER, | ||
| 284 | .integer.value = func, }, | ||
| 285 | { .integer.type = ACPI_TYPE_INTEGER, | ||
| 286 | .integer.value = val, }, | ||
| 287 | }; | ||
| 288 | struct acpi_object_list params = { | ||
| 289 | .count = ARRAY_SIZE(in_objs), | ||
| 290 | .pointer = in_objs, | ||
| 291 | }; | ||
| 292 | acpi_status status; | ||
| 293 | |||
| 294 | ACPI_FUNCTION_TRACE("acpi_pcc_write_sset"); | ||
| 295 | |||
| 296 | status = acpi_evaluate_object(hotkey->handle, METHOD_HKEY_SSET, | ||
| 297 | ¶ms, NULL); | ||
| 298 | |||
| 299 | return_VALUE(status == AE_OK ? AE_OK : AE_ERROR); | ||
| 300 | } | ||
| 301 | |||
| 302 | static inline int acpi_pcc_get_sqty(struct acpi_device *device) | ||
| 303 | { | ||
| 304 | unsigned long s; | ||
| 305 | acpi_status status; | ||
| 306 | |||
| 307 | ACPI_FUNCTION_TRACE("acpi_pcc_get_sqty"); | ||
| 308 | |||
| 309 | status = acpi_evaluate_integer(device->handle, METHOD_HKEY_SQTY, | ||
| 310 | NULL, &s); | ||
| 311 | if (ACPI_SUCCESS(status)) { | ||
| 312 | return_VALUE(s); | ||
| 313 | } else { | ||
| 314 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 315 | "evaluation error HKEY.SQTY\n")); | ||
| 316 | return_VALUE(-EINVAL); | ||
| 317 | } | ||
| 318 | } | ||
| 319 | |||
| 320 | static int acpi_pcc_retrieve_biosdata(struct acpi_hotkey *hotkey, u32 *sinf) | ||
| 321 | { | ||
| 322 | acpi_status status; | ||
| 323 | struct acpi_buffer buffer = {ACPI_ALLOCATE_BUFFER, NULL}; | ||
| 324 | union acpi_object *hkey = NULL; | ||
| 325 | int i; | ||
| 326 | |||
| 327 | ACPI_FUNCTION_TRACE("acpi_pcc_retrieve_biosdata"); | ||
| 328 | |||
| 329 | status = acpi_evaluate_object(hotkey->handle, METHOD_HKEY_SINF, 0, | ||
| 330 | &buffer); | ||
| 331 | if (ACPI_FAILURE(status)) { | ||
| 332 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 333 | "evaluation error HKEY.SINF\n")); | ||
| 334 | status = AE_ERROR; | ||
| 335 | return_VALUE(status); | ||
| 336 | } | ||
| 337 | |||
| 338 | hkey = buffer.pointer; | ||
| 339 | if (!hkey || (hkey->type != ACPI_TYPE_PACKAGE)) { | ||
| 340 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Invalid HKEY.SINF\n")); | ||
| 341 | goto free_buffer; | ||
| 342 | } | ||
| 343 | |||
| 344 | if (hotkey->num_sifr < hkey->package.count) { | ||
| 345 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 346 | "SQTY reports bad SINF length\n")); | ||
| 347 | status = AE_ERROR; | ||
| 348 | goto free_buffer; | ||
| 349 | } | ||
| 350 | |||
| 351 | for (i = 0; i < hkey->package.count; i++) { | ||
| 352 | union acpi_object *element = &(hkey->package.elements[i]); | ||
| 353 | if (likely(element->type == ACPI_TYPE_INTEGER)) { | ||
| 354 | sinf[i] = element->integer.value; | ||
| 355 | } else { | ||
| 356 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 357 | "Invalid HKEY.SINF data\n")); | ||
| 358 | status = AE_ERROR; | ||
| 359 | break; | ||
| 360 | } | ||
| 361 | } | ||
| 362 | sinf[hkey->package.count] = -1; | ||
| 363 | |||
| 364 | free_buffer: | ||
| 365 | kfree(buffer.pointer); | ||
| 366 | return_VALUE(status == AE_OK ? AE_OK : AE_ERROR); | ||
| 367 | } | ||
| 368 | |||
| 369 | static int acpi_pcc_read_sinf_field(struct seq_file *seq, int field) | ||
| 370 | { | ||
| 371 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *) seq->private; | ||
| 372 | u32 sinf[hotkey->num_sifr + 1]; | ||
| 373 | |||
| 374 | ACPI_FUNCTION_TRACE("acpi_pcc_read_sinf_field"); | ||
| 375 | |||
| 376 | if (ACPI_SUCCESS(acpi_pcc_retrieve_biosdata(hotkey, sinf))) | ||
| 377 | seq_printf(seq, "%u\n", sinf[field]); | ||
| 378 | else | ||
| 379 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 380 | "Couldn't retrieve BIOS data\n")); | ||
| 381 | |||
| 382 | return_VALUE(AE_OK); | ||
| 383 | } | ||
| 384 | |||
| 385 | /* ------------------------------------------------------------------------- | ||
| 386 | user interface functions | ||
| 387 | ------------------------------------------------------------------------- */ | ||
| 388 | /* read methods */ | ||
| 389 | /* Sinf read methods */ | ||
| 390 | #define PCC_SINF_READ_F(_name_, FUNC) \ | ||
| 391 | static int _name_(struct seq_file *seq, void *offset) \ | ||
| 392 | { \ | ||
| 393 | return_VALUE(ACPI_SUCCESS(acpi_pcc_read_sinf_field(seq, \ | ||
| 394 | (FUNC))) \ | ||
| 395 | ? 0 : -EINVAL); \ | ||
| 396 | } | ||
| 397 | |||
| 398 | PCC_SINF_READ_F(acpi_pcc_numbatteries_show, SINF_NUM_BATTERIES); | ||
| 399 | PCC_SINF_READ_F(acpi_pcc_lcdtype_show, SINF_LCD_TYPE); | ||
| 400 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_max_show, SINF_AC_MAX_BRIGHT); | ||
| 401 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_min_show, SINF_AC_MIN_BRIGHT); | ||
| 402 | PCC_SINF_READ_F(acpi_pcc_ac_brightness_show, SINF_AC_CUR_BRIGHT); | ||
| 403 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_max_show, SINF_DC_MAX_BRIGHT); | ||
| 404 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_min_show, SINF_DC_MIN_BRIGHT); | ||
| 405 | PCC_SINF_READ_F(acpi_pcc_dc_brightness_show, SINF_DC_CUR_BRIGHT); | ||
| 406 | PCC_SINF_READ_F(acpi_pcc_brightness_show, SINF_AC_CUR_BRIGHT); | ||
| 407 | PCC_SINF_READ_F(acpi_pcc_mute_show, SINF_MUTE); | ||
| 408 | |||
| 409 | static int acpi_pcc_sticky_key_show(struct seq_file *seq, void *offset) | ||
| 410 | { | ||
| 411 | struct acpi_hotkey *hotkey = seq->private; | ||
| 412 | |||
| 413 | ACPI_FUNCTION_TRACE("acpi_pcc_sticky_key_show"); | ||
| 414 | |||
| 415 | if (!hotkey || !hotkey->device) | ||
| 416 | return_VALUE(-EINVAL); | ||
| 417 | |||
| 418 | seq_printf(seq, "%d\n", hotkey->sticky_mode); | ||
| 419 | |||
| 420 | return_VALUE(0); | ||
| 421 | } | ||
| 422 | |||
| 423 | static int acpi_pcc_keyinput_show(struct seq_file *seq, void *offset) | ||
| 424 | { | ||
| 425 | struct acpi_hotkey *hotkey = seq->private; | ||
| 426 | struct input_dev *hotk_input_dev = hotkey->input_dev; | ||
| 427 | struct pcc_keyinput *keyinput = input_get_drvdata(hotk_input_dev); | ||
| 428 | |||
| 429 | ACPI_FUNCTION_TRACE("acpi_pcc_keyinput_show"); | ||
| 430 | |||
| 431 | seq_printf(seq, "%d\n", keyinput->key_mode); | ||
| 432 | |||
| 433 | return_VALUE(0); | ||
| 434 | } | ||
| 435 | |||
| 436 | static int acpi_pcc_version_show(struct seq_file *seq, void *offset) | ||
| 437 | { | ||
| 438 | struct acpi_hotkey *hotkey = seq->private; | ||
| 439 | |||
| 440 | ACPI_FUNCTION_TRACE("acpi_pcc_version_show"); | ||
| 441 | |||
| 442 | if (!hotkey || !hotkey->device) | ||
| 443 | return_VALUE(-EINVAL); | ||
| 444 | |||
| 445 | seq_printf(seq, "%s version %s\n", ACPI_PCC_DRIVER_NAME, | ||
| 446 | ACPI_PCC_VERSION); | ||
| 447 | seq_printf(seq, "%li functions\n", hotkey->num_sifr); | ||
| 448 | |||
| 449 | return_VALUE(0); | ||
| 450 | } | ||
| 451 | |||
| 452 | /* write methods */ | ||
| 453 | static ssize_t acpi_pcc_write_single_flag(struct file *file, | ||
| 454 | const char __user *buffer, | ||
| 455 | size_t count, | ||
| 456 | int sinf_func) | ||
| 457 | { | ||
| 458 | struct seq_file *seq = file->private_data; | ||
| 459 | struct acpi_hotkey *hotkey = seq->private; | ||
| 460 | char write_string[PROC_STR_MAX_LEN]; | ||
| 461 | u32 val; | ||
| 462 | |||
| 463 | ACPI_FUNCTION_TRACE("acpi_pcc_write_single_flag"); | ||
| 464 | |||
| 465 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
| 466 | return_VALUE(-EINVAL); | ||
| 467 | |||
| 468 | if (copy_from_user(write_string, buffer, count)) | ||
| 469 | return_VALUE(-EFAULT); | ||
| 470 | |||
| 471 | write_string[count] = '\0'; | ||
| 472 | |||
| 473 | if ((sscanf(write_string, "%3i", &val) == 1) && | ||
| 474 | (val == 0 || val == 1)) | ||
| 475 | acpi_pcc_write_sset(hotkey, sinf_func, val); | ||
| 476 | |||
| 477 | return_VALUE(count); | ||
| 478 | } | ||
| 479 | |||
| 480 | static unsigned long acpi_pcc_write_brightness(struct file *file, | ||
| 481 | const char __user *buffer, | ||
| 482 | size_t count, | ||
| 483 | int min_index, int max_index, | ||
| 484 | int cur_index) | ||
| 485 | { | ||
| 486 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
| 487 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
| 488 | char write_string[PROC_STR_MAX_LEN]; | ||
| 489 | u32 bright; | ||
| 490 | u32 sinf[hotkey->num_sifr + 1]; | ||
| 491 | |||
| 492 | ACPI_FUNCTION_TRACE("acpi_pcc_write_brightness"); | ||
| 493 | |||
| 494 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
| 495 | return_VALUE(-EINVAL); | ||
| 496 | |||
| 497 | if (copy_from_user(write_string, buffer, count)) | ||
| 498 | return_VALUE(-EFAULT); | ||
| 499 | |||
| 500 | write_string[count] = '\0'; | ||
| 501 | |||
| 502 | if (ACPI_FAILURE(acpi_pcc_retrieve_biosdata(hotkey, sinf))) { | ||
| 503 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 504 | "Couldn't retrieve BIOS data\n")); | ||
| 505 | goto end; | ||
| 506 | } | ||
| 507 | |||
| 508 | if ((sscanf(write_string, "%4i", &bright) == 1) && | ||
| 509 | (bright >= sinf[min_index]) && | ||
| 510 | (bright <= sinf[max_index])) | ||
| 511 | acpi_pcc_write_sset(hotkey, cur_index, bright); | ||
| 512 | |||
| 513 | end: | ||
| 514 | return_VALUE(count); | ||
| 515 | } | ||
| 516 | |||
| 517 | static ssize_t acpi_pcc_write_ac_brightness(struct file *file, | ||
| 518 | const char __user *buffer, | ||
| 519 | size_t count, loff_t *ppos) | ||
| 520 | { | ||
| 521 | return_VALUE(acpi_pcc_write_brightness(file, buffer, count, | ||
| 522 | SINF_AC_MIN_BRIGHT, | ||
| 523 | SINF_AC_MAX_BRIGHT, | ||
| 524 | SINF_AC_CUR_BRIGHT)); | ||
| 525 | } | ||
| 526 | |||
| 527 | static ssize_t acpi_pcc_write_dc_brightness(struct file *file, | ||
| 528 | const char __user *buffer, | ||
| 529 | size_t count, loff_t *ppos) | ||
| 530 | { | ||
| 531 | return_VALUE(acpi_pcc_write_brightness(file, buffer, count, | ||
| 532 | SINF_DC_MIN_BRIGHT, | ||
| 533 | SINF_DC_MAX_BRIGHT, | ||
| 534 | SINF_DC_CUR_BRIGHT)); | ||
| 535 | } | ||
| 536 | |||
| 537 | static ssize_t acpi_pcc_write_no_brightness(struct file *file, | ||
| 538 | const char __user *buffer, | ||
| 539 | size_t count, loff_t *ppos) | ||
| 540 | { | ||
| 541 | return acpi_pcc_write_brightness(file, buffer, count, | ||
| 542 | SINF_AC_MIN_BRIGHT, | ||
| 543 | SINF_AC_MAX_BRIGHT, | ||
| 544 | SINF_AC_CUR_BRIGHT); | ||
| 545 | } | ||
| 546 | |||
| 547 | static ssize_t acpi_pcc_write_mute(struct file *file, | ||
| 548 | const char __user *buffer, | ||
| 549 | size_t count, loff_t *ppos) | ||
| 550 | { | ||
| 551 | return_VALUE(acpi_pcc_write_single_flag(file, buffer, count, | ||
| 552 | SINF_MUTE)); | ||
| 553 | } | ||
| 554 | |||
| 555 | static ssize_t acpi_pcc_write_sticky_key(struct file *file, | ||
| 556 | const char __user *buffer, | ||
| 557 | size_t count, loff_t *ppos) | ||
| 558 | { | ||
| 559 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
| 560 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
| 561 | char write_string[PROC_STR_MAX_LEN]; | ||
| 562 | int mode; | ||
| 563 | |||
| 564 | ACPI_FUNCTION_TRACE("acpi_pcc_write_sticky_key"); | ||
| 565 | |||
| 566 | if (!hotkey || (count > sizeof(write_string) - 1)) | ||
| 567 | return_VALUE(-EINVAL); | ||
| 568 | |||
| 569 | if (copy_from_user(write_string, buffer, count)) | ||
| 570 | return_VALUE(-EFAULT); | ||
| 571 | |||
| 572 | write_string[count] = '\0'; | ||
| 573 | |||
| 574 | if ((sscanf(write_string, "%3i", &mode) == 1) && | ||
| 575 | (mode == 0 || mode == 1)) { | ||
| 576 | acpi_pcc_write_sset(hotkey, SINF_STICKY_KEY, mode); | ||
| 577 | hotkey->sticky_mode = mode; | ||
| 578 | } | ||
| 579 | |||
| 580 | return_VALUE(count); | ||
| 581 | } | ||
| 582 | |||
| 583 | static ssize_t acpi_pcc_write_keyinput(struct file *file, | ||
| 584 | const char __user *buffer, | ||
| 585 | size_t count, loff_t *ppos) | ||
| 586 | { | ||
| 587 | struct seq_file *seq = (struct seq_file *)file->private_data; | ||
| 588 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *)seq->private; | ||
| 589 | struct pcc_keyinput *keyinput; | ||
| 590 | char write_string[PROC_STR_MAX_LEN]; | ||
| 591 | int key_mode; | ||
| 592 | |||
| 593 | ACPI_FUNCTION_TRACE("acpi_pcc_write_keyinput"); | ||
| 594 | |||
| 595 | if (!hotkey || (count > (sizeof(write_string) - 1))) | ||
| 596 | return_VALUE(-EINVAL); | ||
| 597 | |||
| 598 | if (copy_from_user(write_string, buffer, count)) | ||
| 599 | return_VALUE(-EFAULT); | ||
| 600 | |||
| 601 | write_string[count] = '\0'; | ||
| 602 | |||
| 603 | if ((sscanf(write_string, "%4i", &key_mode) == 1) && | ||
| 604 | (key_mode == 0 || key_mode == 1)) { | ||
| 605 | keyinput = input_get_drvdata(hotkey->input_dev); | ||
| 606 | keyinput->key_mode = key_mode; | ||
| 607 | } | ||
| 608 | |||
| 609 | return_VALUE(count); | ||
| 610 | } | ||
| 611 | |||
| 612 | /* ------------------------------------------------------------------------- | ||
| 613 | hotkey driver | ||
| 614 | ------------------------------------------------------------------------- */ | ||
| 615 | static void acpi_pcc_generete_keyinput(struct acpi_hotkey *hotkey) | ||
| 616 | { | ||
| 617 | struct input_dev *hotk_input_dev = hotkey->input_dev; | ||
| 618 | struct pcc_keyinput *keyinput = input_get_drvdata(hotk_input_dev); | ||
| 619 | int hinf = hotkey->status; | ||
| 620 | int key_code, hkey_num; | ||
| 621 | const int key_map[] = { | ||
| 622 | /* 0 */ -1, | ||
| 623 | /* 1 */ KEY_BRIGHTNESSDOWN, | ||
| 624 | /* 2 */ KEY_BRIGHTNESSUP, | ||
| 625 | /* 3 */ -1, /* vga/lcd switch event is not occur on | ||
| 626 | hotkey driver. */ | ||
| 627 | /* 4 */ KEY_MUTE, | ||
| 628 | /* 5 */ KEY_VOLUMEDOWN, | ||
| 629 | /* 6 */ KEY_VOLUMEUP, | ||
| 630 | /* 7 */ KEY_SLEEP, | ||
| 631 | /* 8 */ -1, /* Change CPU boost: do nothing */ | ||
| 632 | /* 9 */ KEY_BATT, | ||
| 633 | /* 10 */ KEY_SUSPEND, | ||
| 634 | }; | ||
| 635 | |||
| 636 | ACPI_FUNCTION_TRACE("acpi_pcc_generete_keyinput"); | ||
| 637 | |||
| 638 | if (keyinput->key_mode == 0) | ||
| 639 | return_VOID; | ||
| 640 | |||
| 641 | hkey_num = hinf & 0xf; | ||
| 642 | |||
| 643 | if ((0 > hkey_num) || | ||
| 644 | (hkey_num > ARRAY_SIZE(key_map))) { | ||
| 645 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 646 | "hotkey number out of range: %d\n", | ||
| 647 | hkey_num)); | ||
| 648 | return_VOID; | ||
| 649 | } | ||
| 650 | |||
| 651 | key_code = key_map[hkey_num]; | ||
| 652 | |||
| 653 | if (key_code != -1) { | ||
| 654 | int pushed = (hinf & 0x80) ? TRUE : FALSE; | ||
| 655 | |||
| 656 | input_report_key(hotk_input_dev, key_code, pushed); | ||
| 657 | input_sync(hotk_input_dev); | ||
| 658 | } | ||
| 659 | } | ||
| 660 | |||
| 661 | static int acpi_pcc_hotkey_get_key(struct acpi_hotkey *hotkey) | ||
| 662 | { | ||
| 663 | unsigned long result; | ||
| 664 | acpi_status status = AE_OK; | ||
| 665 | |||
| 666 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_get_key"); | ||
| 667 | |||
| 668 | status = acpi_evaluate_integer(hotkey->handle, METHOD_HKEY_QUERY, | ||
| 669 | NULL, &result); | ||
| 670 | if (likely(ACPI_SUCCESS(status))) | ||
| 671 | hotkey->status = result; | ||
| 672 | else | ||
| 673 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 674 | "error getting hotkey status\n")); | ||
| 675 | |||
| 676 | return_VALUE(status == AE_OK); | ||
| 677 | } | ||
| 678 | |||
| 679 | void acpi_pcc_hotkey_notify(acpi_handle handle, u32 event, void *data) | ||
| 680 | { | ||
| 681 | struct acpi_hotkey *hotkey = (struct acpi_hotkey *) data; | ||
| 682 | |||
| 683 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_notify"); | ||
| 684 | |||
| 685 | switch (event) { | ||
| 686 | case HKEY_NOTIFY: | ||
| 687 | if (acpi_pcc_hotkey_get_key(hotkey)) { | ||
| 688 | /* generate event like '"pcc HKEY 00000080 00000084"' | ||
| 689 | * when Fn+F4 pressed */ | ||
| 690 | acpi_bus_generate_proc_event(hotkey->device, event, | ||
| 691 | hotkey->status); | ||
| 692 | } | ||
| 693 | acpi_pcc_generete_keyinput(hotkey); | ||
| 694 | break; | ||
| 695 | default: | ||
| 696 | /* nothing to do */ | ||
| 697 | break; | ||
| 698 | } | ||
| 699 | return_VOID; | ||
| 700 | } | ||
| 701 | |||
| 702 | /* ************************************************************************* | ||
| 703 | FS Interface (/proc) | ||
| 704 | ************************************************************************* */ | ||
| 705 | /* oepn proc file fs*/ | ||
| 706 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_open_fs, acpi_pcc_dc_brightness_show); | ||
| 707 | SEQ_OPEN_FS(acpi_pcc_numbatteries_open_fs, acpi_pcc_numbatteries_show); | ||
| 708 | SEQ_OPEN_FS(acpi_pcc_lcdtype_open_fs, acpi_pcc_lcdtype_show); | ||
| 709 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_max_open_fs, | ||
| 710 | acpi_pcc_ac_brightness_max_show); | ||
| 711 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_min_open_fs, | ||
| 712 | acpi_pcc_ac_brightness_min_show); | ||
| 713 | SEQ_OPEN_FS(acpi_pcc_ac_brightness_open_fs, acpi_pcc_ac_brightness_show); | ||
| 714 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_max_open_fs, | ||
| 715 | acpi_pcc_dc_brightness_max_show); | ||
| 716 | SEQ_OPEN_FS(acpi_pcc_dc_brightness_min_open_fs, | ||
| 717 | acpi_pcc_dc_brightness_min_show); | ||
| 718 | SEQ_OPEN_FS(acpi_pcc_brightness_open_fs, acpi_pcc_brightness_show); | ||
| 719 | SEQ_OPEN_FS(acpi_pcc_mute_open_fs, acpi_pcc_mute_show); | ||
| 720 | SEQ_OPEN_FS(acpi_pcc_version_open_fs, acpi_pcc_version_show); | ||
| 721 | SEQ_OPEN_FS(acpi_pcc_keyinput_open_fs, acpi_pcc_keyinput_show); | ||
| 722 | SEQ_OPEN_FS(acpi_pcc_sticky_key_open_fs, acpi_pcc_sticky_key_show); | ||
| 723 | |||
| 724 | static struct file_operations acpi_pcc_numbatteries_fops = | ||
| 725 | SEQ_FILEOPS_R(acpi_pcc_numbatteries_open_fs); | ||
| 726 | static struct file_operations acpi_pcc_lcdtype_fops = | ||
| 727 | SEQ_FILEOPS_R(acpi_pcc_lcdtype_open_fs); | ||
| 728 | static struct file_operations acpi_pcc_mute_fops = | ||
| 729 | SEQ_FILEOPS_RW(acpi_pcc_mute_open_fs, acpi_pcc_write_mute); | ||
| 730 | static struct file_operations acpi_pcc_ac_brightness_fops = | ||
| 731 | SEQ_FILEOPS_RW(acpi_pcc_ac_brightness_open_fs, | ||
| 732 | acpi_pcc_write_ac_brightness); | ||
| 733 | static struct file_operations acpi_pcc_ac_brightness_max_fops = | ||
| 734 | SEQ_FILEOPS_R(acpi_pcc_ac_brightness_max_open_fs); | ||
| 735 | static struct file_operations acpi_pcc_ac_brightness_min_fops = | ||
| 736 | SEQ_FILEOPS_R(acpi_pcc_ac_brightness_min_open_fs); | ||
| 737 | static struct file_operations acpi_pcc_dc_brightness_fops = | ||
| 738 | SEQ_FILEOPS_RW(acpi_pcc_dc_brightness_open_fs, | ||
| 739 | acpi_pcc_write_dc_brightness); | ||
| 740 | static struct file_operations acpi_pcc_dc_brightness_max_fops = | ||
| 741 | SEQ_FILEOPS_R(acpi_pcc_dc_brightness_max_open_fs); | ||
| 742 | static struct file_operations acpi_pcc_dc_brightness_min_fops = | ||
| 743 | SEQ_FILEOPS_R(acpi_pcc_dc_brightness_min_open_fs); | ||
| 744 | static struct file_operations acpi_pcc_brightness_fops = | ||
| 745 | SEQ_FILEOPS_RW(acpi_pcc_brightness_open_fs, | ||
| 746 | acpi_pcc_write_no_brightness); | ||
| 747 | static struct file_operations acpi_pcc_sticky_key_fops = | ||
| 748 | SEQ_FILEOPS_RW(acpi_pcc_sticky_key_open_fs, acpi_pcc_write_sticky_key); | ||
| 749 | static struct file_operations acpi_pcc_keyinput_fops = | ||
| 750 | SEQ_FILEOPS_RW(acpi_pcc_keyinput_open_fs, acpi_pcc_write_keyinput); | ||
| 751 | static struct file_operations acpi_pcc_version_fops = | ||
| 752 | SEQ_FILEOPS_R(acpi_pcc_version_open_fs); | ||
| 753 | |||
| 754 | struct proc_item { | ||
| 755 | const char *name; | ||
| 756 | struct file_operations *fops; | ||
| 757 | mode_t flag; | ||
| 758 | }; | ||
| 759 | |||
| 760 | /* Note: These functions map *exactly* to the SINF/SSET functions */ | ||
| 761 | struct proc_item acpi_pcc_proc_items_sifr[] = { | ||
| 762 | { "num_batteries", &acpi_pcc_numbatteries_fops, S_IRUGO }, | ||
| 763 | { "lcd_type", &acpi_pcc_lcdtype_fops, S_IRUGO }, | ||
| 764 | { "ac_brightness_max", &acpi_pcc_ac_brightness_max_fops, S_IRUGO }, | ||
| 765 | { "ac_brightness_min", &acpi_pcc_ac_brightness_min_fops, S_IRUGO }, | ||
| 766 | { "ac_brightness", &acpi_pcc_ac_brightness_fops, | ||
| 767 | S_IFREG | S_IRUGO | S_IWUSR }, | ||
| 768 | { "dc_brightness_max", &acpi_pcc_dc_brightness_max_fops, S_IRUGO }, | ||
| 769 | { "dc_brightness_min", &acpi_pcc_dc_brightness_min_fops, S_IRUGO }, | ||
| 770 | { "dc_brightness", &acpi_pcc_dc_brightness_fops, | ||
| 771 | S_IFREG | S_IRUGO | S_IWUSR }, | ||
| 772 | { "brightness", &acpi_pcc_brightness_fops, S_IFREG | S_IRUGO | S_IWUSR}, | ||
| 773 | { "mute", &acpi_pcc_mute_fops, S_IFREG | S_IRUGO | S_IWUSR }, | ||
| 774 | { NULL, NULL, 0 }, | ||
| 775 | }; | ||
| 776 | |||
| 777 | struct proc_item acpi_pcc_proc_items[] = { | ||
| 778 | { "sticky_key", &acpi_pcc_sticky_key_fops, S_IFREG | S_IRUGO | S_IWUSR}, | ||
| 779 | { "keyinput", &acpi_pcc_keyinput_fops, S_IFREG | S_IRUGO | S_IWUSR }, | ||
| 780 | { "version", &acpi_pcc_version_fops, S_IRUGO }, | ||
| 781 | { NULL, NULL, 0 }, | ||
| 782 | }; | ||
| 783 | |||
| 784 | static int __devinit acpi_pcc_add_device(struct acpi_device *device, | ||
| 785 | struct proc_item *proc_items, | ||
| 786 | int num) | ||
| 787 | { | ||
| 788 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
| 789 | struct proc_dir_entry *proc; | ||
| 790 | struct proc_item *item; | ||
| 791 | int i; | ||
| 792 | |||
| 793 | for (item = proc_items, i = 0; item->name && i < num; ++item, ++i) { | ||
| 794 | proc = create_proc_entry(item->name, item->flag, | ||
| 795 | hotkey->proc_dir_entry); | ||
| 796 | if (likely(proc)) { | ||
| 797 | proc->proc_fops = item->fops; | ||
| 798 | proc->data = hotkey; | ||
| 799 | proc->owner = THIS_MODULE; | ||
| 800 | } else { | ||
| 801 | while (i-- > 0) { | ||
| 802 | item--; | ||
| 803 | remove_proc_entry(item->name, | ||
| 804 | hotkey->proc_dir_entry); | ||
| 805 | } | ||
| 806 | return_VALUE(-ENODEV); | ||
| 807 | } | ||
| 808 | } | ||
| 809 | return_VALUE(0); | ||
| 810 | } | ||
| 811 | |||
| 812 | static int __devinit acpi_pcc_proc_init(struct acpi_device *device) | ||
| 813 | { | ||
| 814 | struct proc_dir_entry *acpi_pcc_dir; | ||
| 815 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
| 816 | acpi_status status; | ||
| 817 | |||
| 818 | ACPI_FUNCTION_TRACE("acpi_pcc_proc_init"); | ||
| 819 | |||
| 820 | acpi_pcc_dir = proc_mkdir(PROC_PCC, acpi_root_dir); | ||
| 821 | |||
| 822 | if (unlikely(!acpi_pcc_dir)) { | ||
| 823 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 824 | "Couldn't create dir in /proc\n")); | ||
| 825 | return_VALUE(-ENODEV); | ||
| 826 | } | ||
| 827 | |||
| 828 | acpi_pcc_dir->owner = THIS_MODULE; | ||
| 829 | hotkey->proc_dir_entry = acpi_pcc_dir; | ||
| 830 | |||
| 831 | status = acpi_pcc_add_device(device, acpi_pcc_proc_items_sifr, | ||
| 832 | hotkey->num_sifr); | ||
| 833 | status |= acpi_pcc_add_device(device, acpi_pcc_proc_items, | ||
| 834 | ARRAY_SIZE(acpi_pcc_proc_items)); | ||
| 835 | if (unlikely(status)) { | ||
| 836 | remove_proc_entry(PROC_PCC, acpi_root_dir); | ||
| 837 | hotkey->proc_dir_entry = NULL; | ||
| 838 | return_VALUE(-ENODEV); | ||
| 839 | } | ||
| 840 | |||
| 841 | return_VALUE(status); | ||
| 842 | } | ||
| 843 | |||
| 844 | static void __devexit acpi_pcc_remove_device(struct acpi_device *device, | ||
| 845 | struct proc_item *proc_items, | ||
| 846 | int num) | ||
| 847 | { | ||
| 848 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
| 849 | struct proc_item *item; | ||
| 850 | int i; | ||
| 851 | |||
| 852 | for (item = proc_items, i = 0; | ||
| 853 | item->name != NULL && i < num; | ||
| 854 | ++item, ++i) { | ||
| 855 | remove_proc_entry(item->name, hotkey->proc_dir_entry); | ||
| 856 | } | ||
| 857 | |||
| 858 | return_VOID; | ||
| 859 | } | ||
| 860 | |||
| 861 | /* ************************************************************************* | ||
| 862 | Power Management | ||
| 863 | ************************************************************************* */ | ||
| 864 | #ifdef CONFIG_PM | ||
| 865 | static int acpi_pcc_hotkey_resume(struct acpi_device *device) | ||
| 866 | { | ||
| 867 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
| 868 | acpi_status status = AE_OK; | ||
| 869 | |||
| 870 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_resume"); | ||
| 871 | |||
| 872 | if (device == NULL || hotkey == NULL) | ||
| 873 | return_VALUE(-EINVAL); | ||
| 874 | |||
| 875 | if (hotkey->num_sifr != 0) { | ||
| 876 | ACPI_DEBUG_PRINT((ACPI_DB_INFO, "Sticky mode restore: %d\n", | ||
| 877 | hotkey->sticky_mode)); | ||
| 878 | |||
| 879 | status = acpi_pcc_write_sset(hotkey, SINF_STICKY_KEY, | ||
| 880 | hotkey->sticky_mode); | ||
| 881 | } | ||
| 882 | if (status != AE_OK) | ||
| 883 | return_VALUE(-EINVAL); | ||
| 884 | |||
| 885 | return_VALUE(0); | ||
| 886 | } | ||
| 887 | #endif | ||
| 888 | |||
| 889 | /* ************************************************************************* | ||
| 890 | Module init/remove | ||
| 891 | ************************************************************************* */ | ||
| 892 | /* ------------------------------------------------------------------------- | ||
| 893 | input | ||
| 894 | ------------------------------------------------------------------------- */ | ||
| 895 | static int __devinit acpi_pcc_init_input(struct acpi_hotkey *hotkey) | ||
| 896 | { | ||
| 897 | struct input_dev *hotk_input_dev; | ||
| 898 | struct pcc_keyinput *pcc_keyinput; | ||
| 899 | int error; | ||
| 900 | |||
| 901 | ACPI_FUNCTION_TRACE("acpi_pcc_init_input"); | ||
| 902 | |||
| 903 | hotk_input_dev = input_allocate_device(); | ||
| 904 | if (hotk_input_dev == NULL) { | ||
| 905 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 906 | "Couldn't allocate input device for hotkey")); | ||
| 907 | goto err_input; | ||
| 908 | } | ||
| 909 | |||
| 910 | pcc_keyinput = kcalloc(1, sizeof(struct pcc_keyinput), GFP_KERNEL); | ||
| 911 | |||
| 912 | if (pcc_keyinput == NULL) { | ||
| 913 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 914 | "Couldn't allocate mem for private data")); | ||
| 915 | goto err_pcc; | ||
| 916 | } | ||
| 917 | |||
| 918 | hotk_input_dev->evbit[0] = BIT(EV_KEY); | ||
| 919 | |||
| 920 | set_bit(KEY_BRIGHTNESSDOWN, hotk_input_dev->keybit); | ||
| 921 | set_bit(KEY_BRIGHTNESSUP, hotk_input_dev->keybit); | ||
| 922 | set_bit(KEY_MUTE, hotk_input_dev->keybit); | ||
| 923 | set_bit(KEY_VOLUMEDOWN, hotk_input_dev->keybit); | ||
| 924 | set_bit(KEY_VOLUMEUP, hotk_input_dev->keybit); | ||
| 925 | set_bit(KEY_SLEEP, hotk_input_dev->keybit); | ||
| 926 | set_bit(KEY_BATT, hotk_input_dev->keybit); | ||
| 927 | set_bit(KEY_SUSPEND, hotk_input_dev->keybit); | ||
| 928 | |||
| 929 | hotk_input_dev->name = ACPI_PCC_DRIVER_NAME; | ||
| 930 | hotk_input_dev->phys = ACPI_PCC_INPUT_PHYS; | ||
| 931 | hotk_input_dev->id.bustype = BUS_PCC_HOTKEY; | ||
| 932 | hotk_input_dev->id.vendor = 0x0001; | ||
| 933 | hotk_input_dev->id.product = 0x0001; | ||
| 934 | hotk_input_dev->id.version = 0x0100; | ||
| 935 | |||
| 936 | pcc_keyinput->key_mode = PCC_KEYINPUT_MODE; | ||
| 937 | pcc_keyinput->hotkey = hotkey; | ||
| 938 | |||
| 939 | input_set_drvdata(hotk_input_dev, pcc_keyinput); | ||
| 940 | |||
| 941 | hotkey->input_dev = hotk_input_dev; | ||
| 942 | |||
| 943 | error = input_register_device(hotk_input_dev); | ||
| 944 | |||
| 945 | if (error) | ||
| 946 | goto err_pcc; | ||
| 947 | |||
| 948 | return_VALUE(0); | ||
| 949 | |||
| 950 | err_pcc: | ||
| 951 | input_unregister_device(hotk_input_dev); | ||
| 952 | err_input: | ||
| 953 | return_VALUE(-ENOMEM); | ||
| 954 | } | ||
| 955 | |||
| 956 | static void __devexit acpi_pcc_remove_input(struct acpi_hotkey *hotkey) | ||
| 957 | { | ||
| 958 | struct input_dev *hotk_input_dev; | ||
| 959 | struct pcc_keyinput *pcc_keyinput; | ||
| 960 | |||
| 961 | ACPI_FUNCTION_TRACE("acpi_pcc_remove_input"); | ||
| 962 | |||
| 963 | if (hotkey == NULL) { | ||
| 964 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "Can't free memory")); | ||
| 965 | return_VOID; | ||
| 966 | } | ||
| 967 | |||
| 968 | hotk_input_dev = hotkey->input_dev; | ||
| 969 | pcc_keyinput = input_get_drvdata(hotk_input_dev); | ||
| 970 | |||
| 971 | input_unregister_device(hotk_input_dev); | ||
| 972 | |||
| 973 | kfree(pcc_keyinput); | ||
| 974 | } | ||
| 975 | |||
| 976 | /* ------------------------------------------------------------------------- | ||
| 977 | ACPI | ||
| 978 | ------------------------------------------------------------------------- */ | ||
| 979 | static int __devinit acpi_pcc_hotkey_add(struct acpi_device *device) | ||
| 980 | { | ||
| 981 | acpi_status status = AE_OK; | ||
| 982 | struct acpi_hotkey *hotkey = NULL; | ||
| 983 | int sifr_status, num_sifr, result; | ||
| 984 | |||
| 985 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_add"); | ||
| 986 | |||
| 987 | if (device == NULL) | ||
| 988 | return_VALUE(-EINVAL); | ||
| 989 | |||
| 990 | sifr_status = acpi_pcc_get_sqty(device); | ||
| 991 | |||
| 992 | if (sifr_status > 255) { | ||
| 993 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, "num_sifr too large")); | ||
| 994 | return_VALUE(-ENODEV); | ||
| 995 | } | ||
| 996 | |||
| 997 | if (sifr_status < 0) { | ||
| 998 | ACPI_DEBUG_PRINT((ACPI_DB_INFO, "not support SQTY")); | ||
| 999 | num_sifr = 0; | ||
| 1000 | } else { | ||
| 1001 | num_sifr = sifr_status; | ||
| 1002 | } | ||
| 1003 | |||
| 1004 | hotkey = kcalloc(1, sizeof(struct acpi_hotkey), GFP_KERNEL); | ||
| 1005 | if (hotkey == NULL) { | ||
| 1006 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 1007 | "Couldn't allocate mem for hotkey")); | ||
| 1008 | return_VALUE(-ENOMEM); | ||
| 1009 | } | ||
| 1010 | |||
| 1011 | hotkey->device = device; | ||
| 1012 | hotkey->handle = device->handle; | ||
| 1013 | hotkey->num_sifr = num_sifr; | ||
| 1014 | acpi_driver_data(device) = hotkey; | ||
| 1015 | strcpy(acpi_device_name(device), ACPI_PCC_DEVICE_NAME); | ||
| 1016 | strcpy(acpi_device_class(device), ACPI_PCC_CLASS); | ||
| 1017 | |||
| 1018 | status = acpi_install_notify_handler(hotkey->handle, | ||
| 1019 | ACPI_DEVICE_NOTIFY, | ||
| 1020 | acpi_pcc_hotkey_notify, | ||
| 1021 | hotkey); | ||
| 1022 | |||
| 1023 | if (ACPI_FAILURE(status)) { | ||
| 1024 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 1025 | "Error installing notify handler\n")); | ||
| 1026 | kfree(hotkey); | ||
| 1027 | return_VALUE(-ENODEV); | ||
| 1028 | } | ||
| 1029 | |||
| 1030 | result = acpi_pcc_init_input(hotkey); | ||
| 1031 | if (result != 0) { | ||
| 1032 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 1033 | "Error installing keyinput handler\n")); | ||
| 1034 | kfree(hotkey); | ||
| 1035 | return_VALUE(result); | ||
| 1036 | } | ||
| 1037 | |||
| 1038 | return_VALUE(acpi_pcc_proc_init(device)); | ||
| 1039 | } | ||
| 1040 | |||
| 1041 | static int __devexit acpi_pcc_hotkey_remove(struct acpi_device *device, | ||
| 1042 | int type) | ||
| 1043 | { | ||
| 1044 | acpi_status status = AE_OK; | ||
| 1045 | struct acpi_hotkey *hotkey = acpi_driver_data(device); | ||
| 1046 | |||
| 1047 | ACPI_FUNCTION_TRACE("acpi_pcc_hotkey_remove"); | ||
| 1048 | |||
| 1049 | if (!device || !hotkey) | ||
| 1050 | return_VALUE(-EINVAL); | ||
| 1051 | |||
| 1052 | if (hotkey->proc_dir_entry) { | ||
| 1053 | acpi_pcc_remove_device(device, acpi_pcc_proc_items_sifr, | ||
| 1054 | hotkey->num_sifr); | ||
| 1055 | acpi_pcc_remove_device(device, acpi_pcc_proc_items, | ||
| 1056 | ARRAY_SIZE(acpi_pcc_proc_items)); | ||
| 1057 | remove_proc_entry(PROC_PCC, acpi_root_dir); | ||
| 1058 | } | ||
| 1059 | |||
| 1060 | status = acpi_remove_notify_handler(hotkey->handle, | ||
| 1061 | ACPI_DEVICE_NOTIFY, acpi_pcc_hotkey_notify); | ||
| 1062 | |||
| 1063 | if (ACPI_FAILURE(status)) { | ||
| 1064 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 1065 | "Error removing notify handler\n")); | ||
| 1066 | } | ||
| 1067 | |||
| 1068 | acpi_pcc_remove_input(hotkey); | ||
| 1069 | kfree(hotkey); | ||
| 1070 | return_VALUE(status == AE_OK); | ||
| 1071 | } | ||
| 1072 | |||
| 1073 | /* ********************************************************************* | ||
| 1074 | Module entry point | ||
| 1075 | ********************************************************************* */ | ||
| 1076 | static int __init acpi_pcc_init(void) | ||
| 1077 | { | ||
| 1078 | int result; | ||
| 1079 | |||
| 1080 | ACPI_FUNCTION_TRACE("acpi_pcc_init"); | ||
| 1081 | |||
| 1082 | printk(KERN_INFO LOGPREFIX "loading...\n"); | ||
| 1083 | |||
| 1084 | if (acpi_disabled) { | ||
| 1085 | printk(KERN_INFO LOGPREFIX "ACPI disabled.\n"); | ||
| 1086 | return_VALUE(-ENODEV); | ||
| 1087 | } | ||
| 1088 | |||
| 1089 | result = acpi_bus_register_driver(&acpi_pcc_driver); | ||
| 1090 | if (result < 0) { | ||
| 1091 | ACPI_DEBUG_PRINT((ACPI_DB_ERROR, | ||
| 1092 | "Error registering hotkey driver\n")); | ||
| 1093 | return_VALUE(-ENODEV); | ||
| 1094 | } | ||
| 1095 | |||
| 1096 | return_VALUE(result); | ||
| 1097 | } | ||
| 1098 | |||
| 1099 | static void __exit acpi_pcc_exit(void) | ||
| 1100 | { | ||
| 1101 | ACPI_FUNCTION_TRACE("acpi_pcc_exit"); | ||
| 1102 | |||
| 1103 | printk(KERN_INFO LOGPREFIX "unloading...\n"); | ||
| 1104 | |||
| 1105 | acpi_bus_unregister_driver(&acpi_pcc_driver); | ||
| 1106 | |||
| 1107 | return_VOID; | ||
| 1108 | } | ||
| 1109 | |||
| 1110 | module_init(acpi_pcc_init); | ||
| 1111 | module_exit(acpi_pcc_exit); | ||
diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig index c72a13562954..4a4dd9adc328 100644 --- a/drivers/video/backlight/Kconfig +++ b/drivers/video/backlight/Kconfig | |||
| @@ -75,6 +75,15 @@ config LCD_PLATFORM | |||
| 75 | This driver provides a platform-device registered LCD power | 75 | This driver provides a platform-device registered LCD power |
| 76 | control interface. | 76 | control interface. |
| 77 | 77 | ||
| 78 | config LCD_TOSA | ||
| 79 | tristate "Sharp SL-6000 LCD Driver" | ||
| 80 | depends on LCD_CLASS_DEVICE && SPI | ||
| 81 | depends on MACH_TOSA | ||
| 82 | default n | ||
| 83 | help | ||
| 84 | If you have an Sharp SL-6000 Zaurus say Y to enable a driver | ||
| 85 | for its LCD. | ||
| 86 | |||
| 78 | # | 87 | # |
| 79 | # Backlight | 88 | # Backlight |
| 80 | # | 89 | # |
| @@ -115,7 +124,7 @@ config BACKLIGHT_ATMEL_PWM | |||
| 115 | called atmel-pwm-bl. | 124 | called atmel-pwm-bl. |
| 116 | 125 | ||
| 117 | config BACKLIGHT_CORGI | 126 | config BACKLIGHT_CORGI |
| 118 | tristate "Generic (aka Sharp Corgi) Backlight Driver" | 127 | tristate "Generic (aka Sharp Corgi) Backlight Driver (DEPRECATED)" |
| 119 | depends on BACKLIGHT_CLASS_DEVICE | 128 | depends on BACKLIGHT_CLASS_DEVICE |
| 120 | default n | 129 | default n |
| 121 | help | 130 | help |
| @@ -123,6 +132,9 @@ config BACKLIGHT_CORGI | |||
| 123 | known as the Corgi backlight driver. If you have a Sharp Zaurus | 132 | known as the Corgi backlight driver. If you have a Sharp Zaurus |
| 124 | SL-C7xx, SL-Cxx00 or SL-6000x say y. Most users can say n. | 133 | SL-C7xx, SL-Cxx00 or SL-6000x say y. Most users can say n. |
| 125 | 134 | ||
| 135 | Note: this driver is marked as deprecated, try enable SPI and | ||
| 136 | use the new corgi_lcd driver with integrated backlight control | ||
| 137 | |||
| 126 | config BACKLIGHT_LOCOMO | 138 | config BACKLIGHT_LOCOMO |
| 127 | tristate "Sharp LOCOMO LCD/Backlight Driver" | 139 | tristate "Sharp LOCOMO LCD/Backlight Driver" |
| 128 | depends on BACKLIGHT_CLASS_DEVICE && SHARP_LOCOMO | 140 | depends on BACKLIGHT_CLASS_DEVICE && SHARP_LOCOMO |
| @@ -171,6 +183,13 @@ config BACKLIGHT_PWM | |||
| 171 | If you have a LCD backlight adjustable by PWM, say Y to enable | 183 | If you have a LCD backlight adjustable by PWM, say Y to enable |
| 172 | this driver. | 184 | this driver. |
| 173 | 185 | ||
| 186 | config BACKLIGHT_DA903X | ||
| 187 | tristate "Backlight Driver for DA9030/DA9034 using WLED" | ||
| 188 | depends on BACKLIGHT_CLASS_DEVICE && PMIC_DA903X | ||
| 189 | help | ||
| 190 | If you have a LCD backlight connected to the WLED output of DA9030 | ||
| 191 | or DA9034 WLED output, say Y here to enable this driver. | ||
| 192 | |||
| 174 | config BACKLIGHT_MBP_NVIDIA | 193 | config BACKLIGHT_MBP_NVIDIA |
| 175 | tristate "MacBook Pro Nvidia Backlight Driver" | 194 | tristate "MacBook Pro Nvidia Backlight Driver" |
| 176 | depends on BACKLIGHT_CLASS_DEVICE && X86 | 195 | depends on BACKLIGHT_CLASS_DEVICE && X86 |
| @@ -179,3 +198,19 @@ config BACKLIGHT_MBP_NVIDIA | |||
| 179 | If you have an Apple Macbook Pro with Nvidia graphics hardware say Y | 198 | If you have an Apple Macbook Pro with Nvidia graphics hardware say Y |
| 180 | to enable a driver for its backlight | 199 | to enable a driver for its backlight |
| 181 | 200 | ||
| 201 | config BACKLIGHT_TOSA | ||
| 202 | tristate "Sharp SL-6000 Backlight Driver" | ||
| 203 | depends on BACKLIGHT_CLASS_DEVICE && I2C | ||
| 204 | depends on MACH_TOSA && LCD_TOSA | ||
| 205 | default n | ||
| 206 | help | ||
| 207 | If you have an Sharp SL-6000 Zaurus say Y to enable a driver | ||
| 208 | for its backlight | ||
| 209 | |||
| 210 | config BACKLIGHT_SAHARA | ||
| 211 | tristate "Tabletkiosk Sahara Touch-iT Backlight Driver" | ||
| 212 | depends on BACKLIGHT_CLASS_DEVICE && X86 | ||
| 213 | default n | ||
| 214 | help | ||
| 215 | If you have a Tabletkiosk Sahara Touch-iT, say y to enable the | ||
| 216 | backlight driver. | ||
diff --git a/drivers/video/backlight/Makefile b/drivers/video/backlight/Makefile index 3ec551eb472c..103427de6703 100644 --- a/drivers/video/backlight/Makefile +++ b/drivers/video/backlight/Makefile | |||
| @@ -7,6 +7,7 @@ obj-$(CONFIG_LCD_ILI9320) += ili9320.o | |||
| 7 | obj-$(CONFIG_LCD_PLATFORM) += platform_lcd.o | 7 | obj-$(CONFIG_LCD_PLATFORM) += platform_lcd.o |
| 8 | obj-$(CONFIG_LCD_VGG2432A4) += vgg2432a4.o | 8 | obj-$(CONFIG_LCD_VGG2432A4) += vgg2432a4.o |
| 9 | obj-$(CONFIG_LCD_TDO24M) += tdo24m.o | 9 | obj-$(CONFIG_LCD_TDO24M) += tdo24m.o |
| 10 | obj-$(CONFIG_LCD_TOSA) += tosa_lcd.o | ||
| 10 | 11 | ||
| 11 | obj-$(CONFIG_BACKLIGHT_CLASS_DEVICE) += backlight.o | 12 | obj-$(CONFIG_BACKLIGHT_CLASS_DEVICE) += backlight.o |
| 12 | obj-$(CONFIG_BACKLIGHT_ATMEL_PWM) += atmel-pwm-bl.o | 13 | obj-$(CONFIG_BACKLIGHT_ATMEL_PWM) += atmel-pwm-bl.o |
| @@ -17,5 +18,8 @@ obj-$(CONFIG_BACKLIGHT_OMAP1) += omap1_bl.o | |||
| 17 | obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o | 18 | obj-$(CONFIG_BACKLIGHT_PROGEAR) += progear_bl.o |
| 18 | obj-$(CONFIG_BACKLIGHT_CARILLO_RANCH) += cr_bllcd.o | 19 | obj-$(CONFIG_BACKLIGHT_CARILLO_RANCH) += cr_bllcd.o |
| 19 | obj-$(CONFIG_BACKLIGHT_PWM) += pwm_bl.o | 20 | obj-$(CONFIG_BACKLIGHT_PWM) += pwm_bl.o |
| 21 | obj-$(CONFIG_BACKLIGHT_DA903X) += da903x.o | ||
| 20 | obj-$(CONFIG_BACKLIGHT_MBP_NVIDIA) += mbp_nvidia_bl.o | 22 | obj-$(CONFIG_BACKLIGHT_MBP_NVIDIA) += mbp_nvidia_bl.o |
| 23 | obj-$(CONFIG_BACKLIGHT_TOSA) += tosa_bl.o | ||
| 24 | obj-$(CONFIG_BACKLIGHT_SAHARA) += kb3886_bl.o | ||
| 21 | 25 | ||
diff --git a/drivers/video/backlight/da903x.c b/drivers/video/backlight/da903x.c new file mode 100644 index 000000000000..242c38250166 --- /dev/null +++ b/drivers/video/backlight/da903x.c | |||
| @@ -0,0 +1,201 @@ | |||
| 1 | /* | ||
| 2 | * Backlight driver for Dialog Semiconductor DA9030/DA9034 | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Compulab, Ltd. | ||
| 5 | * Mike Rapoport <mike@compulab.co.il> | ||
| 6 | * | ||
| 7 | * Copyright (C) 2006-2008 Marvell International Ltd. | ||
| 8 | * Eric Miao <eric.miao@marvell.com> | ||
| 9 | * | ||
| 10 | * This program is free software; you can redistribute it and/or modify | ||
| 11 | * it under the terms of the GNU General Public License version 2 as | ||
| 12 | * published by the Free Software Foundation. | ||
| 13 | */ | ||
| 14 | |||
| 15 | #include <linux/kernel.h> | ||
| 16 | #include <linux/init.h> | ||
| 17 | #include <linux/platform_device.h> | ||
| 18 | #include <linux/fb.h> | ||
| 19 | #include <linux/backlight.h> | ||
| 20 | #include <linux/mfd/da903x.h> | ||
| 21 | |||
| 22 | #define DA9030_WLED_CONTROL 0x25 | ||
| 23 | #define DA9030_WLED_CP_EN (1 << 6) | ||
| 24 | #define DA9030_WLED_TRIM(x) ((x) & 0x7) | ||
| 25 | |||
| 26 | #define DA9034_WLED_CONTROL1 0x3C | ||
| 27 | #define DA9034_WLED_CONTROL2 0x3D | ||
| 28 | |||
| 29 | #define DA9034_WLED_BOOST_EN (1 << 5) | ||
| 30 | |||
| 31 | #define DA9030_MAX_BRIGHTNESS 7 | ||
| 32 | #define DA9034_MAX_BRIGHTNESS 0x7f | ||
| 33 | |||
| 34 | struct da903x_backlight_data { | ||
| 35 | struct device *da903x_dev; | ||
| 36 | int id; | ||
| 37 | int current_brightness; | ||
| 38 | }; | ||
| 39 | |||
| 40 | static int da903x_backlight_set(struct backlight_device *bl, int brightness) | ||
| 41 | { | ||
| 42 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
| 43 | struct device *dev = data->da903x_dev; | ||
| 44 | uint8_t val; | ||
| 45 | int ret = 0; | ||
| 46 | |||
| 47 | switch (data->id) { | ||
| 48 | case DA9034_ID_WLED: | ||
| 49 | ret = da903x_update(dev, DA9034_WLED_CONTROL1, | ||
| 50 | brightness, 0x7f); | ||
| 51 | if (ret) | ||
| 52 | return ret; | ||
| 53 | |||
| 54 | if (data->current_brightness && brightness == 0) | ||
| 55 | ret = da903x_clr_bits(dev, | ||
| 56 | DA9034_WLED_CONTROL2, | ||
| 57 | DA9034_WLED_BOOST_EN); | ||
| 58 | |||
| 59 | if (data->current_brightness == 0 && brightness) | ||
| 60 | ret = da903x_set_bits(dev, | ||
| 61 | DA9034_WLED_CONTROL2, | ||
| 62 | DA9034_WLED_BOOST_EN); | ||
| 63 | break; | ||
| 64 | case DA9030_ID_WLED: | ||
| 65 | val = DA9030_WLED_TRIM(brightness); | ||
| 66 | val |= brightness ? DA9030_WLED_CP_EN : 0; | ||
| 67 | ret = da903x_write(dev, DA9030_WLED_CONTROL, val); | ||
| 68 | break; | ||
| 69 | } | ||
| 70 | |||
| 71 | if (ret) | ||
| 72 | return ret; | ||
| 73 | |||
| 74 | data->current_brightness = brightness; | ||
| 75 | return 0; | ||
| 76 | } | ||
| 77 | |||
| 78 | static int da903x_backlight_update_status(struct backlight_device *bl) | ||
| 79 | { | ||
| 80 | int brightness = bl->props.brightness; | ||
| 81 | |||
| 82 | if (bl->props.power != FB_BLANK_UNBLANK) | ||
| 83 | brightness = 0; | ||
| 84 | |||
| 85 | if (bl->props.fb_blank != FB_BLANK_UNBLANK) | ||
| 86 | brightness = 0; | ||
| 87 | |||
| 88 | return da903x_backlight_set(bl, brightness); | ||
| 89 | } | ||
| 90 | |||
| 91 | static int da903x_backlight_get_brightness(struct backlight_device *bl) | ||
| 92 | { | ||
| 93 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
| 94 | return data->current_brightness; | ||
| 95 | } | ||
| 96 | |||
| 97 | static struct backlight_ops da903x_backlight_ops = { | ||
| 98 | .update_status = da903x_backlight_update_status, | ||
| 99 | .get_brightness = da903x_backlight_get_brightness, | ||
| 100 | }; | ||
| 101 | |||
| 102 | static int da903x_backlight_probe(struct platform_device *pdev) | ||
| 103 | { | ||
| 104 | struct da903x_backlight_data *data; | ||
| 105 | struct backlight_device *bl; | ||
| 106 | int max_brightness; | ||
| 107 | |||
| 108 | data = kzalloc(sizeof(*data), GFP_KERNEL); | ||
| 109 | if (data == NULL) | ||
| 110 | return -ENOMEM; | ||
| 111 | |||
| 112 | switch (pdev->id) { | ||
| 113 | case DA9030_ID_WLED: | ||
| 114 | max_brightness = DA9030_MAX_BRIGHTNESS; | ||
| 115 | break; | ||
| 116 | case DA9034_ID_WLED: | ||
| 117 | max_brightness = DA9034_MAX_BRIGHTNESS; | ||
| 118 | break; | ||
| 119 | default: | ||
| 120 | dev_err(&pdev->dev, "invalid backlight device ID(%d)\n", | ||
| 121 | pdev->id); | ||
| 122 | return -EINVAL; | ||
| 123 | } | ||
| 124 | |||
| 125 | data->id = pdev->id; | ||
| 126 | data->da903x_dev = pdev->dev.parent; | ||
| 127 | data->current_brightness = 0; | ||
| 128 | |||
| 129 | bl = backlight_device_register(pdev->name, data->da903x_dev, | ||
| 130 | data, &da903x_backlight_ops); | ||
| 131 | if (IS_ERR(bl)) { | ||
| 132 | dev_err(&pdev->dev, "failed to register backlight\n"); | ||
| 133 | return PTR_ERR(bl); | ||
| 134 | } | ||
| 135 | |||
| 136 | bl->props.max_brightness = max_brightness; | ||
| 137 | bl->props.brightness = max_brightness; | ||
| 138 | |||
| 139 | platform_set_drvdata(pdev, bl); | ||
| 140 | backlight_update_status(bl); | ||
| 141 | return 0; | ||
| 142 | } | ||
| 143 | |||
| 144 | static int da903x_backlight_remove(struct platform_device *pdev) | ||
| 145 | { | ||
| 146 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
| 147 | struct da903x_backlight_data *data = bl_get_data(bl); | ||
| 148 | |||
| 149 | backlight_device_unregister(bl); | ||
| 150 | kfree(data); | ||
| 151 | return 0; | ||
| 152 | } | ||
| 153 | |||
| 154 | #ifdef CONFIG_PM | ||
| 155 | static int da903x_backlight_suspend(struct platform_device *pdev, | ||
| 156 | pm_message_t state) | ||
| 157 | { | ||
| 158 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
| 159 | return da903x_backlight_set(bl, 0); | ||
| 160 | } | ||
| 161 | |||
| 162 | static int da903x_backlight_resume(struct platform_device *pdev) | ||
| 163 | { | ||
| 164 | struct backlight_device *bl = platform_get_drvdata(pdev); | ||
| 165 | |||
| 166 | backlight_update_status(bl); | ||
| 167 | return 0; | ||
| 168 | } | ||
| 169 | #else | ||
| 170 | #define da903x_backlight_suspend NULL | ||
| 171 | #define da903x_backlight_resume NULL | ||
| 172 | #endif | ||
| 173 | |||
| 174 | static struct platform_driver da903x_backlight_driver = { | ||
| 175 | .driver = { | ||
| 176 | .name = "da903x-backlight", | ||
| 177 | .owner = THIS_MODULE, | ||
| 178 | }, | ||
| 179 | .probe = da903x_backlight_probe, | ||
| 180 | .remove = da903x_backlight_remove, | ||
| 181 | .suspend = da903x_backlight_suspend, | ||
| 182 | .resume = da903x_backlight_resume, | ||
| 183 | }; | ||
| 184 | |||
| 185 | static int __init da903x_backlight_init(void) | ||
| 186 | { | ||
| 187 | return platform_driver_register(&da903x_backlight_driver); | ||
| 188 | } | ||
| 189 | module_init(da903x_backlight_init); | ||
| 190 | |||
| 191 | static void __exit da903x_backlight_exit(void) | ||
| 192 | { | ||
| 193 | platform_driver_unregister(&da903x_backlight_driver); | ||
| 194 | } | ||
| 195 | module_exit(da903x_backlight_exit); | ||
| 196 | |||
| 197 | MODULE_DESCRIPTION("Backlight Driver for Dialog Semiconductor DA9030/DA9034"); | ||
| 198 | MODULE_AUTHOR("Eric Miao <eric.miao@marvell.com>" | ||
| 199 | "Mike Rapoport <mike@compulab.co.il>"); | ||
| 200 | MODULE_LICENSE("GPL"); | ||
| 201 | MODULE_ALIAS("platform:da903x-backlight"); | ||
diff --git a/drivers/video/backlight/kb3886_bl.c b/drivers/video/backlight/kb3886_bl.c new file mode 100644 index 000000000000..a38fda1742dd --- /dev/null +++ b/drivers/video/backlight/kb3886_bl.c | |||
| @@ -0,0 +1,204 @@ | |||
| 1 | /* | ||
| 2 | * Backlight Driver for the KB3886 Backlight | ||
| 3 | * | ||
| 4 | * Copyright (c) 2007-2008 Claudio Nieder | ||
| 5 | * | ||
| 6 | * Based on corgi_bl.c by Richard Purdie and kb3886 driver by Robert Woerle | ||
| 7 | * | ||
| 8 | * This program is free software; you can redistribute it and/or modify | ||
| 9 | * it under the terms of the GNU General Public License version 2 as | ||
| 10 | * published by the Free Software Foundation. | ||
| 11 | * | ||
| 12 | */ | ||
| 13 | |||
| 14 | #include <linux/module.h> | ||
| 15 | #include <linux/kernel.h> | ||
| 16 | #include <linux/init.h> | ||
| 17 | #include <linux/platform_device.h> | ||
| 18 | #include <linux/mutex.h> | ||
| 19 | #include <linux/fb.h> | ||
| 20 | #include <linux/backlight.h> | ||
| 21 | #include <linux/delay.h> | ||
| 22 | #include <linux/dmi.h> | ||
| 23 | |||
| 24 | #define KB3886_PARENT 0x64 | ||
| 25 | #define KB3886_IO 0x60 | ||
| 26 | #define KB3886_ADC_DAC_PWM 0xC4 | ||
| 27 | #define KB3886_PWM0_WRITE 0x81 | ||
| 28 | #define KB3886_PWM0_READ 0x41 | ||
| 29 | |||
| 30 | static DEFINE_MUTEX(bl_mutex); | ||
| 31 | |||
| 32 | static void kb3886_bl_set_intensity(int intensity) | ||
| 33 | { | ||
| 34 | mutex_lock(&bl_mutex); | ||
| 35 | intensity = intensity&0xff; | ||
| 36 | outb(KB3886_ADC_DAC_PWM, KB3886_PARENT); | ||
| 37 | msleep(10); | ||
| 38 | outb(KB3886_PWM0_WRITE, KB3886_IO); | ||
| 39 | msleep(10); | ||
| 40 | outb(intensity, KB3886_IO); | ||
| 41 | mutex_unlock(&bl_mutex); | ||
| 42 | } | ||
| 43 | |||
| 44 | struct kb3886bl_machinfo { | ||
| 45 | int max_intensity; | ||
| 46 | int default_intensity; | ||
| 47 | int limit_mask; | ||
| 48 | void (*set_bl_intensity)(int intensity); | ||
| 49 | }; | ||
| 50 | |||
| 51 | static struct kb3886bl_machinfo kb3886_bl_machinfo = { | ||
| 52 | .max_intensity = 0xff, | ||
| 53 | .default_intensity = 0xa0, | ||
| 54 | .limit_mask = 0x7f, | ||
| 55 | .set_bl_intensity = kb3886_bl_set_intensity, | ||
| 56 | }; | ||
| 57 | |||
| 58 | static struct platform_device kb3886bl_device = { | ||
| 59 | .name = "kb3886-bl", | ||
| 60 | .dev = { | ||
| 61 | .platform_data = &kb3886_bl_machinfo, | ||
| 62 | }, | ||
| 63 | .id = -1, | ||
| 64 | }; | ||
| 65 | |||
| 66 | static struct platform_device *devices[] __initdata = { | ||
| 67 | &kb3886bl_device, | ||
| 68 | }; | ||
| 69 | |||
| 70 | /* | ||
| 71 | * Back to driver | ||
| 72 | */ | ||
| 73 | |||
| 74 | static int kb3886bl_intensity; | ||
| 75 | static struct backlight_device *kb3886_backlight_device; | ||
| 76 | static struct kb3886bl_machinfo *bl_machinfo; | ||
| 77 | |||
| 78 | static unsigned long kb3886bl_flags; | ||
| 79 | #define KB3886BL_SUSPENDED 0x01 | ||
| 80 | |||
| 81 | static struct dmi_system_id __initdata kb3886bl_device_table[] = { | ||
| 82 | { | ||
| 83 | .ident = "Sahara Touch-iT", | ||
| 84 | .matches = { | ||
| 85 | DMI_MATCH(DMI_SYS_VENDOR, "SDV"), | ||
| 86 | DMI_MATCH(DMI_PRODUCT_NAME, "iTouch T201"), | ||
| 87 | }, | ||
| 88 | }, | ||
| 89 | { } | ||
| 90 | }; | ||
| 91 | |||
| 92 | static int kb3886bl_send_intensity(struct backlight_device *bd) | ||
| 93 | { | ||
| 94 | int intensity = bd->props.brightness; | ||
| 95 | |||
| 96 | if (bd->props.power != FB_BLANK_UNBLANK) | ||
| 97 | intensity = 0; | ||
| 98 | if (bd->props.fb_blank != FB_BLANK_UNBLANK) | ||
| 99 | intensity = 0; | ||
| 100 | if (kb3886bl_flags & KB3886BL_SUSPENDED) | ||
| 101 | intensity = 0; | ||
| 102 | |||
| 103 | bl_machinfo->set_bl_intensity(intensity); | ||
| 104 | |||
| 105 | kb3886bl_intensity = intensity; | ||
| 106 | return 0; | ||
| 107 | } | ||
| 108 | |||
| 109 | #ifdef CONFIG_PM | ||
| 110 | static int kb3886bl_suspend(struct platform_device *pdev, pm_message_t state) | ||
| 111 | { | ||
| 112 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
| 113 | |||
| 114 | kb3886bl_flags |= KB3886BL_SUSPENDED; | ||
| 115 | backlight_update_status(bd); | ||
| 116 | return 0; | ||
| 117 | } | ||
| 118 | |||
| 119 | static int kb3886bl_resume(struct platform_device *pdev) | ||
| 120 | { | ||
| 121 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
| 122 | |||
| 123 | kb3886bl_flags &= ~KB3886BL_SUSPENDED; | ||
| 124 | backlight_update_status(bd); | ||
| 125 | return 0; | ||
| 126 | } | ||
| 127 | #else | ||
| 128 | #define kb3886bl_suspend NULL | ||
| 129 | #define kb3886bl_resume NULL | ||
| 130 | #endif | ||
| 131 | |||
| 132 | static int kb3886bl_get_intensity(struct backlight_device *bd) | ||
| 133 | { | ||
| 134 | return kb3886bl_intensity; | ||
| 135 | } | ||
| 136 | |||
| 137 | static struct backlight_ops kb3886bl_ops = { | ||
| 138 | .get_brightness = kb3886bl_get_intensity, | ||
| 139 | .update_status = kb3886bl_send_intensity, | ||
| 140 | }; | ||
| 141 | |||
| 142 | static int kb3886bl_probe(struct platform_device *pdev) | ||
| 143 | { | ||
| 144 | struct kb3886bl_machinfo *machinfo = pdev->dev.platform_data; | ||
| 145 | |||
| 146 | bl_machinfo = machinfo; | ||
| 147 | if (!machinfo->limit_mask) | ||
| 148 | machinfo->limit_mask = -1; | ||
| 149 | |||
| 150 | kb3886_backlight_device = backlight_device_register("kb3886-bl", | ||
| 151 | &pdev->dev, NULL, &kb3886bl_ops); | ||
| 152 | if (IS_ERR(kb3886_backlight_device)) | ||
| 153 | return PTR_ERR(kb3886_backlight_device); | ||
| 154 | |||
| 155 | platform_set_drvdata(pdev, kb3886_backlight_device); | ||
| 156 | |||
| 157 | kb3886_backlight_device->props.max_brightness = machinfo->max_intensity; | ||
| 158 | kb3886_backlight_device->props.power = FB_BLANK_UNBLANK; | ||
| 159 | kb3886_backlight_device->props.brightness = machinfo->default_intensity; | ||
| 160 | backlight_update_status(kb3886_backlight_device); | ||
| 161 | |||
| 162 | return 0; | ||
| 163 | } | ||
| 164 | |||
| 165 | static int kb3886bl_remove(struct platform_device *pdev) | ||
| 166 | { | ||
| 167 | struct backlight_device *bd = platform_get_drvdata(pdev); | ||
| 168 | |||
| 169 | backlight_device_unregister(bd); | ||
| 170 | |||
| 171 | return 0; | ||
| 172 | } | ||
| 173 | |||
| 174 | static struct platform_driver kb3886bl_driver = { | ||
| 175 | .probe = kb3886bl_probe, | ||
| 176 | .remove = kb3886bl_remove, | ||
| 177 | .suspend = kb3886bl_suspend, | ||
| 178 | .resume = kb3886bl_resume, | ||
| 179 | .driver = { | ||
| 180 | .name = "kb3886-bl", | ||
| 181 | }, | ||
| 182 | }; | ||
| 183 | |||
| 184 | static int __init kb3886_init(void) | ||
| 185 | { | ||
| 186 | if (!dmi_check_system(kb3886bl_device_table)) | ||
| 187 | return -ENODEV; | ||
| 188 | |||
| 189 | platform_add_devices(devices, ARRAY_SIZE(devices)); | ||
| 190 | return platform_driver_register(&kb3886bl_driver); | ||
| 191 | } | ||
| 192 | |||
| 193 | static void __exit kb3886_exit(void) | ||
| 194 | { | ||
| 195 | platform_driver_unregister(&kb3886bl_driver); | ||
| 196 | } | ||
| 197 | |||
| 198 | module_init(kb3886_init); | ||
| 199 | module_exit(kb3886_exit); | ||
| 200 | |||
| 201 | MODULE_AUTHOR("Claudio Nieder <private@claudio.ch>"); | ||
| 202 | MODULE_DESCRIPTION("Tabletkiosk Sahara Touch-iT Backlight Driver"); | ||
| 203 | MODULE_LICENSE("GPL"); | ||
| 204 | MODULE_ALIAS("dmi:*:svnSDV:pniTouchT201:*"); | ||
diff --git a/drivers/video/backlight/tosa_bl.c b/drivers/video/backlight/tosa_bl.c new file mode 100644 index 000000000000..43edbada12d1 --- /dev/null +++ b/drivers/video/backlight/tosa_bl.c | |||
| @@ -0,0 +1,198 @@ | |||
| 1 | /* | ||
| 2 | * LCD / Backlight control code for Sharp SL-6000x (tosa) | ||
| 3 | * | ||
| 4 | * Copyright (c) 2005 Dirk Opfer | ||
| 5 | * Copyright (c) 2007,2008 Dmitry Baryshkov | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License version 2 as | ||
| 9 | * published by the Free Software Foundation. | ||
| 10 | * | ||
| 11 | */ | ||
| 12 | |||
| 13 | #include <linux/kernel.h> | ||
| 14 | #include <linux/module.h> | ||
| 15 | #include <linux/device.h> | ||
| 16 | #include <linux/spi/spi.h> | ||
| 17 | #include <linux/i2c.h> | ||
| 18 | #include <linux/gpio.h> | ||
| 19 | #include <linux/fb.h> | ||
| 20 | #include <linux/backlight.h> | ||
| 21 | |||
| 22 | #include <asm/mach/sharpsl_param.h> | ||
| 23 | |||
| 24 | #include <mach/tosa.h> | ||
| 25 | |||
| 26 | #define COMADJ_DEFAULT 97 | ||
| 27 | |||
| 28 | #define DAC_CH1 0 | ||
| 29 | #define DAC_CH2 1 | ||
| 30 | |||
| 31 | struct tosa_bl_data { | ||
| 32 | struct i2c_client *i2c; | ||
| 33 | struct backlight_device *bl; | ||
| 34 | |||
| 35 | int comadj; | ||
| 36 | }; | ||
| 37 | |||
| 38 | static void tosa_bl_set_backlight(struct tosa_bl_data *data, int brightness) | ||
| 39 | { | ||
| 40 | struct spi_device *spi = data->i2c->dev.platform_data; | ||
| 41 | |||
| 42 | i2c_smbus_write_byte_data(data->i2c, DAC_CH1, data->comadj); | ||
| 43 | |||
| 44 | /* SetBacklightDuty */ | ||
| 45 | i2c_smbus_write_byte_data(data->i2c, DAC_CH2, (u8)(brightness & 0xff)); | ||
| 46 | |||
| 47 | /* SetBacklightVR */ | ||
| 48 | gpio_set_value(TOSA_GPIO_BL_C20MA, brightness & 0x100); | ||
| 49 | |||
| 50 | tosa_bl_enable(spi, brightness); | ||
| 51 | } | ||
| 52 | |||
| 53 | static int tosa_bl_update_status(struct backlight_device *dev) | ||
| 54 | { | ||
| 55 | struct backlight_properties *props = &dev->props; | ||
| 56 | struct tosa_bl_data *data = dev_get_drvdata(&dev->dev); | ||
| 57 | int power = max(props->power, props->fb_blank); | ||
| 58 | int brightness = props->brightness; | ||
| 59 | |||
| 60 | if (power) | ||
| 61 | brightness = 0; | ||
| 62 | |||
| 63 | tosa_bl_set_backlight(data, brightness); | ||
| 64 | |||
| 65 | return 0; | ||
| 66 | } | ||
| 67 | |||
| 68 | static int tosa_bl_get_brightness(struct backlight_device *dev) | ||
| 69 | { | ||
| 70 | struct backlight_properties *props = &dev->props; | ||
| 71 | |||
| 72 | return props->brightness; | ||
| 73 | } | ||
| 74 | |||
| 75 | static struct backlight_ops bl_ops = { | ||
| 76 | .get_brightness = tosa_bl_get_brightness, | ||
| 77 | .update_status = tosa_bl_update_status, | ||
| 78 | }; | ||
| 79 | |||
| 80 | static int __devinit tosa_bl_probe(struct i2c_client *client, | ||
| 81 | const struct i2c_device_id *id) | ||
| 82 | { | ||
| 83 | struct tosa_bl_data *data = kzalloc(sizeof(struct tosa_bl_data), GFP_KERNEL); | ||
| 84 | int ret = 0; | ||
| 85 | if (!data) | ||
| 86 | return -ENOMEM; | ||
| 87 | |||
| 88 | data->comadj = sharpsl_param.comadj == -1 ? COMADJ_DEFAULT : sharpsl_param.comadj; | ||
| 89 | |||
| 90 | ret = gpio_request(TOSA_GPIO_BL_C20MA, "backlight"); | ||
| 91 | if (ret) { | ||
| 92 | dev_dbg(&data->bl->dev, "Unable to request gpio!\n"); | ||
| 93 | goto err_gpio_bl; | ||
| 94 | } | ||
| 95 | ret = gpio_direction_output(TOSA_GPIO_BL_C20MA, 0); | ||
| 96 | if (ret) | ||
| 97 | goto err_gpio_dir; | ||
| 98 | |||
| 99 | i2c_set_clientdata(client, data); | ||
| 100 | data->i2c = client; | ||
| 101 | |||
| 102 | data->bl = backlight_device_register("tosa-bl", &client->dev, | ||
| 103 | data, &bl_ops); | ||
| 104 | if (IS_ERR(data->bl)) { | ||
| 105 | ret = PTR_ERR(data->bl); | ||
| 106 | goto err_reg; | ||
| 107 | } | ||
| 108 | |||
| 109 | data->bl->props.brightness = 69; | ||
| 110 | data->bl->props.max_brightness = 512 - 1; | ||
| 111 | data->bl->props.power = FB_BLANK_UNBLANK; | ||
| 112 | |||
| 113 | backlight_update_status(data->bl); | ||
| 114 | |||
| 115 | return 0; | ||
| 116 | |||
| 117 | err_reg: | ||
| 118 | data->bl = NULL; | ||
| 119 | i2c_set_clientdata(client, NULL); | ||
| 120 | err_gpio_dir: | ||
| 121 | gpio_free(TOSA_GPIO_BL_C20MA); | ||
| 122 | err_gpio_bl: | ||
| 123 | kfree(data); | ||
| 124 | return ret; | ||
| 125 | } | ||
| 126 | |||
| 127 | static int __devexit tosa_bl_remove(struct i2c_client *client) | ||
| 128 | { | ||
| 129 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
| 130 | |||
| 131 | backlight_device_unregister(data->bl); | ||
| 132 | data->bl = NULL; | ||
| 133 | i2c_set_clientdata(client, NULL); | ||
| 134 | |||
| 135 | gpio_free(TOSA_GPIO_BL_C20MA); | ||
| 136 | |||
| 137 | kfree(data); | ||
| 138 | |||
| 139 | return 0; | ||
| 140 | } | ||
| 141 | |||
| 142 | #ifdef CONFIG_PM | ||
| 143 | static int tosa_bl_suspend(struct i2c_client *client, pm_message_t pm) | ||
| 144 | { | ||
| 145 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
| 146 | |||
| 147 | tosa_bl_set_backlight(data, 0); | ||
| 148 | |||
| 149 | return 0; | ||
| 150 | } | ||
| 151 | |||
| 152 | static int tosa_bl_resume(struct i2c_client *client) | ||
| 153 | { | ||
| 154 | struct tosa_bl_data *data = i2c_get_clientdata(client); | ||
| 155 | |||
| 156 | backlight_update_status(data->bl); | ||
| 157 | return 0; | ||
| 158 | } | ||
| 159 | #else | ||
| 160 | #define tosa_bl_suspend NULL | ||
| 161 | #define tosa_bl_resume NULL | ||
| 162 | #endif | ||
| 163 | |||
| 164 | static const struct i2c_device_id tosa_bl_id[] = { | ||
| 165 | { "tosa-bl", 0 }, | ||
| 166 | { }, | ||
| 167 | }; | ||
| 168 | |||
| 169 | |||
| 170 | static struct i2c_driver tosa_bl_driver = { | ||
| 171 | .driver = { | ||
| 172 | .name = "tosa-bl", | ||
| 173 | .owner = THIS_MODULE, | ||
| 174 | }, | ||
| 175 | .probe = tosa_bl_probe, | ||
| 176 | .remove = __devexit_p(tosa_bl_remove), | ||
| 177 | .suspend = tosa_bl_suspend, | ||
| 178 | .resume = tosa_bl_resume, | ||
| 179 | .id_table = tosa_bl_id, | ||
| 180 | }; | ||
| 181 | |||
| 182 | static int __init tosa_bl_init(void) | ||
| 183 | { | ||
| 184 | return i2c_add_driver(&tosa_bl_driver); | ||
| 185 | } | ||
| 186 | |||
| 187 | static void __exit tosa_bl_exit(void) | ||
| 188 | { | ||
| 189 | i2c_del_driver(&tosa_bl_driver); | ||
| 190 | } | ||
| 191 | |||
| 192 | module_init(tosa_bl_init); | ||
| 193 | module_exit(tosa_bl_exit); | ||
| 194 | |||
| 195 | MODULE_AUTHOR("Dmitry Baryshkov"); | ||
| 196 | MODULE_LICENSE("GPL v2"); | ||
| 197 | MODULE_DESCRIPTION("LCD/Backlight control for Sharp SL-6000 PDA"); | ||
| 198 | |||
diff --git a/drivers/video/backlight/tosa_lcd.c b/drivers/video/backlight/tosa_lcd.c new file mode 100644 index 000000000000..57a26649f1a5 --- /dev/null +++ b/drivers/video/backlight/tosa_lcd.c | |||
| @@ -0,0 +1,280 @@ | |||
| 1 | /* | ||
| 2 | * LCD / Backlight control code for Sharp SL-6000x (tosa) | ||
| 3 | * | ||
| 4 | * Copyright (c) 2005 Dirk Opfer | ||
| 5 | * Copyright (c) 2007,2008 Dmitry Baryshkov | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License version 2 as | ||
| 9 | * published by the Free Software Foundation. | ||
| 10 | * | ||
| 11 | */ | ||
| 12 | |||
| 13 | #include <linux/kernel.h> | ||
| 14 | #include <linux/module.h> | ||
| 15 | #include <linux/device.h> | ||
| 16 | #include <linux/spi/spi.h> | ||
| 17 | #include <linux/i2c.h> | ||
| 18 | #include <linux/gpio.h> | ||
| 19 | #include <linux/delay.h> | ||
| 20 | #include <linux/lcd.h> | ||
| 21 | #include <linux/fb.h> | ||
| 22 | |||
| 23 | #include <asm/mach/sharpsl_param.h> | ||
| 24 | |||
| 25 | #include <mach/tosa.h> | ||
| 26 | |||
| 27 | #define POWER_IS_ON(pwr) ((pwr) <= FB_BLANK_NORMAL) | ||
| 28 | |||
| 29 | #define TG_REG0_VQV 0x0001 | ||
| 30 | #define TG_REG0_COLOR 0x0002 | ||
| 31 | #define TG_REG0_UD 0x0004 | ||
| 32 | #define TG_REG0_LR 0x0008 | ||
| 33 | |||
| 34 | #define DAC_BASE 0x4e | ||
| 35 | |||
| 36 | struct tosa_lcd_data { | ||
| 37 | struct spi_device *spi; | ||
| 38 | struct lcd_device *lcd; | ||
| 39 | struct i2c_client *i2c; | ||
| 40 | |||
| 41 | int lcd_power; | ||
| 42 | }; | ||
| 43 | |||
| 44 | static int tosa_tg_send(struct spi_device *spi, int adrs, uint8_t data) | ||
| 45 | { | ||
| 46 | u8 buf[1]; | ||
| 47 | struct spi_message msg; | ||
| 48 | struct spi_transfer xfer = { | ||
| 49 | .len = 1, | ||
| 50 | .cs_change = 1, | ||
| 51 | .tx_buf = buf, | ||
| 52 | }; | ||
| 53 | |||
| 54 | buf[0] = ((adrs & 0x07) << 5) | (data & 0x1f); | ||
| 55 | spi_message_init(&msg); | ||
| 56 | spi_message_add_tail(&xfer, &msg); | ||
| 57 | |||
| 58 | return spi_sync(spi, &msg); | ||
| 59 | } | ||
| 60 | |||
| 61 | int tosa_bl_enable(struct spi_device *spi, int enable) | ||
| 62 | { | ||
| 63 | /* bl_enable GP04=1 otherwise GP04=0*/ | ||
| 64 | return tosa_tg_send(spi, TG_GPODR2, enable? 0x01 : 0x00); | ||
| 65 | } | ||
| 66 | EXPORT_SYMBOL(tosa_bl_enable); | ||
| 67 | |||
| 68 | static void tosa_lcd_tg_init(struct tosa_lcd_data *data) | ||
| 69 | { | ||
| 70 | /* TG on */ | ||
| 71 | gpio_set_value(TOSA_GPIO_TG_ON, 0); | ||
| 72 | |||
| 73 | mdelay(60); | ||
| 74 | |||
| 75 | /* delayed 0clk TCTL signal for VGA */ | ||
| 76 | tosa_tg_send(data->spi, TG_TPOSCTL, 0x00); | ||
| 77 | /* GPOS0=powercontrol, GPOS1=GPIO, GPOS2=TCTL */ | ||
| 78 | tosa_tg_send(data->spi, TG_GPOSR, 0x02); | ||
| 79 | } | ||
| 80 | |||
| 81 | static void tosa_lcd_tg_on(struct tosa_lcd_data *data) | ||
| 82 | { | ||
| 83 | struct spi_device *spi = data->spi; | ||
| 84 | const int value = TG_REG0_COLOR | TG_REG0_UD | TG_REG0_LR; | ||
| 85 | tosa_tg_send(spi, TG_PNLCTL, value | TG_REG0_VQV); /* this depends on mode */ | ||
| 86 | |||
| 87 | /* TG LCD pannel power up */ | ||
| 88 | tosa_tg_send(spi, TG_PINICTL,0x4); | ||
| 89 | mdelay(50); | ||
| 90 | |||
| 91 | /* TG LCD GVSS */ | ||
| 92 | tosa_tg_send(spi, TG_PINICTL,0x0); | ||
| 93 | |||
| 94 | if (!data->i2c) { | ||
| 95 | /* after the pannel is powered up the first time, we can access the i2c bus */ | ||
| 96 | /* so probe for the DAC */ | ||
| 97 | struct i2c_adapter *adap = i2c_get_adapter(0); | ||
| 98 | struct i2c_board_info info = { | ||
| 99 | .type = "tosa-bl", | ||
| 100 | .addr = DAC_BASE, | ||
| 101 | .platform_data = data->spi, | ||
| 102 | }; | ||
| 103 | data->i2c = i2c_new_device(adap, &info); | ||
| 104 | } | ||
| 105 | } | ||
| 106 | |||
| 107 | static void tosa_lcd_tg_off(struct tosa_lcd_data *data) | ||
| 108 | { | ||
| 109 | struct spi_device *spi = data->spi; | ||
| 110 | |||
| 111 | /* TG LCD VHSA off */ | ||
| 112 | tosa_tg_send(spi, TG_PINICTL,0x4); | ||
| 113 | mdelay(50); | ||
| 114 | |||
| 115 | /* TG LCD signal off */ | ||
| 116 | tosa_tg_send(spi, TG_PINICTL,0x6); | ||
| 117 | mdelay(50); | ||
| 118 | |||
| 119 | /* TG Off */ | ||
| 120 | gpio_set_value(TOSA_GPIO_TG_ON, 1); | ||
| 121 | mdelay(100); | ||
| 122 | } | ||
| 123 | |||
| 124 | int tosa_lcd_set_power(struct lcd_device *lcd, int power) | ||
| 125 | { | ||
| 126 | struct tosa_lcd_data *data = lcd_get_data(lcd); | ||
| 127 | |||
| 128 | if (POWER_IS_ON(power) && !POWER_IS_ON(data->lcd_power)) | ||
| 129 | tosa_lcd_tg_on(data); | ||
| 130 | |||
| 131 | if (!POWER_IS_ON(power) && POWER_IS_ON(data->lcd_power)) | ||
| 132 | tosa_lcd_tg_off(data); | ||
| 133 | |||
| 134 | data->lcd_power = power; | ||
| 135 | return 0; | ||
| 136 | } | ||
| 137 | |||
| 138 | static int tosa_lcd_get_power(struct lcd_device *lcd) | ||
| 139 | { | ||
| 140 | struct tosa_lcd_data *data = lcd_get_data(lcd); | ||
| 141 | |||
| 142 | return data->lcd_power; | ||
| 143 | } | ||
| 144 | |||
| 145 | static struct lcd_ops tosa_lcd_ops = { | ||
| 146 | .set_power = tosa_lcd_set_power, | ||
| 147 | .get_power = tosa_lcd_get_power, | ||
| 148 | }; | ||
| 149 | |||
| 150 | static int __devinit tosa_lcd_probe(struct spi_device *spi) | ||
| 151 | { | ||
| 152 | int ret; | ||
| 153 | struct tosa_lcd_data *data; | ||
| 154 | |||
| 155 | data = kzalloc(sizeof(struct tosa_lcd_data), GFP_KERNEL); | ||
| 156 | if (!data) | ||
| 157 | return -ENOMEM; | ||
| 158 | |||
| 159 | /* | ||
| 160 | * bits_per_word cannot be configured in platform data | ||
| 161 | */ | ||
| 162 | spi->bits_per_word = 8; | ||
| 163 | |||
| 164 | ret = spi_setup(spi); | ||
| 165 | if (ret < 0) | ||
| 166 | goto err_spi; | ||
| 167 | |||
| 168 | data->spi = spi; | ||
| 169 | dev_set_drvdata(&spi->dev, data); | ||
| 170 | |||
| 171 | ret = gpio_request(TOSA_GPIO_TG_ON, "tg #pwr"); | ||
| 172 | if (ret < 0) | ||
| 173 | goto err_gpio_tg; | ||
| 174 | |||
| 175 | mdelay(60); | ||
| 176 | |||
| 177 | ret = gpio_direction_output(TOSA_GPIO_TG_ON, 0); | ||
| 178 | if (ret < 0) | ||
| 179 | goto err_gpio_dir; | ||
| 180 | |||
| 181 | mdelay(60); | ||
| 182 | tosa_lcd_tg_init(data); | ||
| 183 | |||
| 184 | tosa_lcd_tg_on(data); | ||
| 185 | |||
| 186 | data->lcd = lcd_device_register("tosa-lcd", &spi->dev, data, | ||
| 187 | &tosa_lcd_ops); | ||
| 188 | |||
| 189 | if (IS_ERR(data->lcd)) { | ||
| 190 | ret = PTR_ERR(data->lcd); | ||
| 191 | data->lcd = NULL; | ||
| 192 | goto err_register; | ||
| 193 | } | ||
| 194 | |||
| 195 | return 0; | ||
| 196 | |||
| 197 | err_register: | ||
| 198 | tosa_lcd_tg_off(data); | ||
| 199 | err_gpio_dir: | ||
| 200 | gpio_free(TOSA_GPIO_TG_ON); | ||
| 201 | err_gpio_tg: | ||
| 202 | dev_set_drvdata(&spi->dev, NULL); | ||
| 203 | err_spi: | ||
| 204 | kfree(data); | ||
| 205 | return ret; | ||
| 206 | } | ||
| 207 | |||
| 208 | static int __devexit tosa_lcd_remove(struct spi_device *spi) | ||
| 209 | { | ||
| 210 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
| 211 | |||
| 212 | lcd_device_unregister(data->lcd); | ||
| 213 | |||
| 214 | if (data->i2c) | ||
| 215 | i2c_unregister_device(data->i2c); | ||
| 216 | |||
| 217 | tosa_lcd_tg_off(data); | ||
| 218 | |||
| 219 | gpio_free(TOSA_GPIO_TG_ON); | ||
| 220 | dev_set_drvdata(&spi->dev, NULL); | ||
| 221 | kfree(data); | ||
| 222 | |||
| 223 | return 0; | ||
| 224 | } | ||
| 225 | |||
| 226 | #ifdef CONFIG_PM | ||
| 227 | static int tosa_lcd_suspend(struct spi_device *spi, pm_message_t state) | ||
| 228 | { | ||
| 229 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
| 230 | |||
| 231 | tosa_lcd_tg_off(data); | ||
| 232 | |||
| 233 | return 0; | ||
| 234 | } | ||
| 235 | |||
| 236 | static int tosa_lcd_resume(struct spi_device *spi) | ||
| 237 | { | ||
| 238 | struct tosa_lcd_data *data = dev_get_drvdata(&spi->dev); | ||
| 239 | |||
| 240 | tosa_lcd_tg_init(data); | ||
| 241 | if (POWER_IS_ON(data->lcd_power)) | ||
| 242 | tosa_lcd_tg_on(data); | ||
| 243 | else | ||
| 244 | tosa_lcd_tg_off(data); | ||
| 245 | |||
| 246 | return 0; | ||
| 247 | } | ||
| 248 | #else | ||
| 249 | #define tosa_lcd_suspend NULL | ||
| 250 | #define tosa_lcd_reume NULL | ||
| 251 | #endif | ||
| 252 | |||
| 253 | static struct spi_driver tosa_lcd_driver = { | ||
| 254 | .driver = { | ||
| 255 | .name = "tosa-lcd", | ||
| 256 | .owner = THIS_MODULE, | ||
| 257 | }, | ||
| 258 | .probe = tosa_lcd_probe, | ||
| 259 | .remove = __devexit_p(tosa_lcd_remove), | ||
| 260 | .suspend = tosa_lcd_suspend, | ||
| 261 | .resume = tosa_lcd_resume, | ||
| 262 | }; | ||
| 263 | |||
| 264 | static int __init tosa_lcd_init(void) | ||
| 265 | { | ||
| 266 | return spi_register_driver(&tosa_lcd_driver); | ||
| 267 | } | ||
| 268 | |||
| 269 | static void __exit tosa_lcd_exit(void) | ||
| 270 | { | ||
| 271 | spi_unregister_driver(&tosa_lcd_driver); | ||
| 272 | } | ||
| 273 | |||
| 274 | module_init(tosa_lcd_init); | ||
| 275 | module_exit(tosa_lcd_exit); | ||
| 276 | |||
| 277 | MODULE_AUTHOR("Dmitry Baryshkov"); | ||
| 278 | MODULE_LICENSE("GPL v2"); | ||
| 279 | MODULE_DESCRIPTION("LCD/Backlight control for Sharp SL-6000 PDA"); | ||
| 280 | |||
diff --git a/fs/cifs/CHANGES b/fs/cifs/CHANGES index 06e521a945c3..8f528ea24c48 100644 --- a/fs/cifs/CHANGES +++ b/fs/cifs/CHANGES | |||
| @@ -1,3 +1,11 @@ | |||
| 1 | Version 1.55 | ||
| 2 | ------------ | ||
| 3 | Various fixes to make delete of open files behavior more predictable | ||
| 4 | (when delete of an open file fails we mark the file as "delete-on-close" | ||
| 5 | in a way that more servers accept, but only if we can first rename the | ||
| 6 | file to a temporary name). Add experimental support for more safely | ||
| 7 | handling fcntl(F_SETLEASE). | ||
| 8 | |||
| 1 | Version 1.54 | 9 | Version 1.54 |
| 2 | ------------ | 10 | ------------ |
| 3 | Fix premature write failure on congested networks (we would give up | 11 | Fix premature write failure on congested networks (we would give up |
| @@ -13,6 +21,7 @@ on dns_upcall (resolving DFS referralls). Fix plain text password | |||
| 13 | authentication (requires setting SecurityFlags to 0x30030 to enable | 21 | authentication (requires setting SecurityFlags to 0x30030 to enable |
| 14 | lanman and plain text though). Fix writes to be at correct offset when | 22 | lanman and plain text though). Fix writes to be at correct offset when |
| 15 | file is open with O_APPEND and file is on a directio (forcediretio) mount. | 23 | file is open with O_APPEND and file is on a directio (forcediretio) mount. |
| 24 | Fix bug in rewinding readdir directory searches. Add nodfs mount option. | ||
| 16 | 25 | ||
| 17 | Version 1.53 | 26 | Version 1.53 |
| 18 | ------------ | 27 | ------------ |
diff --git a/fs/cifs/README b/fs/cifs/README index bd2343d4c6a6..a439dc1739b3 100644 --- a/fs/cifs/README +++ b/fs/cifs/README | |||
| @@ -463,6 +463,9 @@ A partial list of the supported mount options follows: | |||
| 463 | with cifs style mandatory byte range locks (and most | 463 | with cifs style mandatory byte range locks (and most |
| 464 | cifs servers do not yet support requesting advisory | 464 | cifs servers do not yet support requesting advisory |
| 465 | byte range locks). | 465 | byte range locks). |
| 466 | nodfs Disable DFS (global name space support) even if the | ||
| 467 | server claims to support it. This can help work around | ||
| 468 | a problem with parsing of DFS paths with Samba 3.0.24 server. | ||
| 466 | remount remount the share (often used to change from ro to rw mounts | 469 | remount remount the share (often used to change from ro to rw mounts |
| 467 | or vice versa) | 470 | or vice versa) |
| 468 | cifsacl Report mode bits (e.g. on stat) based on the Windows ACL for | 471 | cifsacl Report mode bits (e.g. on stat) based on the Windows ACL for |
| @@ -488,6 +491,19 @@ A partial list of the supported mount options follows: | |||
| 488 | Note that this differs from the sign mount option in that it | 491 | Note that this differs from the sign mount option in that it |
| 489 | causes encryption of data sent over this mounted share but other | 492 | causes encryption of data sent over this mounted share but other |
| 490 | shares mounted to the same server are unaffected. | 493 | shares mounted to the same server are unaffected. |
| 494 | locallease This option is rarely needed. Fcntl F_SETLEASE is | ||
| 495 | used by some applications such as Samba and NFSv4 server to | ||
| 496 | check to see whether a file is cacheable. CIFS has no way | ||
| 497 | to explicitly request a lease, but can check whether a file | ||
| 498 | is cacheable (oplocked). Unfortunately, even if a file | ||
| 499 | is not oplocked, it could still be cacheable (ie cifs client | ||
| 500 | could grant fcntl leases if no other local processes are using | ||
| 501 | the file) for cases for example such as when the server does not | ||
| 502 | support oplocks and the user is sure that the only updates to | ||
| 503 | the file will be from this client. Specifying this mount option | ||
| 504 | will allow the cifs client to check for leases (only) locally | ||
| 505 | for files which are not oplocked instead of denying leases | ||
| 506 | in that case. (EXPERIMENTAL) | ||
| 491 | sec Security mode. Allowed values are: | 507 | sec Security mode. Allowed values are: |
| 492 | none attempt to connection as a null user (no name) | 508 | none attempt to connection as a null user (no name) |
| 493 | krb5 Use Kerberos version 5 authentication | 509 | krb5 Use Kerberos version 5 authentication |
| @@ -638,6 +654,9 @@ requires enabling CONFIG_CIFS_EXPERIMENTAL | |||
| 638 | cifsacl support needed to retrieve approximated mode bits based on | 654 | cifsacl support needed to retrieve approximated mode bits based on |
| 639 | the contents on the CIFS ACL. | 655 | the contents on the CIFS ACL. |
| 640 | 656 | ||
| 657 | lease support: cifs will check the oplock state before calling into | ||
| 658 | the vfs to see if we can grant a lease on a file. | ||
| 659 | |||
| 641 | DNOTIFY fcntl: needed for support of directory change | 660 | DNOTIFY fcntl: needed for support of directory change |
| 642 | notification and perhaps later for file leases) | 661 | notification and perhaps later for file leases) |
| 643 | 662 | ||
diff --git a/fs/cifs/cifsfs.c b/fs/cifs/cifsfs.c index 84cc011a16e4..ac5915d61dca 100644 --- a/fs/cifs/cifsfs.c +++ b/fs/cifs/cifsfs.c | |||
| @@ -312,6 +312,7 @@ cifs_alloc_inode(struct super_block *sb) | |||
| 312 | file data or metadata */ | 312 | file data or metadata */ |
| 313 | cifs_inode->clientCanCacheRead = false; | 313 | cifs_inode->clientCanCacheRead = false; |
| 314 | cifs_inode->clientCanCacheAll = false; | 314 | cifs_inode->clientCanCacheAll = false; |
| 315 | cifs_inode->delete_pending = false; | ||
| 315 | cifs_inode->vfs_inode.i_blkbits = 14; /* 2**14 = CIFS_MAX_MSGSIZE */ | 316 | cifs_inode->vfs_inode.i_blkbits = 14; /* 2**14 = CIFS_MAX_MSGSIZE */ |
| 316 | 317 | ||
| 317 | /* Can not set i_flags here - they get immediately overwritten | 318 | /* Can not set i_flags here - they get immediately overwritten |
| @@ -620,6 +621,37 @@ static loff_t cifs_llseek(struct file *file, loff_t offset, int origin) | |||
| 620 | return generic_file_llseek_unlocked(file, offset, origin); | 621 | return generic_file_llseek_unlocked(file, offset, origin); |
| 621 | } | 622 | } |
| 622 | 623 | ||
| 624 | #ifdef CONFIG_CIFS_EXPERIMENTAL | ||
| 625 | static int cifs_setlease(struct file *file, long arg, struct file_lock **lease) | ||
| 626 | { | ||
| 627 | /* note that this is called by vfs setlease with the BKL held | ||
| 628 | although I doubt that BKL is needed here in cifs */ | ||
| 629 | struct inode *inode = file->f_path.dentry->d_inode; | ||
| 630 | |||
| 631 | if (!(S_ISREG(inode->i_mode))) | ||
| 632 | return -EINVAL; | ||
| 633 | |||
| 634 | /* check if file is oplocked */ | ||
| 635 | if (((arg == F_RDLCK) && | ||
| 636 | (CIFS_I(inode)->clientCanCacheRead)) || | ||
| 637 | ((arg == F_WRLCK) && | ||
| 638 | (CIFS_I(inode)->clientCanCacheAll))) | ||
| 639 | return generic_setlease(file, arg, lease); | ||
| 640 | else if (CIFS_SB(inode->i_sb)->tcon->local_lease && | ||
| 641 | !CIFS_I(inode)->clientCanCacheRead) | ||
| 642 | /* If the server claims to support oplock on this | ||
| 643 | file, then we still need to check oplock even | ||
| 644 | if the local_lease mount option is set, but there | ||
| 645 | are servers which do not support oplock for which | ||
| 646 | this mount option may be useful if the user | ||
| 647 | knows that the file won't be changed on the server | ||
| 648 | by anyone else */ | ||
| 649 | return generic_setlease(file, arg, lease); | ||
| 650 | else | ||
| 651 | return -EAGAIN; | ||
| 652 | } | ||
| 653 | #endif | ||
| 654 | |||
| 623 | struct file_system_type cifs_fs_type = { | 655 | struct file_system_type cifs_fs_type = { |
| 624 | .owner = THIS_MODULE, | 656 | .owner = THIS_MODULE, |
| 625 | .name = "cifs", | 657 | .name = "cifs", |
| @@ -698,6 +730,7 @@ const struct file_operations cifs_file_ops = { | |||
| 698 | 730 | ||
| 699 | #ifdef CONFIG_CIFS_EXPERIMENTAL | 731 | #ifdef CONFIG_CIFS_EXPERIMENTAL |
| 700 | .dir_notify = cifs_dir_notify, | 732 | .dir_notify = cifs_dir_notify, |
| 733 | .setlease = cifs_setlease, | ||
| 701 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ | 734 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ |
| 702 | }; | 735 | }; |
| 703 | 736 | ||
| @@ -718,6 +751,7 @@ const struct file_operations cifs_file_direct_ops = { | |||
| 718 | .llseek = cifs_llseek, | 751 | .llseek = cifs_llseek, |
| 719 | #ifdef CONFIG_CIFS_EXPERIMENTAL | 752 | #ifdef CONFIG_CIFS_EXPERIMENTAL |
| 720 | .dir_notify = cifs_dir_notify, | 753 | .dir_notify = cifs_dir_notify, |
| 754 | .setlease = cifs_setlease, | ||
| 721 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ | 755 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ |
| 722 | }; | 756 | }; |
| 723 | const struct file_operations cifs_file_nobrl_ops = { | 757 | const struct file_operations cifs_file_nobrl_ops = { |
| @@ -738,6 +772,7 @@ const struct file_operations cifs_file_nobrl_ops = { | |||
| 738 | 772 | ||
| 739 | #ifdef CONFIG_CIFS_EXPERIMENTAL | 773 | #ifdef CONFIG_CIFS_EXPERIMENTAL |
| 740 | .dir_notify = cifs_dir_notify, | 774 | .dir_notify = cifs_dir_notify, |
| 775 | .setlease = cifs_setlease, | ||
| 741 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ | 776 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ |
| 742 | }; | 777 | }; |
| 743 | 778 | ||
| @@ -757,6 +792,7 @@ const struct file_operations cifs_file_direct_nobrl_ops = { | |||
| 757 | .llseek = cifs_llseek, | 792 | .llseek = cifs_llseek, |
| 758 | #ifdef CONFIG_CIFS_EXPERIMENTAL | 793 | #ifdef CONFIG_CIFS_EXPERIMENTAL |
| 759 | .dir_notify = cifs_dir_notify, | 794 | .dir_notify = cifs_dir_notify, |
| 795 | .setlease = cifs_setlease, | ||
| 760 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ | 796 | #endif /* CONFIG_CIFS_EXPERIMENTAL */ |
| 761 | }; | 797 | }; |
| 762 | 798 | ||
| @@ -949,6 +985,12 @@ static int cifs_oplock_thread(void *dummyarg) | |||
| 949 | the call */ | 985 | the call */ |
| 950 | /* mutex_lock(&inode->i_mutex);*/ | 986 | /* mutex_lock(&inode->i_mutex);*/ |
| 951 | if (S_ISREG(inode->i_mode)) { | 987 | if (S_ISREG(inode->i_mode)) { |
| 988 | #ifdef CONFIG_CIFS_EXPERIMENTAL | ||
| 989 | if (CIFS_I(inode)->clientCanCacheAll == 0) | ||
| 990 | break_lease(inode, FMODE_READ); | ||
| 991 | else if (CIFS_I(inode)->clientCanCacheRead == 0) | ||
| 992 | break_lease(inode, FMODE_WRITE); | ||
| 993 | #endif | ||
| 952 | rc = filemap_fdatawrite(inode->i_mapping); | 994 | rc = filemap_fdatawrite(inode->i_mapping); |
| 953 | if (CIFS_I(inode)->clientCanCacheRead == 0) { | 995 | if (CIFS_I(inode)->clientCanCacheRead == 0) { |
| 954 | waitrc = filemap_fdatawait( | 996 | waitrc = filemap_fdatawait( |
diff --git a/fs/cifs/cifsfs.h b/fs/cifs/cifsfs.h index f7b4a5cd837b..074de0b5064d 100644 --- a/fs/cifs/cifsfs.h +++ b/fs/cifs/cifsfs.h | |||
| @@ -101,5 +101,5 @@ extern long cifs_ioctl(struct file *filep, unsigned int cmd, unsigned long arg); | |||
| 101 | extern const struct export_operations cifs_export_ops; | 101 | extern const struct export_operations cifs_export_ops; |
| 102 | #endif /* EXPERIMENTAL */ | 102 | #endif /* EXPERIMENTAL */ |
| 103 | 103 | ||
| 104 | #define CIFS_VERSION "1.54" | 104 | #define CIFS_VERSION "1.55" |
| 105 | #endif /* _CIFSFS_H */ | 105 | #endif /* _CIFSFS_H */ |
diff --git a/fs/cifs/cifsglob.h b/fs/cifs/cifsglob.h index 0d22479d99b7..c791e5b5a914 100644 --- a/fs/cifs/cifsglob.h +++ b/fs/cifs/cifsglob.h | |||
| @@ -285,6 +285,7 @@ struct cifsTconInfo { | |||
| 285 | bool seal:1; /* transport encryption for this mounted share */ | 285 | bool seal:1; /* transport encryption for this mounted share */ |
| 286 | bool unix_ext:1; /* if false disable Linux extensions to CIFS protocol | 286 | bool unix_ext:1; /* if false disable Linux extensions to CIFS protocol |
| 287 | for this mount even if server would support */ | 287 | for this mount even if server would support */ |
| 288 | bool local_lease:1; /* check leases (only) on local system not remote */ | ||
| 288 | /* BB add field for back pointer to sb struct(s)? */ | 289 | /* BB add field for back pointer to sb struct(s)? */ |
| 289 | }; | 290 | }; |
| 290 | 291 | ||
| @@ -353,6 +354,7 @@ struct cifsInodeInfo { | |||
| 353 | bool clientCanCacheRead:1; /* read oplock */ | 354 | bool clientCanCacheRead:1; /* read oplock */ |
| 354 | bool clientCanCacheAll:1; /* read and writebehind oplock */ | 355 | bool clientCanCacheAll:1; /* read and writebehind oplock */ |
| 355 | bool oplockPending:1; | 356 | bool oplockPending:1; |
| 357 | bool delete_pending:1; /* DELETE_ON_CLOSE is set */ | ||
| 356 | struct inode vfs_inode; | 358 | struct inode vfs_inode; |
| 357 | }; | 359 | }; |
| 358 | 360 | ||
diff --git a/fs/cifs/cifssmb.c b/fs/cifs/cifssmb.c index 6f4ffe15d68d..843a85fb8b9a 100644 --- a/fs/cifs/cifssmb.c +++ b/fs/cifs/cifssmb.c | |||
| @@ -1309,6 +1309,7 @@ OldOpenRetry: | |||
| 1309 | cpu_to_le64(le32_to_cpu(pSMBr->EndOfFile)); | 1309 | cpu_to_le64(le32_to_cpu(pSMBr->EndOfFile)); |
| 1310 | pfile_info->EndOfFile = pfile_info->AllocationSize; | 1310 | pfile_info->EndOfFile = pfile_info->AllocationSize; |
| 1311 | pfile_info->NumberOfLinks = cpu_to_le32(1); | 1311 | pfile_info->NumberOfLinks = cpu_to_le32(1); |
| 1312 | pfile_info->DeletePending = 0; | ||
| 1312 | } | 1313 | } |
| 1313 | } | 1314 | } |
| 1314 | 1315 | ||
| @@ -1410,6 +1411,7 @@ openRetry: | |||
| 1410 | pfile_info->AllocationSize = pSMBr->AllocationSize; | 1411 | pfile_info->AllocationSize = pSMBr->AllocationSize; |
| 1411 | pfile_info->EndOfFile = pSMBr->EndOfFile; | 1412 | pfile_info->EndOfFile = pSMBr->EndOfFile; |
| 1412 | pfile_info->NumberOfLinks = cpu_to_le32(1); | 1413 | pfile_info->NumberOfLinks = cpu_to_le32(1); |
| 1414 | pfile_info->DeletePending = 0; | ||
| 1413 | } | 1415 | } |
| 1414 | } | 1416 | } |
| 1415 | 1417 | ||
diff --git a/fs/cifs/connect.c b/fs/cifs/connect.c index 4c13bcdb92a5..71b7661e2260 100644 --- a/fs/cifs/connect.c +++ b/fs/cifs/connect.c | |||
| @@ -90,6 +90,8 @@ struct smb_vol { | |||
| 90 | bool nocase:1; /* request case insensitive filenames */ | 90 | bool nocase:1; /* request case insensitive filenames */ |
| 91 | bool nobrl:1; /* disable sending byte range locks to srv */ | 91 | bool nobrl:1; /* disable sending byte range locks to srv */ |
| 92 | bool seal:1; /* request transport encryption on share */ | 92 | bool seal:1; /* request transport encryption on share */ |
| 93 | bool nodfs:1; /* Do not request DFS, even if available */ | ||
| 94 | bool local_lease:1; /* check leases only on local system, not remote */ | ||
| 93 | unsigned int rsize; | 95 | unsigned int rsize; |
| 94 | unsigned int wsize; | 96 | unsigned int wsize; |
| 95 | unsigned int sockopt; | 97 | unsigned int sockopt; |
| @@ -124,7 +126,7 @@ cifs_reconnect(struct TCP_Server_Info *server) | |||
| 124 | struct mid_q_entry *mid_entry; | 126 | struct mid_q_entry *mid_entry; |
| 125 | 127 | ||
| 126 | spin_lock(&GlobalMid_Lock); | 128 | spin_lock(&GlobalMid_Lock); |
| 127 | if (kthread_should_stop()) { | 129 | if (server->tcpStatus == CifsExiting) { |
| 128 | /* the demux thread will exit normally | 130 | /* the demux thread will exit normally |
| 129 | next time through the loop */ | 131 | next time through the loop */ |
| 130 | spin_unlock(&GlobalMid_Lock); | 132 | spin_unlock(&GlobalMid_Lock); |
| @@ -184,7 +186,8 @@ cifs_reconnect(struct TCP_Server_Info *server) | |||
| 184 | spin_unlock(&GlobalMid_Lock); | 186 | spin_unlock(&GlobalMid_Lock); |
| 185 | up(&server->tcpSem); | 187 | up(&server->tcpSem); |
| 186 | 188 | ||
| 187 | while ((!kthread_should_stop()) && (server->tcpStatus != CifsGood)) { | 189 | while ((server->tcpStatus != CifsExiting) && |
| 190 | (server->tcpStatus != CifsGood)) { | ||
| 188 | try_to_freeze(); | 191 | try_to_freeze(); |
| 189 | if (server->protocolType == IPV6) { | 192 | if (server->protocolType == IPV6) { |
| 190 | rc = ipv6_connect(&server->addr.sockAddr6, | 193 | rc = ipv6_connect(&server->addr.sockAddr6, |
| @@ -201,7 +204,7 @@ cifs_reconnect(struct TCP_Server_Info *server) | |||
| 201 | } else { | 204 | } else { |
| 202 | atomic_inc(&tcpSesReconnectCount); | 205 | atomic_inc(&tcpSesReconnectCount); |
| 203 | spin_lock(&GlobalMid_Lock); | 206 | spin_lock(&GlobalMid_Lock); |
| 204 | if (!kthread_should_stop()) | 207 | if (server->tcpStatus != CifsExiting) |
| 205 | server->tcpStatus = CifsGood; | 208 | server->tcpStatus = CifsGood; |
| 206 | server->sequence_number = 0; | 209 | server->sequence_number = 0; |
| 207 | spin_unlock(&GlobalMid_Lock); | 210 | spin_unlock(&GlobalMid_Lock); |
| @@ -356,7 +359,7 @@ cifs_demultiplex_thread(struct TCP_Server_Info *server) | |||
| 356 | GFP_KERNEL); | 359 | GFP_KERNEL); |
| 357 | 360 | ||
| 358 | set_freezable(); | 361 | set_freezable(); |
| 359 | while (!kthread_should_stop()) { | 362 | while (server->tcpStatus != CifsExiting) { |
| 360 | if (try_to_freeze()) | 363 | if (try_to_freeze()) |
| 361 | continue; | 364 | continue; |
| 362 | if (bigbuf == NULL) { | 365 | if (bigbuf == NULL) { |
| @@ -397,7 +400,7 @@ incomplete_rcv: | |||
| 397 | kernel_recvmsg(csocket, &smb_msg, | 400 | kernel_recvmsg(csocket, &smb_msg, |
| 398 | &iov, 1, pdu_length, 0 /* BB other flags? */); | 401 | &iov, 1, pdu_length, 0 /* BB other flags? */); |
| 399 | 402 | ||
| 400 | if (kthread_should_stop()) { | 403 | if (server->tcpStatus == CifsExiting) { |
| 401 | break; | 404 | break; |
| 402 | } else if (server->tcpStatus == CifsNeedReconnect) { | 405 | } else if (server->tcpStatus == CifsNeedReconnect) { |
| 403 | cFYI(1, ("Reconnect after server stopped responding")); | 406 | cFYI(1, ("Reconnect after server stopped responding")); |
| @@ -522,7 +525,7 @@ incomplete_rcv: | |||
| 522 | total_read += length) { | 525 | total_read += length) { |
| 523 | length = kernel_recvmsg(csocket, &smb_msg, &iov, 1, | 526 | length = kernel_recvmsg(csocket, &smb_msg, &iov, 1, |
| 524 | pdu_length - total_read, 0); | 527 | pdu_length - total_read, 0); |
| 525 | if (kthread_should_stop() || | 528 | if ((server->tcpStatus == CifsExiting) || |
| 526 | (length == -EINTR)) { | 529 | (length == -EINTR)) { |
| 527 | /* then will exit */ | 530 | /* then will exit */ |
| 528 | reconnect = 2; | 531 | reconnect = 2; |
| @@ -651,14 +654,6 @@ multi_t2_fnd: | |||
| 651 | spin_unlock(&GlobalMid_Lock); | 654 | spin_unlock(&GlobalMid_Lock); |
| 652 | wake_up_all(&server->response_q); | 655 | wake_up_all(&server->response_q); |
| 653 | 656 | ||
| 654 | /* don't exit until kthread_stop is called */ | ||
| 655 | set_current_state(TASK_UNINTERRUPTIBLE); | ||
| 656 | while (!kthread_should_stop()) { | ||
| 657 | schedule(); | ||
| 658 | set_current_state(TASK_UNINTERRUPTIBLE); | ||
| 659 | } | ||
| 660 | set_current_state(TASK_RUNNING); | ||
| 661 | |||
| 662 | /* check if we have blocked requests that need to free */ | 657 | /* check if we have blocked requests that need to free */ |
| 663 | /* Note that cifs_max_pending is normally 50, but | 658 | /* Note that cifs_max_pending is normally 50, but |
| 664 | can be set at module install time to as little as two */ | 659 | can be set at module install time to as little as two */ |
| @@ -755,6 +750,7 @@ multi_t2_fnd: | |||
| 755 | write_unlock(&GlobalSMBSeslock); | 750 | write_unlock(&GlobalSMBSeslock); |
| 756 | 751 | ||
| 757 | kfree(server->hostname); | 752 | kfree(server->hostname); |
| 753 | task_to_wake = xchg(&server->tsk, NULL); | ||
| 758 | kfree(server); | 754 | kfree(server); |
| 759 | 755 | ||
| 760 | length = atomic_dec_return(&tcpSesAllocCount); | 756 | length = atomic_dec_return(&tcpSesAllocCount); |
| @@ -762,6 +758,16 @@ multi_t2_fnd: | |||
| 762 | mempool_resize(cifs_req_poolp, length + cifs_min_rcv, | 758 | mempool_resize(cifs_req_poolp, length + cifs_min_rcv, |
| 763 | GFP_KERNEL); | 759 | GFP_KERNEL); |
| 764 | 760 | ||
| 761 | /* if server->tsk was NULL then wait for a signal before exiting */ | ||
| 762 | if (!task_to_wake) { | ||
| 763 | set_current_state(TASK_INTERRUPTIBLE); | ||
| 764 | while (!signal_pending(current)) { | ||
| 765 | schedule(); | ||
| 766 | set_current_state(TASK_INTERRUPTIBLE); | ||
| 767 | } | ||
| 768 | set_current_state(TASK_RUNNING); | ||
| 769 | } | ||
| 770 | |||
| 765 | return 0; | 771 | return 0; |
| 766 | } | 772 | } |
| 767 | 773 | ||
| @@ -1218,6 +1224,8 @@ cifs_parse_mount_options(char *options, const char *devname, | |||
| 1218 | vol->sfu_emul = 1; | 1224 | vol->sfu_emul = 1; |
| 1219 | } else if (strnicmp(data, "nosfu", 5) == 0) { | 1225 | } else if (strnicmp(data, "nosfu", 5) == 0) { |
| 1220 | vol->sfu_emul = 0; | 1226 | vol->sfu_emul = 0; |
| 1227 | } else if (strnicmp(data, "nodfs", 5) == 0) { | ||
| 1228 | vol->nodfs = 1; | ||
| 1221 | } else if (strnicmp(data, "posixpaths", 10) == 0) { | 1229 | } else if (strnicmp(data, "posixpaths", 10) == 0) { |
| 1222 | vol->posix_paths = 1; | 1230 | vol->posix_paths = 1; |
| 1223 | } else if (strnicmp(data, "noposixpaths", 12) == 0) { | 1231 | } else if (strnicmp(data, "noposixpaths", 12) == 0) { |
| @@ -1268,6 +1276,10 @@ cifs_parse_mount_options(char *options, const char *devname, | |||
| 1268 | vol->no_psx_acl = 0; | 1276 | vol->no_psx_acl = 0; |
| 1269 | } else if (strnicmp(data, "noacl", 5) == 0) { | 1277 | } else if (strnicmp(data, "noacl", 5) == 0) { |
| 1270 | vol->no_psx_acl = 1; | 1278 | vol->no_psx_acl = 1; |
| 1279 | #ifdef CONFIG_CIFS_EXPERIMENTAL | ||
| 1280 | } else if (strnicmp(data, "locallease", 6) == 0) { | ||
| 1281 | vol->local_lease = 1; | ||
| 1282 | #endif | ||
| 1271 | } else if (strnicmp(data, "sign", 4) == 0) { | 1283 | } else if (strnicmp(data, "sign", 4) == 0) { |
| 1272 | vol->secFlg |= CIFSSEC_MUST_SIGN; | 1284 | vol->secFlg |= CIFSSEC_MUST_SIGN; |
| 1273 | } else if (strnicmp(data, "seal", 4) == 0) { | 1285 | } else if (strnicmp(data, "seal", 4) == 0) { |
| @@ -1845,6 +1857,16 @@ convert_delimiter(char *path, char delim) | |||
| 1845 | } | 1857 | } |
| 1846 | } | 1858 | } |
| 1847 | 1859 | ||
| 1860 | static void | ||
| 1861 | kill_cifsd(struct TCP_Server_Info *server) | ||
| 1862 | { | ||
| 1863 | struct task_struct *task; | ||
| 1864 | |||
| 1865 | task = xchg(&server->tsk, NULL); | ||
| 1866 | if (task) | ||
| 1867 | force_sig(SIGKILL, task); | ||
| 1868 | } | ||
| 1869 | |||
| 1848 | int | 1870 | int |
| 1849 | cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, | 1871 | cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, |
| 1850 | char *mount_data, const char *devname) | 1872 | char *mount_data, const char *devname) |
| @@ -2166,6 +2188,7 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, | |||
| 2166 | for the retry flag is used */ | 2188 | for the retry flag is used */ |
| 2167 | tcon->retry = volume_info.retry; | 2189 | tcon->retry = volume_info.retry; |
| 2168 | tcon->nocase = volume_info.nocase; | 2190 | tcon->nocase = volume_info.nocase; |
| 2191 | tcon->local_lease = volume_info.local_lease; | ||
| 2169 | if (tcon->seal != volume_info.seal) | 2192 | if (tcon->seal != volume_info.seal) |
| 2170 | cERROR(1, ("transport encryption setting " | 2193 | cERROR(1, ("transport encryption setting " |
| 2171 | "conflicts with existing tid")); | 2194 | "conflicts with existing tid")); |
| @@ -2197,6 +2220,12 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, | |||
| 2197 | volume_info.UNC, | 2220 | volume_info.UNC, |
| 2198 | tcon, cifs_sb->local_nls); | 2221 | tcon, cifs_sb->local_nls); |
| 2199 | cFYI(1, ("CIFS Tcon rc = %d", rc)); | 2222 | cFYI(1, ("CIFS Tcon rc = %d", rc)); |
| 2223 | if (volume_info.nodfs) { | ||
| 2224 | tcon->Flags &= | ||
| 2225 | ~SMB_SHARE_IS_IN_DFS; | ||
| 2226 | cFYI(1, ("DFS disabled (%d)", | ||
| 2227 | tcon->Flags)); | ||
| 2228 | } | ||
| 2200 | } | 2229 | } |
| 2201 | if (!rc) { | 2230 | if (!rc) { |
| 2202 | atomic_inc(&pSesInfo->inUse); | 2231 | atomic_inc(&pSesInfo->inUse); |
| @@ -2225,14 +2254,7 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, | |||
| 2225 | spin_lock(&GlobalMid_Lock); | 2254 | spin_lock(&GlobalMid_Lock); |
| 2226 | srvTcp->tcpStatus = CifsExiting; | 2255 | srvTcp->tcpStatus = CifsExiting; |
| 2227 | spin_unlock(&GlobalMid_Lock); | 2256 | spin_unlock(&GlobalMid_Lock); |
| 2228 | if (srvTcp->tsk) { | 2257 | kill_cifsd(srvTcp); |
| 2229 | /* If we could verify that kthread_stop would | ||
| 2230 | always wake up processes blocked in | ||
| 2231 | tcp in recv_mesg then we could remove the | ||
| 2232 | send_sig call */ | ||
| 2233 | force_sig(SIGKILL, srvTcp->tsk); | ||
| 2234 | kthread_stop(srvTcp->tsk); | ||
| 2235 | } | ||
| 2236 | } | 2258 | } |
| 2237 | /* If find_unc succeeded then rc == 0 so we can not end */ | 2259 | /* If find_unc succeeded then rc == 0 so we can not end */ |
| 2238 | if (tcon) /* up accidently freeing someone elses tcon struct */ | 2260 | if (tcon) /* up accidently freeing someone elses tcon struct */ |
| @@ -2245,19 +2267,15 @@ cifs_mount(struct super_block *sb, struct cifs_sb_info *cifs_sb, | |||
| 2245 | temp_rc = CIFSSMBLogoff(xid, pSesInfo); | 2267 | temp_rc = CIFSSMBLogoff(xid, pSesInfo); |
| 2246 | /* if the socketUseCount is now zero */ | 2268 | /* if the socketUseCount is now zero */ |
| 2247 | if ((temp_rc == -ESHUTDOWN) && | 2269 | if ((temp_rc == -ESHUTDOWN) && |
| 2248 | (pSesInfo->server) && | 2270 | (pSesInfo->server)) |
| 2249 | (pSesInfo->server->tsk)) { | 2271 | kill_cifsd(pSesInfo->server); |
| 2250 | force_sig(SIGKILL, | ||
| 2251 | pSesInfo->server->tsk); | ||
| 2252 | kthread_stop(pSesInfo->server->tsk); | ||
| 2253 | } | ||
| 2254 | } else { | 2272 | } else { |
| 2255 | cFYI(1, ("No session or bad tcon")); | 2273 | cFYI(1, ("No session or bad tcon")); |
| 2256 | if ((pSesInfo->server) && | 2274 | if (pSesInfo->server) { |
| 2257 | (pSesInfo->server->tsk)) { | 2275 | spin_lock(&GlobalMid_Lock); |
| 2258 | force_sig(SIGKILL, | 2276 | srvTcp->tcpStatus = CifsExiting; |
| 2259 | pSesInfo->server->tsk); | 2277 | spin_unlock(&GlobalMid_Lock); |
| 2260 | kthread_stop(pSesInfo->server->tsk); | 2278 | kill_cifsd(pSesInfo->server); |
| 2261 | } | 2279 | } |
| 2262 | } | 2280 | } |
| 2263 | sesInfoFree(pSesInfo); | 2281 | sesInfoFree(pSesInfo); |
| @@ -3544,7 +3562,6 @@ cifs_umount(struct super_block *sb, struct cifs_sb_info *cifs_sb) | |||
| 3544 | int rc = 0; | 3562 | int rc = 0; |
| 3545 | int xid; | 3563 | int xid; |
| 3546 | struct cifsSesInfo *ses = NULL; | 3564 | struct cifsSesInfo *ses = NULL; |
| 3547 | struct task_struct *cifsd_task; | ||
| 3548 | char *tmp; | 3565 | char *tmp; |
| 3549 | 3566 | ||
| 3550 | xid = GetXid(); | 3567 | xid = GetXid(); |
| @@ -3560,7 +3577,6 @@ cifs_umount(struct super_block *sb, struct cifs_sb_info *cifs_sb) | |||
| 3560 | tconInfoFree(cifs_sb->tcon); | 3577 | tconInfoFree(cifs_sb->tcon); |
| 3561 | if ((ses) && (ses->server)) { | 3578 | if ((ses) && (ses->server)) { |
| 3562 | /* save off task so we do not refer to ses later */ | 3579 | /* save off task so we do not refer to ses later */ |
| 3563 | cifsd_task = ses->server->tsk; | ||
| 3564 | cFYI(1, ("About to do SMBLogoff ")); | 3580 | cFYI(1, ("About to do SMBLogoff ")); |
| 3565 | rc = CIFSSMBLogoff(xid, ses); | 3581 | rc = CIFSSMBLogoff(xid, ses); |
| 3566 | if (rc == -EBUSY) { | 3582 | if (rc == -EBUSY) { |
| @@ -3568,10 +3584,8 @@ cifs_umount(struct super_block *sb, struct cifs_sb_info *cifs_sb) | |||
| 3568 | return 0; | 3584 | return 0; |
| 3569 | } else if (rc == -ESHUTDOWN) { | 3585 | } else if (rc == -ESHUTDOWN) { |
| 3570 | cFYI(1, ("Waking up socket by sending signal")); | 3586 | cFYI(1, ("Waking up socket by sending signal")); |
| 3571 | if (cifsd_task) { | 3587 | if (ses->server) |
| 3572 | force_sig(SIGKILL, cifsd_task); | 3588 | kill_cifsd(ses->server); |
| 3573 | kthread_stop(cifsd_task); | ||
| 3574 | } | ||
| 3575 | rc = 0; | 3589 | rc = 0; |
| 3576 | } /* else - we have an smb session | 3590 | } /* else - we have an smb session |
| 3577 | left on this socket do not kill cifsd */ | 3591 | left on this socket do not kill cifsd */ |
| @@ -3701,7 +3715,9 @@ int cifs_setup_session(unsigned int xid, struct cifsSesInfo *pSesInfo, | |||
| 3701 | cERROR(1, ("Send error in SessSetup = %d", rc)); | 3715 | cERROR(1, ("Send error in SessSetup = %d", rc)); |
| 3702 | } else { | 3716 | } else { |
| 3703 | cFYI(1, ("CIFS Session Established successfully")); | 3717 | cFYI(1, ("CIFS Session Established successfully")); |
| 3718 | spin_lock(&GlobalMid_Lock); | ||
| 3704 | pSesInfo->status = CifsGood; | 3719 | pSesInfo->status = CifsGood; |
| 3720 | spin_unlock(&GlobalMid_Lock); | ||
| 3705 | } | 3721 | } |
| 3706 | 3722 | ||
| 3707 | ss_err_exit: | 3723 | ss_err_exit: |
diff --git a/fs/cifs/inode.c b/fs/cifs/inode.c index a8c833345fc9..d54fa8aeaea9 100644 --- a/fs/cifs/inode.c +++ b/fs/cifs/inode.c | |||
| @@ -506,6 +506,7 @@ int cifs_get_inode_info(struct inode **pinode, | |||
| 506 | inode = *pinode; | 506 | inode = *pinode; |
| 507 | cifsInfo = CIFS_I(inode); | 507 | cifsInfo = CIFS_I(inode); |
| 508 | cifsInfo->cifsAttrs = attr; | 508 | cifsInfo->cifsAttrs = attr; |
| 509 | cifsInfo->delete_pending = pfindData->DeletePending ? true : false; | ||
| 509 | cFYI(1, ("Old time %ld", cifsInfo->time)); | 510 | cFYI(1, ("Old time %ld", cifsInfo->time)); |
| 510 | cifsInfo->time = jiffies; | 511 | cifsInfo->time = jiffies; |
| 511 | cFYI(1, ("New time %ld", cifsInfo->time)); | 512 | cFYI(1, ("New time %ld", cifsInfo->time)); |
| @@ -772,63 +773,106 @@ out: | |||
| 772 | * anything else. | 773 | * anything else. |
| 773 | */ | 774 | */ |
| 774 | static int | 775 | static int |
| 775 | cifs_rename_pending_delete(char *full_path, struct inode *inode, int xid) | 776 | cifs_rename_pending_delete(char *full_path, struct dentry *dentry, int xid) |
| 776 | { | 777 | { |
| 777 | int oplock = 0; | 778 | int oplock = 0; |
| 778 | int rc; | 779 | int rc; |
| 779 | __u16 netfid; | 780 | __u16 netfid; |
| 781 | struct inode *inode = dentry->d_inode; | ||
| 780 | struct cifsInodeInfo *cifsInode = CIFS_I(inode); | 782 | struct cifsInodeInfo *cifsInode = CIFS_I(inode); |
| 781 | struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); | 783 | struct cifs_sb_info *cifs_sb = CIFS_SB(inode->i_sb); |
| 782 | struct cifsTconInfo *tcon = cifs_sb->tcon; | 784 | struct cifsTconInfo *tcon = cifs_sb->tcon; |
| 783 | __u32 dosattr; | 785 | __u32 dosattr, origattr; |
| 784 | FILE_BASIC_INFO *info_buf; | 786 | FILE_BASIC_INFO *info_buf = NULL; |
| 785 | 787 | ||
| 786 | rc = CIFSSMBOpen(xid, tcon, full_path, FILE_OPEN, | 788 | rc = CIFSSMBOpen(xid, tcon, full_path, FILE_OPEN, |
| 787 | DELETE|FILE_WRITE_ATTRIBUTES, | 789 | DELETE|FILE_WRITE_ATTRIBUTES, CREATE_NOT_DIR, |
| 788 | CREATE_NOT_DIR|CREATE_DELETE_ON_CLOSE, | ||
| 789 | &netfid, &oplock, NULL, cifs_sb->local_nls, | 790 | &netfid, &oplock, NULL, cifs_sb->local_nls, |
| 790 | cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR); | 791 | cifs_sb->mnt_cifs_flags & CIFS_MOUNT_MAP_SPECIAL_CHR); |
| 791 | if (rc != 0) | 792 | if (rc != 0) |
| 792 | goto out; | 793 | goto out; |
| 793 | 794 | ||
| 794 | /* set ATTR_HIDDEN and clear ATTR_READONLY */ | 795 | origattr = cifsInode->cifsAttrs; |
| 795 | cifsInode = CIFS_I(inode); | 796 | if (origattr == 0) |
| 796 | dosattr = cifsInode->cifsAttrs & ~ATTR_READONLY; | 797 | origattr |= ATTR_NORMAL; |
| 798 | |||
| 799 | dosattr = origattr & ~ATTR_READONLY; | ||
| 797 | if (dosattr == 0) | 800 | if (dosattr == 0) |
| 798 | dosattr |= ATTR_NORMAL; | 801 | dosattr |= ATTR_NORMAL; |
| 799 | dosattr |= ATTR_HIDDEN; | 802 | dosattr |= ATTR_HIDDEN; |
| 800 | 803 | ||
| 801 | info_buf = kzalloc(sizeof(*info_buf), GFP_KERNEL); | 804 | /* set ATTR_HIDDEN and clear ATTR_READONLY, but only if needed */ |
| 802 | if (info_buf == NULL) { | 805 | if (dosattr != origattr) { |
| 803 | rc = -ENOMEM; | 806 | info_buf = kzalloc(sizeof(*info_buf), GFP_KERNEL); |
| 804 | goto out_close; | 807 | if (info_buf == NULL) { |
| 808 | rc = -ENOMEM; | ||
| 809 | goto out_close; | ||
| 810 | } | ||
| 811 | info_buf->Attributes = cpu_to_le32(dosattr); | ||
| 812 | rc = CIFSSMBSetFileInfo(xid, tcon, info_buf, netfid, | ||
| 813 | current->tgid); | ||
| 814 | /* although we would like to mark the file hidden | ||
| 815 | if that fails we will still try to rename it */ | ||
| 816 | if (rc != 0) | ||
| 817 | cifsInode->cifsAttrs = dosattr; | ||
| 818 | else | ||
| 819 | dosattr = origattr; /* since not able to change them */ | ||
| 805 | } | 820 | } |
| 806 | info_buf->Attributes = cpu_to_le32(dosattr); | ||
| 807 | rc = CIFSSMBSetFileInfo(xid, tcon, info_buf, netfid, current->tgid); | ||
| 808 | kfree(info_buf); | ||
| 809 | if (rc != 0) | ||
| 810 | goto out_close; | ||
| 811 | cifsInode->cifsAttrs = dosattr; | ||
| 812 | 821 | ||
| 813 | /* silly-rename the file */ | 822 | /* rename the file */ |
| 814 | CIFSSMBRenameOpenFile(xid, tcon, netfid, NULL, cifs_sb->local_nls, | 823 | rc = CIFSSMBRenameOpenFile(xid, tcon, netfid, NULL, cifs_sb->local_nls, |
| 815 | cifs_sb->mnt_cifs_flags & | 824 | cifs_sb->mnt_cifs_flags & |
| 816 | CIFS_MOUNT_MAP_SPECIAL_CHR); | 825 | CIFS_MOUNT_MAP_SPECIAL_CHR); |
| 826 | if (rc != 0) { | ||
| 827 | rc = -ETXTBSY; | ||
| 828 | goto undo_setattr; | ||
| 829 | } | ||
| 817 | 830 | ||
| 818 | /* set DELETE_ON_CLOSE */ | 831 | /* try to set DELETE_ON_CLOSE */ |
| 819 | rc = CIFSSMBSetFileDisposition(xid, tcon, true, netfid, current->tgid); | 832 | if (!cifsInode->delete_pending) { |
| 820 | 833 | rc = CIFSSMBSetFileDisposition(xid, tcon, true, netfid, | |
| 821 | /* | 834 | current->tgid); |
| 822 | * some samba versions return -ENOENT when we try to set the file | 835 | /* |
| 823 | * disposition here. Likely a samba bug, but work around it for now | 836 | * some samba versions return -ENOENT when we try to set the |
| 824 | */ | 837 | * file disposition here. Likely a samba bug, but work around |
| 825 | if (rc == -ENOENT) | 838 | * it for now. This means that some cifsXXX files may hang |
| 826 | rc = 0; | 839 | * around after they shouldn't. |
| 840 | * | ||
| 841 | * BB: remove this hack after more servers have the fix | ||
| 842 | */ | ||
| 843 | if (rc == -ENOENT) | ||
| 844 | rc = 0; | ||
| 845 | else if (rc != 0) { | ||
| 846 | rc = -ETXTBSY; | ||
| 847 | goto undo_rename; | ||
| 848 | } | ||
| 849 | cifsInode->delete_pending = true; | ||
| 850 | } | ||
| 827 | 851 | ||
| 828 | out_close: | 852 | out_close: |
| 829 | CIFSSMBClose(xid, tcon, netfid); | 853 | CIFSSMBClose(xid, tcon, netfid); |
| 830 | out: | 854 | out: |
| 855 | kfree(info_buf); | ||
| 831 | return rc; | 856 | return rc; |
| 857 | |||
| 858 | /* | ||
| 859 | * reset everything back to the original state. Don't bother | ||
| 860 | * dealing with errors here since we can't do anything about | ||
| 861 | * them anyway. | ||
| 862 | */ | ||
| 863 | undo_rename: | ||
| 864 | CIFSSMBRenameOpenFile(xid, tcon, netfid, dentry->d_name.name, | ||
| 865 | cifs_sb->local_nls, cifs_sb->mnt_cifs_flags & | ||
| 866 | CIFS_MOUNT_MAP_SPECIAL_CHR); | ||
| 867 | undo_setattr: | ||
| 868 | if (dosattr != origattr) { | ||
| 869 | info_buf->Attributes = cpu_to_le32(origattr); | ||
| 870 | if (!CIFSSMBSetFileInfo(xid, tcon, info_buf, netfid, | ||
| 871 | current->tgid)) | ||
| 872 | cifsInode->cifsAttrs = origattr; | ||
| 873 | } | ||
| 874 | |||
| 875 | goto out_close; | ||
| 832 | } | 876 | } |
| 833 | 877 | ||
| 834 | int cifs_unlink(struct inode *dir, struct dentry *dentry) | 878 | int cifs_unlink(struct inode *dir, struct dentry *dentry) |
| @@ -878,7 +922,7 @@ psx_del_no_retry: | |||
| 878 | } else if (rc == -ENOENT) { | 922 | } else if (rc == -ENOENT) { |
| 879 | d_drop(dentry); | 923 | d_drop(dentry); |
| 880 | } else if (rc == -ETXTBSY) { | 924 | } else if (rc == -ETXTBSY) { |
| 881 | rc = cifs_rename_pending_delete(full_path, inode, xid); | 925 | rc = cifs_rename_pending_delete(full_path, dentry, xid); |
| 882 | if (rc == 0) | 926 | if (rc == 0) |
| 883 | drop_nlink(inode); | 927 | drop_nlink(inode); |
| 884 | } else if (rc == -EACCES && dosattr == 0) { | 928 | } else if (rc == -EACCES && dosattr == 0) { |
| @@ -1241,22 +1285,21 @@ cifs_do_rename(int xid, struct dentry *from_dentry, const char *fromPath, | |||
| 1241 | return rc; | 1285 | return rc; |
| 1242 | } | 1286 | } |
| 1243 | 1287 | ||
| 1244 | int cifs_rename(struct inode *source_inode, struct dentry *source_direntry, | 1288 | int cifs_rename(struct inode *source_dir, struct dentry *source_dentry, |
| 1245 | struct inode *target_inode, struct dentry *target_direntry) | 1289 | struct inode *target_dir, struct dentry *target_dentry) |
| 1246 | { | 1290 | { |
| 1247 | char *fromName = NULL; | 1291 | char *fromName = NULL; |
| 1248 | char *toName = NULL; | 1292 | char *toName = NULL; |
| 1249 | struct cifs_sb_info *cifs_sb_source; | 1293 | struct cifs_sb_info *cifs_sb_source; |
| 1250 | struct cifs_sb_info *cifs_sb_target; | 1294 | struct cifs_sb_info *cifs_sb_target; |
| 1251 | struct cifsTconInfo *pTcon; | 1295 | struct cifsTconInfo *tcon; |
| 1252 | FILE_UNIX_BASIC_INFO *info_buf_source = NULL; | 1296 | FILE_UNIX_BASIC_INFO *info_buf_source = NULL; |
| 1253 | FILE_UNIX_BASIC_INFO *info_buf_target; | 1297 | FILE_UNIX_BASIC_INFO *info_buf_target; |
| 1254 | int xid; | 1298 | int xid, rc, tmprc; |
| 1255 | int rc; | ||
| 1256 | 1299 | ||
| 1257 | cifs_sb_target = CIFS_SB(target_inode->i_sb); | 1300 | cifs_sb_target = CIFS_SB(target_dir->i_sb); |
| 1258 | cifs_sb_source = CIFS_SB(source_inode->i_sb); | 1301 | cifs_sb_source = CIFS_SB(source_dir->i_sb); |
| 1259 | pTcon = cifs_sb_source->tcon; | 1302 | tcon = cifs_sb_source->tcon; |
| 1260 | 1303 | ||
| 1261 | xid = GetXid(); | 1304 | xid = GetXid(); |
| 1262 | 1305 | ||
| @@ -1264,7 +1307,7 @@ int cifs_rename(struct inode *source_inode, struct dentry *source_direntry, | |||
| 1264 | * BB: this might be allowed if same server, but different share. | 1307 | * BB: this might be allowed if same server, but different share. |
| 1265 | * Consider adding support for this | 1308 | * Consider adding support for this |
| 1266 | */ | 1309 | */ |
| 1267 | if (pTcon != cifs_sb_target->tcon) { | 1310 | if (tcon != cifs_sb_target->tcon) { |
| 1268 | rc = -EXDEV; | 1311 | rc = -EXDEV; |
| 1269 | goto cifs_rename_exit; | 1312 | goto cifs_rename_exit; |
| 1270 | } | 1313 | } |
| @@ -1273,65 +1316,65 @@ int cifs_rename(struct inode *source_inode, struct dentry *source_direntry, | |||
| 1273 | * we already have the rename sem so we do not need to | 1316 | * we already have the rename sem so we do not need to |
| 1274 | * grab it again here to protect the path integrity | 1317 | * grab it again here to protect the path integrity |
| 1275 | */ | 1318 | */ |
| 1276 | fromName = build_path_from_dentry(source_direntry); | 1319 | fromName = build_path_from_dentry(source_dentry); |
| 1277 | if (fromName == NULL) { | 1320 | if (fromName == NULL) { |
| 1278 | rc = -ENOMEM; | 1321 | rc = -ENOMEM; |
| 1279 | goto cifs_rename_exit; | 1322 | goto cifs_rename_exit; |
| 1280 | } | 1323 | } |
| 1281 | 1324 | ||
| 1282 | toName = build_path_from_dentry(target_direntry); | 1325 | toName = build_path_from_dentry(target_dentry); |
| 1283 | if (toName == NULL) { | 1326 | if (toName == NULL) { |
| 1284 | rc = -ENOMEM; | 1327 | rc = -ENOMEM; |
| 1285 | goto cifs_rename_exit; | 1328 | goto cifs_rename_exit; |
| 1286 | } | 1329 | } |
| 1287 | 1330 | ||
| 1288 | rc = cifs_do_rename(xid, source_direntry, fromName, | 1331 | rc = cifs_do_rename(xid, source_dentry, fromName, |
| 1289 | target_direntry, toName); | 1332 | target_dentry, toName); |
| 1290 | 1333 | ||
| 1291 | if (rc == -EEXIST) { | 1334 | if (rc == -EEXIST && tcon->unix_ext) { |
| 1292 | if (pTcon->unix_ext) { | 1335 | /* |
| 1293 | /* | 1336 | * Are src and dst hardlinks of same inode? We can |
| 1294 | * Are src and dst hardlinks of same inode? We can | 1337 | * only tell with unix extensions enabled |
| 1295 | * only tell with unix extensions enabled | 1338 | */ |
| 1296 | */ | 1339 | info_buf_source = |
| 1297 | info_buf_source = | 1340 | kmalloc(2 * sizeof(FILE_UNIX_BASIC_INFO), |
| 1298 | kmalloc(2 * sizeof(FILE_UNIX_BASIC_INFO), | 1341 | GFP_KERNEL); |
| 1299 | GFP_KERNEL); | 1342 | if (info_buf_source == NULL) { |
| 1300 | if (info_buf_source == NULL) | 1343 | rc = -ENOMEM; |
| 1301 | goto unlink_target; | 1344 | goto cifs_rename_exit; |
| 1302 | 1345 | } | |
| 1303 | info_buf_target = info_buf_source + 1; | ||
| 1304 | rc = CIFSSMBUnixQPathInfo(xid, pTcon, fromName, | ||
| 1305 | info_buf_source, | ||
| 1306 | cifs_sb_source->local_nls, | ||
| 1307 | cifs_sb_source->mnt_cifs_flags & | ||
| 1308 | CIFS_MOUNT_MAP_SPECIAL_CHR); | ||
| 1309 | if (rc != 0) | ||
| 1310 | goto unlink_target; | ||
| 1311 | |||
| 1312 | rc = CIFSSMBUnixQPathInfo(xid, pTcon, | ||
| 1313 | toName, info_buf_target, | ||
| 1314 | cifs_sb_target->local_nls, | ||
| 1315 | /* remap based on source sb */ | ||
| 1316 | cifs_sb_source->mnt_cifs_flags & | ||
| 1317 | CIFS_MOUNT_MAP_SPECIAL_CHR); | ||
| 1318 | 1346 | ||
| 1319 | if (rc == 0 && (info_buf_source->UniqueId == | 1347 | info_buf_target = info_buf_source + 1; |
| 1320 | info_buf_target->UniqueId)) | 1348 | tmprc = CIFSSMBUnixQPathInfo(xid, tcon, fromName, |
| 1321 | /* same file, POSIX says that this is a noop */ | 1349 | info_buf_source, |
| 1322 | goto cifs_rename_exit; | 1350 | cifs_sb_source->local_nls, |
| 1323 | } /* else ... BB we could add the same check for Windows by | 1351 | cifs_sb_source->mnt_cifs_flags & |
| 1352 | CIFS_MOUNT_MAP_SPECIAL_CHR); | ||
| 1353 | if (tmprc != 0) | ||
| 1354 | goto unlink_target; | ||
| 1355 | |||
| 1356 | tmprc = CIFSSMBUnixQPathInfo(xid, tcon, | ||
| 1357 | toName, info_buf_target, | ||
| 1358 | cifs_sb_target->local_nls, | ||
| 1359 | /* remap based on source sb */ | ||
| 1360 | cifs_sb_source->mnt_cifs_flags & | ||
| 1361 | CIFS_MOUNT_MAP_SPECIAL_CHR); | ||
| 1362 | |||
| 1363 | if (tmprc == 0 && (info_buf_source->UniqueId == | ||
| 1364 | info_buf_target->UniqueId)) | ||
| 1365 | /* same file, POSIX says that this is a noop */ | ||
| 1366 | goto cifs_rename_exit; | ||
| 1367 | } /* else ... BB we could add the same check for Windows by | ||
| 1324 | checking the UniqueId via FILE_INTERNAL_INFO */ | 1368 | checking the UniqueId via FILE_INTERNAL_INFO */ |
| 1369 | |||
| 1325 | unlink_target: | 1370 | unlink_target: |
| 1326 | /* | 1371 | if ((rc == -EACCES) || (rc == -EEXIST)) { |
| 1327 | * we either can not tell the files are hardlinked (as with | 1372 | tmprc = cifs_unlink(target_dir, target_dentry); |
| 1328 | * Windows servers) or files are not hardlinked. Delete the | 1373 | if (tmprc) |
| 1329 | * target manually before renaming to follow POSIX rather than | 1374 | goto cifs_rename_exit; |
| 1330 | * Windows semantics | 1375 | |
| 1331 | */ | 1376 | rc = cifs_do_rename(xid, source_dentry, fromName, |
| 1332 | cifs_unlink(target_inode, target_direntry); | 1377 | target_dentry, toName); |
| 1333 | rc = cifs_do_rename(xid, source_direntry, fromName, | ||
| 1334 | target_direntry, toName); | ||
| 1335 | } | 1378 | } |
| 1336 | 1379 | ||
| 1337 | cifs_rename_exit: | 1380 | cifs_rename_exit: |
diff --git a/fs/cifs/readdir.c b/fs/cifs/readdir.c index 765adf12d54f..58d57299f2a0 100644 --- a/fs/cifs/readdir.c +++ b/fs/cifs/readdir.c | |||
| @@ -762,14 +762,15 @@ static int find_cifs_entry(const int xid, struct cifsTconInfo *pTcon, | |||
| 762 | rc)); | 762 | rc)); |
| 763 | return rc; | 763 | return rc; |
| 764 | } | 764 | } |
| 765 | cifs_save_resume_key(cifsFile->srch_inf.last_entry, cifsFile); | ||
| 765 | } | 766 | } |
| 766 | 767 | ||
| 767 | while ((index_to_find >= cifsFile->srch_inf.index_of_last_entry) && | 768 | while ((index_to_find >= cifsFile->srch_inf.index_of_last_entry) && |
| 768 | (rc == 0) && !cifsFile->srch_inf.endOfSearch) { | 769 | (rc == 0) && !cifsFile->srch_inf.endOfSearch) { |
| 769 | cFYI(1, ("calling findnext2")); | 770 | cFYI(1, ("calling findnext2")); |
| 770 | cifs_save_resume_key(cifsFile->srch_inf.last_entry, cifsFile); | ||
| 771 | rc = CIFSFindNext(xid, pTcon, cifsFile->netfid, | 771 | rc = CIFSFindNext(xid, pTcon, cifsFile->netfid, |
| 772 | &cifsFile->srch_inf); | 772 | &cifsFile->srch_inf); |
| 773 | cifs_save_resume_key(cifsFile->srch_inf.last_entry, cifsFile); | ||
| 773 | if (rc) | 774 | if (rc) |
| 774 | return -ENOENT; | 775 | return -ENOENT; |
| 775 | } | 776 | } |
diff --git a/fs/compat.c b/fs/compat.c index cb36245f9fe0..fe3c9bf87608 100644 --- a/fs/compat.c +++ b/fs/compat.c | |||
| @@ -1469,6 +1469,57 @@ out_ret: | |||
| 1469 | 1469 | ||
| 1470 | #define __COMPAT_NFDBITS (8 * sizeof(compat_ulong_t)) | 1470 | #define __COMPAT_NFDBITS (8 * sizeof(compat_ulong_t)) |
| 1471 | 1471 | ||
| 1472 | static int poll_select_copy_remaining(struct timespec *end_time, void __user *p, | ||
| 1473 | int timeval, int ret) | ||
| 1474 | { | ||
| 1475 | struct timespec ts; | ||
| 1476 | |||
| 1477 | if (!p) | ||
| 1478 | return ret; | ||
| 1479 | |||
| 1480 | if (current->personality & STICKY_TIMEOUTS) | ||
| 1481 | goto sticky; | ||
| 1482 | |||
| 1483 | /* No update for zero timeout */ | ||
| 1484 | if (!end_time->tv_sec && !end_time->tv_nsec) | ||
| 1485 | return ret; | ||
| 1486 | |||
| 1487 | ktime_get_ts(&ts); | ||
| 1488 | ts = timespec_sub(*end_time, ts); | ||
| 1489 | if (ts.tv_sec < 0) | ||
| 1490 | ts.tv_sec = ts.tv_nsec = 0; | ||
| 1491 | |||
| 1492 | if (timeval) { | ||
| 1493 | struct compat_timeval rtv; | ||
| 1494 | |||
| 1495 | rtv.tv_sec = ts.tv_sec; | ||
| 1496 | rtv.tv_usec = ts.tv_nsec / NSEC_PER_USEC; | ||
| 1497 | |||
| 1498 | if (!copy_to_user(p, &rtv, sizeof(rtv))) | ||
| 1499 | return ret; | ||
| 1500 | } else { | ||
| 1501 | struct compat_timespec rts; | ||
| 1502 | |||
| 1503 | rts.tv_sec = ts.tv_sec; | ||
| 1504 | rts.tv_nsec = ts.tv_nsec; | ||
| 1505 | |||
| 1506 | if (!copy_to_user(p, &rts, sizeof(rts))) | ||
| 1507 | return ret; | ||
| 1508 | } | ||
| 1509 | /* | ||
| 1510 | * If an application puts its timeval in read-only memory, we | ||
| 1511 | * don't want the Linux-specific update to the timeval to | ||
| 1512 | * cause a fault after the select has completed | ||
| 1513 | * successfully. However, because we're not updating the | ||
| 1514 | * timeval, we can't restart the system call. | ||
| 1515 | */ | ||
| 1516 | |||
| 1517 | sticky: | ||
| 1518 | if (ret == -ERESTARTNOHAND) | ||
| 1519 | ret = -EINTR; | ||
| 1520 | return ret; | ||
| 1521 | } | ||
| 1522 | |||
| 1472 | /* | 1523 | /* |
| 1473 | * Ooo, nasty. We need here to frob 32-bit unsigned longs to | 1524 | * Ooo, nasty. We need here to frob 32-bit unsigned longs to |
| 1474 | * 64-bit unsigned longs. | 1525 | * 64-bit unsigned longs. |
| @@ -1550,7 +1601,8 @@ int compat_set_fd_set(unsigned long nr, compat_ulong_t __user *ufdset, | |||
| 1550 | ((unsigned long) (MAX_SCHEDULE_TIMEOUT / HZ)-1) | 1601 | ((unsigned long) (MAX_SCHEDULE_TIMEOUT / HZ)-1) |
| 1551 | 1602 | ||
| 1552 | int compat_core_sys_select(int n, compat_ulong_t __user *inp, | 1603 | int compat_core_sys_select(int n, compat_ulong_t __user *inp, |
| 1553 | compat_ulong_t __user *outp, compat_ulong_t __user *exp, s64 *timeout) | 1604 | compat_ulong_t __user *outp, compat_ulong_t __user *exp, |
| 1605 | struct timespec *end_time) | ||
| 1554 | { | 1606 | { |
| 1555 | fd_set_bits fds; | 1607 | fd_set_bits fds; |
| 1556 | void *bits; | 1608 | void *bits; |
| @@ -1597,7 +1649,7 @@ int compat_core_sys_select(int n, compat_ulong_t __user *inp, | |||
| 1597 | zero_fd_set(n, fds.res_out); | 1649 | zero_fd_set(n, fds.res_out); |
| 1598 | zero_fd_set(n, fds.res_ex); | 1650 | zero_fd_set(n, fds.res_ex); |
| 1599 | 1651 | ||
| 1600 | ret = do_select(n, &fds, timeout); | 1652 | ret = do_select(n, &fds, end_time); |
| 1601 | 1653 | ||
| 1602 | if (ret < 0) | 1654 | if (ret < 0) |
| 1603 | goto out; | 1655 | goto out; |
| @@ -1623,7 +1675,7 @@ asmlinkage long compat_sys_select(int n, compat_ulong_t __user *inp, | |||
| 1623 | compat_ulong_t __user *outp, compat_ulong_t __user *exp, | 1675 | compat_ulong_t __user *outp, compat_ulong_t __user *exp, |
| 1624 | struct compat_timeval __user *tvp) | 1676 | struct compat_timeval __user *tvp) |
| 1625 | { | 1677 | { |
| 1626 | s64 timeout = -1; | 1678 | struct timespec end_time, *to = NULL; |
| 1627 | struct compat_timeval tv; | 1679 | struct compat_timeval tv; |
| 1628 | int ret; | 1680 | int ret; |
| 1629 | 1681 | ||
| @@ -1631,43 +1683,14 @@ asmlinkage long compat_sys_select(int n, compat_ulong_t __user *inp, | |||
| 1631 | if (copy_from_user(&tv, tvp, sizeof(tv))) | 1683 | if (copy_from_user(&tv, tvp, sizeof(tv))) |
| 1632 | return -EFAULT; | 1684 | return -EFAULT; |
| 1633 | 1685 | ||
| 1634 | if (tv.tv_sec < 0 || tv.tv_usec < 0) | 1686 | to = &end_time; |
| 1687 | if (poll_select_set_timeout(to, tv.tv_sec, | ||
| 1688 | tv.tv_usec * NSEC_PER_USEC)) | ||
| 1635 | return -EINVAL; | 1689 | return -EINVAL; |
| 1636 | |||
| 1637 | /* Cast to u64 to make GCC stop complaining */ | ||
| 1638 | if ((u64)tv.tv_sec >= (u64)MAX_INT64_SECONDS) | ||
| 1639 | timeout = -1; /* infinite */ | ||
| 1640 | else { | ||
| 1641 | timeout = DIV_ROUND_UP(tv.tv_usec, 1000000/HZ); | ||
| 1642 | timeout += tv.tv_sec * HZ; | ||
| 1643 | } | ||
| 1644 | } | 1690 | } |
| 1645 | 1691 | ||
| 1646 | ret = compat_core_sys_select(n, inp, outp, exp, &timeout); | 1692 | ret = compat_core_sys_select(n, inp, outp, exp, to); |
| 1647 | 1693 | ret = poll_select_copy_remaining(&end_time, tvp, 1, ret); | |
| 1648 | if (tvp) { | ||
| 1649 | struct compat_timeval rtv; | ||
| 1650 | |||
| 1651 | if (current->personality & STICKY_TIMEOUTS) | ||
| 1652 | goto sticky; | ||
| 1653 | rtv.tv_usec = jiffies_to_usecs(do_div((*(u64*)&timeout), HZ)); | ||
| 1654 | rtv.tv_sec = timeout; | ||
| 1655 | if (compat_timeval_compare(&rtv, &tv) >= 0) | ||
| 1656 | rtv = tv; | ||
| 1657 | if (copy_to_user(tvp, &rtv, sizeof(rtv))) { | ||
| 1658 | sticky: | ||
| 1659 | /* | ||
| 1660 | * If an application puts its timeval in read-only | ||
| 1661 | * memory, we don't want the Linux-specific update to | ||
| 1662 | * the timeval to cause a fault after the select has | ||
| 1663 | * completed successfully. However, because we're not | ||
| 1664 | * updating the timeval, we can't restart the system | ||
| 1665 | * call. | ||
| 1666 | */ | ||
| 1667 | if (ret == -ERESTARTNOHAND) | ||
| 1668 | ret = -EINTR; | ||
| 1669 | } | ||
| 1670 | } | ||
| 1671 | 1694 | ||
| 1672 | return ret; | 1695 | return ret; |
| 1673 | } | 1696 | } |
| @@ -1680,15 +1703,16 @@ asmlinkage long compat_sys_pselect7(int n, compat_ulong_t __user *inp, | |||
| 1680 | { | 1703 | { |
| 1681 | compat_sigset_t ss32; | 1704 | compat_sigset_t ss32; |
| 1682 | sigset_t ksigmask, sigsaved; | 1705 | sigset_t ksigmask, sigsaved; |
| 1683 | s64 timeout = MAX_SCHEDULE_TIMEOUT; | ||
| 1684 | struct compat_timespec ts; | 1706 | struct compat_timespec ts; |
| 1707 | struct timespec end_time, *to = NULL; | ||
| 1685 | int ret; | 1708 | int ret; |
| 1686 | 1709 | ||
| 1687 | if (tsp) { | 1710 | if (tsp) { |
| 1688 | if (copy_from_user(&ts, tsp, sizeof(ts))) | 1711 | if (copy_from_user(&ts, tsp, sizeof(ts))) |
| 1689 | return -EFAULT; | 1712 | return -EFAULT; |
| 1690 | 1713 | ||
| 1691 | if (ts.tv_sec < 0 || ts.tv_nsec < 0) | 1714 | to = &end_time; |
| 1715 | if (poll_select_set_timeout(to, ts.tv_sec, ts.tv_nsec)) | ||
| 1692 | return -EINVAL; | 1716 | return -EINVAL; |
| 1693 | } | 1717 | } |
| 1694 | 1718 | ||
| @@ -1703,51 +1727,8 @@ asmlinkage long compat_sys_pselect7(int n, compat_ulong_t __user *inp, | |||
| 1703 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); | 1727 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); |
| 1704 | } | 1728 | } |
| 1705 | 1729 | ||
| 1706 | do { | 1730 | ret = compat_core_sys_select(n, inp, outp, exp, to); |
| 1707 | if (tsp) { | 1731 | ret = poll_select_copy_remaining(&end_time, tsp, 0, ret); |
| 1708 | if ((unsigned long)ts.tv_sec < MAX_SELECT_SECONDS) { | ||
| 1709 | timeout = DIV_ROUND_UP(ts.tv_nsec, 1000000000/HZ); | ||
| 1710 | timeout += ts.tv_sec * (unsigned long)HZ; | ||
| 1711 | ts.tv_sec = 0; | ||
| 1712 | ts.tv_nsec = 0; | ||
| 1713 | } else { | ||
| 1714 | ts.tv_sec -= MAX_SELECT_SECONDS; | ||
| 1715 | timeout = MAX_SELECT_SECONDS * HZ; | ||
| 1716 | } | ||
| 1717 | } | ||
| 1718 | |||
| 1719 | ret = compat_core_sys_select(n, inp, outp, exp, &timeout); | ||
| 1720 | |||
| 1721 | } while (!ret && !timeout && tsp && (ts.tv_sec || ts.tv_nsec)); | ||
| 1722 | |||
| 1723 | if (tsp) { | ||
| 1724 | struct compat_timespec rts; | ||
| 1725 | |||
| 1726 | if (current->personality & STICKY_TIMEOUTS) | ||
| 1727 | goto sticky; | ||
| 1728 | |||
| 1729 | rts.tv_sec = timeout / HZ; | ||
| 1730 | rts.tv_nsec = (timeout % HZ) * (NSEC_PER_SEC/HZ); | ||
| 1731 | if (rts.tv_nsec >= NSEC_PER_SEC) { | ||
| 1732 | rts.tv_sec++; | ||
| 1733 | rts.tv_nsec -= NSEC_PER_SEC; | ||
| 1734 | } | ||
| 1735 | if (compat_timespec_compare(&rts, &ts) >= 0) | ||
| 1736 | rts = ts; | ||
| 1737 | if (copy_to_user(tsp, &rts, sizeof(rts))) { | ||
| 1738 | sticky: | ||
| 1739 | /* | ||
| 1740 | * If an application puts its timeval in read-only | ||
| 1741 | * memory, we don't want the Linux-specific update to | ||
| 1742 | * the timeval to cause a fault after the select has | ||
| 1743 | * completed successfully. However, because we're not | ||
| 1744 | * updating the timeval, we can't restart the system | ||
| 1745 | * call. | ||
| 1746 | */ | ||
| 1747 | if (ret == -ERESTARTNOHAND) | ||
| 1748 | ret = -EINTR; | ||
| 1749 | } | ||
| 1750 | } | ||
| 1751 | 1732 | ||
| 1752 | if (ret == -ERESTARTNOHAND) { | 1733 | if (ret == -ERESTARTNOHAND) { |
| 1753 | /* | 1734 | /* |
| @@ -1792,18 +1773,16 @@ asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds, | |||
| 1792 | compat_sigset_t ss32; | 1773 | compat_sigset_t ss32; |
| 1793 | sigset_t ksigmask, sigsaved; | 1774 | sigset_t ksigmask, sigsaved; |
| 1794 | struct compat_timespec ts; | 1775 | struct compat_timespec ts; |
| 1795 | s64 timeout = -1; | 1776 | struct timespec end_time, *to = NULL; |
| 1796 | int ret; | 1777 | int ret; |
| 1797 | 1778 | ||
| 1798 | if (tsp) { | 1779 | if (tsp) { |
| 1799 | if (copy_from_user(&ts, tsp, sizeof(ts))) | 1780 | if (copy_from_user(&ts, tsp, sizeof(ts))) |
| 1800 | return -EFAULT; | 1781 | return -EFAULT; |
| 1801 | 1782 | ||
| 1802 | /* We assume that ts.tv_sec is always lower than | 1783 | to = &end_time; |
| 1803 | the number of seconds that can be expressed in | 1784 | if (poll_select_set_timeout(to, ts.tv_sec, ts.tv_nsec)) |
| 1804 | an s64. Otherwise the compiler bitches at us */ | 1785 | return -EINVAL; |
| 1805 | timeout = DIV_ROUND_UP(ts.tv_nsec, 1000000000/HZ); | ||
| 1806 | timeout += ts.tv_sec * HZ; | ||
| 1807 | } | 1786 | } |
| 1808 | 1787 | ||
| 1809 | if (sigmask) { | 1788 | if (sigmask) { |
| @@ -1817,7 +1796,7 @@ asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds, | |||
| 1817 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); | 1796 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); |
| 1818 | } | 1797 | } |
| 1819 | 1798 | ||
| 1820 | ret = do_sys_poll(ufds, nfds, &timeout); | 1799 | ret = do_sys_poll(ufds, nfds, to); |
| 1821 | 1800 | ||
| 1822 | /* We can restart this syscall, usually */ | 1801 | /* We can restart this syscall, usually */ |
| 1823 | if (ret == -EINTR) { | 1802 | if (ret == -EINTR) { |
| @@ -1835,31 +1814,7 @@ asmlinkage long compat_sys_ppoll(struct pollfd __user *ufds, | |||
| 1835 | } else if (sigmask) | 1814 | } else if (sigmask) |
| 1836 | sigprocmask(SIG_SETMASK, &sigsaved, NULL); | 1815 | sigprocmask(SIG_SETMASK, &sigsaved, NULL); |
| 1837 | 1816 | ||
| 1838 | if (tsp && timeout >= 0) { | 1817 | ret = poll_select_copy_remaining(&end_time, tsp, 0, ret); |
| 1839 | struct compat_timespec rts; | ||
| 1840 | |||
| 1841 | if (current->personality & STICKY_TIMEOUTS) | ||
| 1842 | goto sticky; | ||
| 1843 | /* Yes, we know it's actually an s64, but it's also positive. */ | ||
| 1844 | rts.tv_nsec = jiffies_to_usecs(do_div((*(u64*)&timeout), HZ)) * | ||
| 1845 | 1000; | ||
| 1846 | rts.tv_sec = timeout; | ||
| 1847 | if (compat_timespec_compare(&rts, &ts) >= 0) | ||
| 1848 | rts = ts; | ||
| 1849 | if (copy_to_user(tsp, &rts, sizeof(rts))) { | ||
| 1850 | sticky: | ||
| 1851 | /* | ||
| 1852 | * If an application puts its timeval in read-only | ||
| 1853 | * memory, we don't want the Linux-specific update to | ||
| 1854 | * the timeval to cause a fault after the select has | ||
| 1855 | * completed successfully. However, because we're not | ||
| 1856 | * updating the timeval, we can't restart the system | ||
| 1857 | * call. | ||
| 1858 | */ | ||
| 1859 | if (ret == -ERESTARTNOHAND && timeout >= 0) | ||
| 1860 | ret = -EINTR; | ||
| 1861 | } | ||
| 1862 | } | ||
| 1863 | 1818 | ||
| 1864 | return ret; | 1819 | return ret; |
| 1865 | } | 1820 | } |
diff --git a/fs/ext3/super.c b/fs/ext3/super.c index 8147dd44cede..18eaa78ecb4e 100644 --- a/fs/ext3/super.c +++ b/fs/ext3/super.c | |||
| @@ -2836,7 +2836,7 @@ static int ext3_quota_on(struct super_block *sb, int type, int format_id, | |||
| 2836 | err = journal_flush(EXT3_SB(sb)->s_journal); | 2836 | err = journal_flush(EXT3_SB(sb)->s_journal); |
| 2837 | journal_unlock_updates(EXT3_SB(sb)->s_journal); | 2837 | journal_unlock_updates(EXT3_SB(sb)->s_journal); |
| 2838 | if (err) { | 2838 | if (err) { |
| 2839 | path_put(&nd.path); | 2839 | path_put(&path); |
| 2840 | return err; | 2840 | return err; |
| 2841 | } | 2841 | } |
| 2842 | } | 2842 | } |
diff --git a/fs/ext4/namei.c b/fs/ext4/namei.c index 5b93a7d94d42..63adcb792988 100644 --- a/fs/ext4/namei.c +++ b/fs/ext4/namei.c | |||
| @@ -1061,7 +1061,6 @@ static struct dentry *ext4_lookup(struct inode *dir, struct dentry *dentry, stru | |||
| 1061 | struct dentry *ext4_get_parent(struct dentry *child) | 1061 | struct dentry *ext4_get_parent(struct dentry *child) |
| 1062 | { | 1062 | { |
| 1063 | unsigned long ino; | 1063 | unsigned long ino; |
| 1064 | struct dentry *parent; | ||
| 1065 | struct inode *inode; | 1064 | struct inode *inode; |
| 1066 | static const struct qstr dotdot = { | 1065 | static const struct qstr dotdot = { |
| 1067 | .name = "..", | 1066 | .name = "..", |
diff --git a/fs/filesystems.c b/fs/filesystems.c index f37f87262837..d0e20ced62dd 100644 --- a/fs/filesystems.c +++ b/fs/filesystems.c | |||
| @@ -8,6 +8,8 @@ | |||
| 8 | 8 | ||
| 9 | #include <linux/syscalls.h> | 9 | #include <linux/syscalls.h> |
| 10 | #include <linux/fs.h> | 10 | #include <linux/fs.h> |
| 11 | #include <linux/proc_fs.h> | ||
| 12 | #include <linux/seq_file.h> | ||
| 11 | #include <linux/slab.h> | 13 | #include <linux/slab.h> |
| 12 | #include <linux/kmod.h> | 14 | #include <linux/kmod.h> |
| 13 | #include <linux/init.h> | 15 | #include <linux/init.h> |
| @@ -214,6 +216,43 @@ int get_filesystem_list(char * buf) | |||
| 214 | return len; | 216 | return len; |
| 215 | } | 217 | } |
| 216 | 218 | ||
| 219 | #ifdef CONFIG_PROC_FS | ||
| 220 | static int filesystems_proc_show(struct seq_file *m, void *v) | ||
| 221 | { | ||
| 222 | struct file_system_type * tmp; | ||
| 223 | |||
| 224 | read_lock(&file_systems_lock); | ||
| 225 | tmp = file_systems; | ||
| 226 | while (tmp) { | ||
| 227 | seq_printf(m, "%s\t%s\n", | ||
| 228 | (tmp->fs_flags & FS_REQUIRES_DEV) ? "" : "nodev", | ||
| 229 | tmp->name); | ||
| 230 | tmp = tmp->next; | ||
| 231 | } | ||
| 232 | read_unlock(&file_systems_lock); | ||
| 233 | return 0; | ||
| 234 | } | ||
| 235 | |||
| 236 | static int filesystems_proc_open(struct inode *inode, struct file *file) | ||
| 237 | { | ||
| 238 | return single_open(file, filesystems_proc_show, NULL); | ||
| 239 | } | ||
| 240 | |||
| 241 | static const struct file_operations filesystems_proc_fops = { | ||
| 242 | .open = filesystems_proc_open, | ||
| 243 | .read = seq_read, | ||
| 244 | .llseek = seq_lseek, | ||
| 245 | .release = single_release, | ||
| 246 | }; | ||
| 247 | |||
| 248 | static int __init proc_filesystems_init(void) | ||
| 249 | { | ||
| 250 | proc_create("filesystems", 0, NULL, &filesystems_proc_fops); | ||
| 251 | return 0; | ||
| 252 | } | ||
| 253 | module_init(proc_filesystems_init); | ||
| 254 | #endif | ||
| 255 | |||
| 217 | struct file_system_type *get_fs_type(const char *name) | 256 | struct file_system_type *get_fs_type(const char *name) |
| 218 | { | 257 | { |
| 219 | struct file_system_type *fs; | 258 | struct file_system_type *fs; |
diff --git a/fs/locks.c b/fs/locks.c index 20457486d6b2..09062e3ff104 100644 --- a/fs/locks.c +++ b/fs/locks.c | |||
| @@ -2079,6 +2079,7 @@ int vfs_cancel_lock(struct file *filp, struct file_lock *fl) | |||
| 2079 | EXPORT_SYMBOL_GPL(vfs_cancel_lock); | 2079 | EXPORT_SYMBOL_GPL(vfs_cancel_lock); |
| 2080 | 2080 | ||
| 2081 | #ifdef CONFIG_PROC_FS | 2081 | #ifdef CONFIG_PROC_FS |
| 2082 | #include <linux/proc_fs.h> | ||
| 2082 | #include <linux/seq_file.h> | 2083 | #include <linux/seq_file.h> |
| 2083 | 2084 | ||
| 2084 | static void lock_get_status(struct seq_file *f, struct file_lock *fl, | 2085 | static void lock_get_status(struct seq_file *f, struct file_lock *fl, |
| @@ -2184,12 +2185,31 @@ static void locks_stop(struct seq_file *f, void *v) | |||
| 2184 | unlock_kernel(); | 2185 | unlock_kernel(); |
| 2185 | } | 2186 | } |
| 2186 | 2187 | ||
| 2187 | struct seq_operations locks_seq_operations = { | 2188 | static const struct seq_operations locks_seq_operations = { |
| 2188 | .start = locks_start, | 2189 | .start = locks_start, |
| 2189 | .next = locks_next, | 2190 | .next = locks_next, |
| 2190 | .stop = locks_stop, | 2191 | .stop = locks_stop, |
| 2191 | .show = locks_show, | 2192 | .show = locks_show, |
| 2192 | }; | 2193 | }; |
| 2194 | |||
| 2195 | static int locks_open(struct inode *inode, struct file *filp) | ||
| 2196 | { | ||
| 2197 | return seq_open(filp, &locks_seq_operations); | ||
| 2198 | } | ||
| 2199 | |||
| 2200 | static const struct file_operations proc_locks_operations = { | ||
| 2201 | .open = locks_open, | ||
| 2202 | .read = seq_read, | ||
| 2203 | .llseek = seq_lseek, | ||
| 2204 | .release = seq_release, | ||
| 2205 | }; | ||
| 2206 | |||
| 2207 | static int __init proc_locks_init(void) | ||
| 2208 | { | ||
| 2209 | proc_create("locks", 0, NULL, &proc_locks_operations); | ||
| 2210 | return 0; | ||
| 2211 | } | ||
| 2212 | module_init(proc_locks_init); | ||
| 2193 | #endif | 2213 | #endif |
| 2194 | 2214 | ||
| 2195 | /** | 2215 | /** |
diff --git a/fs/proc/Makefile b/fs/proc/Makefile index ebaba0213546..63d965193b22 100644 --- a/fs/proc/Makefile +++ b/fs/proc/Makefile | |||
| @@ -8,11 +8,20 @@ proc-y := nommu.o task_nommu.o | |||
| 8 | proc-$(CONFIG_MMU) := mmu.o task_mmu.o | 8 | proc-$(CONFIG_MMU) := mmu.o task_mmu.o |
| 9 | 9 | ||
| 10 | proc-y += inode.o root.o base.o generic.o array.o \ | 10 | proc-y += inode.o root.o base.o generic.o array.o \ |
| 11 | proc_tty.o proc_misc.o | 11 | proc_tty.o |
| 12 | 12 | proc-y += cmdline.o | |
| 13 | proc-y += cpuinfo.o | ||
| 14 | proc-y += devices.o | ||
| 15 | proc-y += interrupts.o | ||
| 16 | proc-y += loadavg.o | ||
| 17 | proc-y += meminfo.o | ||
| 18 | proc-y += stat.o | ||
| 19 | proc-y += uptime.o | ||
| 20 | proc-y += version.o | ||
| 13 | proc-$(CONFIG_PROC_SYSCTL) += proc_sysctl.o | 21 | proc-$(CONFIG_PROC_SYSCTL) += proc_sysctl.o |
| 14 | proc-$(CONFIG_NET) += proc_net.o | 22 | proc-$(CONFIG_NET) += proc_net.o |
| 15 | proc-$(CONFIG_PROC_KCORE) += kcore.o | 23 | proc-$(CONFIG_PROC_KCORE) += kcore.o |
| 16 | proc-$(CONFIG_PROC_VMCORE) += vmcore.o | 24 | proc-$(CONFIG_PROC_VMCORE) += vmcore.o |
| 17 | proc-$(CONFIG_PROC_DEVICETREE) += proc_devtree.o | 25 | proc-$(CONFIG_PROC_DEVICETREE) += proc_devtree.o |
| 18 | proc-$(CONFIG_PRINTK) += kmsg.o | 26 | proc-$(CONFIG_PRINTK) += kmsg.o |
| 27 | proc-$(CONFIG_PROC_PAGE_MONITOR) += page.o | ||
diff --git a/fs/proc/cmdline.c b/fs/proc/cmdline.c new file mode 100644 index 000000000000..82676e3fcd1d --- /dev/null +++ b/fs/proc/cmdline.c | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/proc_fs.h> | ||
| 4 | #include <linux/seq_file.h> | ||
| 5 | |||
| 6 | static int cmdline_proc_show(struct seq_file *m, void *v) | ||
| 7 | { | ||
| 8 | seq_printf(m, "%s\n", saved_command_line); | ||
| 9 | return 0; | ||
| 10 | } | ||
| 11 | |||
| 12 | static int cmdline_proc_open(struct inode *inode, struct file *file) | ||
| 13 | { | ||
| 14 | return single_open(file, cmdline_proc_show, NULL); | ||
| 15 | } | ||
| 16 | |||
| 17 | static const struct file_operations cmdline_proc_fops = { | ||
| 18 | .open = cmdline_proc_open, | ||
| 19 | .read = seq_read, | ||
| 20 | .llseek = seq_lseek, | ||
| 21 | .release = single_release, | ||
| 22 | }; | ||
| 23 | |||
| 24 | static int __init proc_cmdline_init(void) | ||
| 25 | { | ||
| 26 | proc_create("cmdline", 0, NULL, &cmdline_proc_fops); | ||
| 27 | return 0; | ||
| 28 | } | ||
| 29 | module_init(proc_cmdline_init); | ||
diff --git a/fs/proc/cpuinfo.c b/fs/proc/cpuinfo.c new file mode 100644 index 000000000000..5a1e539a234b --- /dev/null +++ b/fs/proc/cpuinfo.c | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/proc_fs.h> | ||
| 4 | #include <linux/seq_file.h> | ||
| 5 | |||
| 6 | extern const struct seq_operations cpuinfo_op; | ||
| 7 | static int cpuinfo_open(struct inode *inode, struct file *file) | ||
| 8 | { | ||
| 9 | return seq_open(file, &cpuinfo_op); | ||
| 10 | } | ||
| 11 | |||
| 12 | static const struct file_operations proc_cpuinfo_operations = { | ||
| 13 | .open = cpuinfo_open, | ||
| 14 | .read = seq_read, | ||
| 15 | .llseek = seq_lseek, | ||
| 16 | .release = seq_release, | ||
| 17 | }; | ||
| 18 | |||
| 19 | static int __init proc_cpuinfo_init(void) | ||
| 20 | { | ||
| 21 | proc_create("cpuinfo", 0, NULL, &proc_cpuinfo_operations); | ||
| 22 | return 0; | ||
| 23 | } | ||
| 24 | module_init(proc_cpuinfo_init); | ||
diff --git a/fs/proc/devices.c b/fs/proc/devices.c new file mode 100644 index 000000000000..59ee7da959c9 --- /dev/null +++ b/fs/proc/devices.c | |||
| @@ -0,0 +1,70 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/proc_fs.h> | ||
| 4 | #include <linux/seq_file.h> | ||
| 5 | |||
| 6 | static int devinfo_show(struct seq_file *f, void *v) | ||
| 7 | { | ||
| 8 | int i = *(loff_t *) v; | ||
| 9 | |||
| 10 | if (i < CHRDEV_MAJOR_HASH_SIZE) { | ||
| 11 | if (i == 0) | ||
| 12 | seq_printf(f, "Character devices:\n"); | ||
| 13 | chrdev_show(f, i); | ||
| 14 | } | ||
| 15 | #ifdef CONFIG_BLOCK | ||
| 16 | else { | ||
| 17 | i -= CHRDEV_MAJOR_HASH_SIZE; | ||
| 18 | if (i == 0) | ||
| 19 | seq_printf(f, "\nBlock devices:\n"); | ||
| 20 | blkdev_show(f, i); | ||
| 21 | } | ||
| 22 | #endif | ||
| 23 | return 0; | ||
| 24 | } | ||
| 25 | |||
| 26 | static void *devinfo_start(struct seq_file *f, loff_t *pos) | ||
| 27 | { | ||
| 28 | if (*pos < (BLKDEV_MAJOR_HASH_SIZE + CHRDEV_MAJOR_HASH_SIZE)) | ||
| 29 | return pos; | ||
| 30 | return NULL; | ||
| 31 | } | ||
| 32 | |||
| 33 | static void *devinfo_next(struct seq_file *f, void *v, loff_t *pos) | ||
| 34 | { | ||
| 35 | (*pos)++; | ||
| 36 | if (*pos >= (BLKDEV_MAJOR_HASH_SIZE + CHRDEV_MAJOR_HASH_SIZE)) | ||
| 37 | return NULL; | ||
| 38 | return pos; | ||
| 39 | } | ||
| 40 | |||
| 41 | static void devinfo_stop(struct seq_file *f, void *v) | ||
| 42 | { | ||
| 43 | /* Nothing to do */ | ||
| 44 | } | ||
| 45 | |||
| 46 | static const struct seq_operations devinfo_ops = { | ||
| 47 | .start = devinfo_start, | ||
| 48 | .next = devinfo_next, | ||
| 49 | .stop = devinfo_stop, | ||
| 50 | .show = devinfo_show | ||
| 51 | }; | ||
| 52 | |||
| 53 | static int devinfo_open(struct inode *inode, struct file *filp) | ||
| 54 | { | ||
| 55 | return seq_open(filp, &devinfo_ops); | ||
| 56 | } | ||
| 57 | |||
| 58 | static const struct file_operations proc_devinfo_operations = { | ||
| 59 | .open = devinfo_open, | ||
| 60 | .read = seq_read, | ||
| 61 | .llseek = seq_lseek, | ||
| 62 | .release = seq_release, | ||
| 63 | }; | ||
| 64 | |||
| 65 | static int __init proc_devices_init(void) | ||
| 66 | { | ||
| 67 | proc_create("devices", 0, NULL, &proc_devinfo_operations); | ||
| 68 | return 0; | ||
| 69 | } | ||
| 70 | module_init(proc_devices_init); | ||
diff --git a/fs/proc/generic.c b/fs/proc/generic.c index 7821589a17d5..60a359b35582 100644 --- a/fs/proc/generic.c +++ b/fs/proc/generic.c | |||
| @@ -547,9 +547,8 @@ static int proc_register(struct proc_dir_entry * dir, struct proc_dir_entry * dp | |||
| 547 | 547 | ||
| 548 | for (tmp = dir->subdir; tmp; tmp = tmp->next) | 548 | for (tmp = dir->subdir; tmp; tmp = tmp->next) |
| 549 | if (strcmp(tmp->name, dp->name) == 0) { | 549 | if (strcmp(tmp->name, dp->name) == 0) { |
| 550 | printk(KERN_WARNING "proc_dir_entry '%s/%s' already registered\n", | 550 | WARN(1, KERN_WARNING "proc_dir_entry '%s/%s' already registered\n", |
| 551 | dir->name, dp->name); | 551 | dir->name, dp->name); |
| 552 | dump_stack(); | ||
| 553 | break; | 552 | break; |
| 554 | } | 553 | } |
| 555 | 554 | ||
diff --git a/fs/proc/inode.c b/fs/proc/inode.c index c6b4fa7e3b49..2543fd00c658 100644 --- a/fs/proc/inode.c +++ b/fs/proc/inode.c | |||
| @@ -106,14 +106,13 @@ static void init_once(void *foo) | |||
| 106 | inode_init_once(&ei->vfs_inode); | 106 | inode_init_once(&ei->vfs_inode); |
| 107 | } | 107 | } |
| 108 | 108 | ||
| 109 | int __init proc_init_inodecache(void) | 109 | void __init proc_init_inodecache(void) |
| 110 | { | 110 | { |
| 111 | proc_inode_cachep = kmem_cache_create("proc_inode_cache", | 111 | proc_inode_cachep = kmem_cache_create("proc_inode_cache", |
| 112 | sizeof(struct proc_inode), | 112 | sizeof(struct proc_inode), |
| 113 | 0, (SLAB_RECLAIM_ACCOUNT| | 113 | 0, (SLAB_RECLAIM_ACCOUNT| |
| 114 | SLAB_MEM_SPREAD|SLAB_PANIC), | 114 | SLAB_MEM_SPREAD|SLAB_PANIC), |
| 115 | init_once); | 115 | init_once); |
| 116 | return 0; | ||
| 117 | } | 116 | } |
| 118 | 117 | ||
| 119 | static const struct super_operations proc_sops = { | 118 | static const struct super_operations proc_sops = { |
diff --git a/fs/proc/internal.h b/fs/proc/internal.h index 3bfb7b8747b3..3e8aeb8b61ce 100644 --- a/fs/proc/internal.h +++ b/fs/proc/internal.h | |||
| @@ -61,12 +61,11 @@ extern const struct file_operations proc_smaps_operations; | |||
| 61 | extern const struct file_operations proc_clear_refs_operations; | 61 | extern const struct file_operations proc_clear_refs_operations; |
| 62 | extern const struct file_operations proc_pagemap_operations; | 62 | extern const struct file_operations proc_pagemap_operations; |
| 63 | extern const struct file_operations proc_net_operations; | 63 | extern const struct file_operations proc_net_operations; |
| 64 | extern const struct file_operations proc_kmsg_operations; | ||
| 65 | extern const struct inode_operations proc_net_inode_operations; | 64 | extern const struct inode_operations proc_net_inode_operations; |
| 66 | 65 | ||
| 67 | void free_proc_entry(struct proc_dir_entry *de); | 66 | void free_proc_entry(struct proc_dir_entry *de); |
| 68 | 67 | ||
| 69 | int proc_init_inodecache(void); | 68 | void proc_init_inodecache(void); |
| 70 | 69 | ||
| 71 | static inline struct pid *proc_pid(struct inode *inode) | 70 | static inline struct pid *proc_pid(struct inode *inode) |
| 72 | { | 71 | { |
diff --git a/fs/proc/interrupts.c b/fs/proc/interrupts.c new file mode 100644 index 000000000000..05029c0e2f24 --- /dev/null +++ b/fs/proc/interrupts.c | |||
| @@ -0,0 +1,53 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/interrupt.h> | ||
| 4 | #include <linux/irqnr.h> | ||
| 5 | #include <linux/proc_fs.h> | ||
| 6 | #include <linux/seq_file.h> | ||
| 7 | |||
| 8 | /* | ||
| 9 | * /proc/interrupts | ||
| 10 | */ | ||
| 11 | static void *int_seq_start(struct seq_file *f, loff_t *pos) | ||
| 12 | { | ||
| 13 | return (*pos <= nr_irqs) ? pos : NULL; | ||
| 14 | } | ||
| 15 | |||
| 16 | static void *int_seq_next(struct seq_file *f, void *v, loff_t *pos) | ||
| 17 | { | ||
| 18 | (*pos)++; | ||
| 19 | if (*pos > nr_irqs) | ||
| 20 | return NULL; | ||
| 21 | return pos; | ||
| 22 | } | ||
| 23 | |||
| 24 | static void int_seq_stop(struct seq_file *f, void *v) | ||
| 25 | { | ||
| 26 | /* Nothing to do */ | ||
| 27 | } | ||
| 28 | |||
| 29 | static const struct seq_operations int_seq_ops = { | ||
| 30 | .start = int_seq_start, | ||
| 31 | .next = int_seq_next, | ||
| 32 | .stop = int_seq_stop, | ||
| 33 | .show = show_interrupts | ||
| 34 | }; | ||
| 35 | |||
| 36 | static int interrupts_open(struct inode *inode, struct file *filp) | ||
| 37 | { | ||
| 38 | return seq_open(filp, &int_seq_ops); | ||
| 39 | } | ||
| 40 | |||
| 41 | static const struct file_operations proc_interrupts_operations = { | ||
| 42 | .open = interrupts_open, | ||
| 43 | .read = seq_read, | ||
| 44 | .llseek = seq_lseek, | ||
| 45 | .release = seq_release, | ||
| 46 | }; | ||
| 47 | |||
| 48 | static int __init proc_interrupts_init(void) | ||
| 49 | { | ||
| 50 | proc_create("interrupts", 0, NULL, &proc_interrupts_operations); | ||
| 51 | return 0; | ||
| 52 | } | ||
| 53 | module_init(proc_interrupts_init); | ||
diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c index c2370c76fb71..59b43a068872 100644 --- a/fs/proc/kcore.c +++ b/fs/proc/kcore.c | |||
| @@ -27,6 +27,8 @@ | |||
| 27 | #define ELF_CORE_EFLAGS 0 | 27 | #define ELF_CORE_EFLAGS 0 |
| 28 | #endif | 28 | #endif |
| 29 | 29 | ||
| 30 | static struct proc_dir_entry *proc_root_kcore; | ||
| 31 | |||
| 30 | static int open_kcore(struct inode * inode, struct file * filp) | 32 | static int open_kcore(struct inode * inode, struct file * filp) |
| 31 | { | 33 | { |
| 32 | return capable(CAP_SYS_RAWIO) ? 0 : -EPERM; | 34 | return capable(CAP_SYS_RAWIO) ? 0 : -EPERM; |
| @@ -34,7 +36,7 @@ static int open_kcore(struct inode * inode, struct file * filp) | |||
| 34 | 36 | ||
| 35 | static ssize_t read_kcore(struct file *, char __user *, size_t, loff_t *); | 37 | static ssize_t read_kcore(struct file *, char __user *, size_t, loff_t *); |
| 36 | 38 | ||
| 37 | const struct file_operations proc_kcore_operations = { | 39 | static const struct file_operations proc_kcore_operations = { |
| 38 | .read = read_kcore, | 40 | .read = read_kcore, |
| 39 | .open = open_kcore, | 41 | .open = open_kcore, |
| 40 | }; | 42 | }; |
| @@ -399,3 +401,13 @@ read_kcore(struct file *file, char __user *buffer, size_t buflen, loff_t *fpos) | |||
| 399 | 401 | ||
| 400 | return acc; | 402 | return acc; |
| 401 | } | 403 | } |
| 404 | |||
| 405 | static int __init proc_kcore_init(void) | ||
| 406 | { | ||
| 407 | proc_root_kcore = proc_create("kcore", S_IRUSR, NULL, &proc_kcore_operations); | ||
| 408 | if (proc_root_kcore) | ||
| 409 | proc_root_kcore->size = | ||
| 410 | (size_t)high_memory - PAGE_OFFSET + PAGE_SIZE; | ||
| 411 | return 0; | ||
| 412 | } | ||
| 413 | module_init(proc_kcore_init); | ||
diff --git a/fs/proc/kmsg.c b/fs/proc/kmsg.c index 9fd5df3f40ce..7ca78346d3f0 100644 --- a/fs/proc/kmsg.c +++ b/fs/proc/kmsg.c | |||
| @@ -10,13 +10,12 @@ | |||
| 10 | #include <linux/time.h> | 10 | #include <linux/time.h> |
| 11 | #include <linux/kernel.h> | 11 | #include <linux/kernel.h> |
| 12 | #include <linux/poll.h> | 12 | #include <linux/poll.h> |
| 13 | #include <linux/proc_fs.h> | ||
| 13 | #include <linux/fs.h> | 14 | #include <linux/fs.h> |
| 14 | 15 | ||
| 15 | #include <asm/uaccess.h> | 16 | #include <asm/uaccess.h> |
| 16 | #include <asm/io.h> | 17 | #include <asm/io.h> |
| 17 | 18 | ||
| 18 | #include "internal.h" | ||
| 19 | |||
| 20 | extern wait_queue_head_t log_wait; | 19 | extern wait_queue_head_t log_wait; |
| 21 | 20 | ||
| 22 | extern int do_syslog(int type, char __user *bug, int count); | 21 | extern int do_syslog(int type, char __user *bug, int count); |
| @@ -49,9 +48,16 @@ static unsigned int kmsg_poll(struct file *file, poll_table *wait) | |||
| 49 | } | 48 | } |
| 50 | 49 | ||
| 51 | 50 | ||
| 52 | const struct file_operations proc_kmsg_operations = { | 51 | static const struct file_operations proc_kmsg_operations = { |
| 53 | .read = kmsg_read, | 52 | .read = kmsg_read, |
| 54 | .poll = kmsg_poll, | 53 | .poll = kmsg_poll, |
| 55 | .open = kmsg_open, | 54 | .open = kmsg_open, |
| 56 | .release = kmsg_release, | 55 | .release = kmsg_release, |
| 57 | }; | 56 | }; |
| 57 | |||
| 58 | static int __init proc_kmsg_init(void) | ||
| 59 | { | ||
| 60 | proc_create("kmsg", S_IRUSR, NULL, &proc_kmsg_operations); | ||
| 61 | return 0; | ||
| 62 | } | ||
| 63 | module_init(proc_kmsg_init); | ||
diff --git a/fs/proc/loadavg.c b/fs/proc/loadavg.c new file mode 100644 index 000000000000..9bca39cf99ee --- /dev/null +++ b/fs/proc/loadavg.c | |||
| @@ -0,0 +1,51 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/pid_namespace.h> | ||
| 4 | #include <linux/proc_fs.h> | ||
| 5 | #include <linux/sched.h> | ||
| 6 | #include <linux/seq_file.h> | ||
| 7 | #include <linux/seqlock.h> | ||
| 8 | #include <linux/time.h> | ||
| 9 | |||
| 10 | #define LOAD_INT(x) ((x) >> FSHIFT) | ||
| 11 | #define LOAD_FRAC(x) LOAD_INT(((x) & (FIXED_1-1)) * 100) | ||
| 12 | |||
| 13 | static int loadavg_proc_show(struct seq_file *m, void *v) | ||
| 14 | { | ||
| 15 | int a, b, c; | ||
| 16 | unsigned long seq; | ||
| 17 | |||
| 18 | do { | ||
| 19 | seq = read_seqbegin(&xtime_lock); | ||
| 20 | a = avenrun[0] + (FIXED_1/200); | ||
| 21 | b = avenrun[1] + (FIXED_1/200); | ||
| 22 | c = avenrun[2] + (FIXED_1/200); | ||
| 23 | } while (read_seqretry(&xtime_lock, seq)); | ||
| 24 | |||
| 25 | seq_printf(m, "%d.%02d %d.%02d %d.%02d %ld/%d %d\n", | ||
| 26 | LOAD_INT(a), LOAD_FRAC(a), | ||
| 27 | LOAD_INT(b), LOAD_FRAC(b), | ||
| 28 | LOAD_INT(c), LOAD_FRAC(c), | ||
| 29 | nr_running(), nr_threads, | ||
| 30 | task_active_pid_ns(current)->last_pid); | ||
| 31 | return 0; | ||
| 32 | } | ||
| 33 | |||
| 34 | static int loadavg_proc_open(struct inode *inode, struct file *file) | ||
| 35 | { | ||
| 36 | return single_open(file, loadavg_proc_show, NULL); | ||
| 37 | } | ||
| 38 | |||
| 39 | static const struct file_operations loadavg_proc_fops = { | ||
| 40 | .open = loadavg_proc_open, | ||
| 41 | .read = seq_read, | ||
| 42 | .llseek = seq_lseek, | ||
| 43 | .release = single_release, | ||
| 44 | }; | ||
| 45 | |||
| 46 | static int __init proc_loadavg_init(void) | ||
| 47 | { | ||
| 48 | proc_create("loadavg", 0, NULL, &loadavg_proc_fops); | ||
| 49 | return 0; | ||
| 50 | } | ||
| 51 | module_init(proc_loadavg_init); | ||
diff --git a/fs/proc/meminfo.c b/fs/proc/meminfo.c new file mode 100644 index 000000000000..b1675c4e66da --- /dev/null +++ b/fs/proc/meminfo.c | |||
| @@ -0,0 +1,168 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/hugetlb.h> | ||
| 3 | #include <linux/init.h> | ||
| 4 | #include <linux/kernel.h> | ||
| 5 | #include <linux/mm.h> | ||
| 6 | #include <linux/mman.h> | ||
| 7 | #include <linux/mmzone.h> | ||
| 8 | #include <linux/proc_fs.h> | ||
| 9 | #include <linux/quicklist.h> | ||
| 10 | #include <linux/seq_file.h> | ||
| 11 | #include <linux/swap.h> | ||
| 12 | #include <linux/vmstat.h> | ||
| 13 | #include <asm/atomic.h> | ||
| 14 | #include <asm/page.h> | ||
| 15 | #include <asm/pgtable.h> | ||
| 16 | #include "internal.h" | ||
| 17 | |||
| 18 | void __attribute__((weak)) arch_report_meminfo(struct seq_file *m) | ||
| 19 | { | ||
| 20 | } | ||
| 21 | |||
| 22 | static int meminfo_proc_show(struct seq_file *m, void *v) | ||
| 23 | { | ||
| 24 | struct sysinfo i; | ||
| 25 | unsigned long committed; | ||
| 26 | unsigned long allowed; | ||
| 27 | struct vmalloc_info vmi; | ||
| 28 | long cached; | ||
| 29 | unsigned long pages[NR_LRU_LISTS]; | ||
| 30 | int lru; | ||
| 31 | |||
| 32 | /* | ||
| 33 | * display in kilobytes. | ||
| 34 | */ | ||
| 35 | #define K(x) ((x) << (PAGE_SHIFT - 10)) | ||
| 36 | si_meminfo(&i); | ||
| 37 | si_swapinfo(&i); | ||
| 38 | committed = atomic_long_read(&vm_committed_space); | ||
| 39 | allowed = ((totalram_pages - hugetlb_total_pages()) | ||
| 40 | * sysctl_overcommit_ratio / 100) + total_swap_pages; | ||
| 41 | |||
| 42 | cached = global_page_state(NR_FILE_PAGES) - | ||
| 43 | total_swapcache_pages - i.bufferram; | ||
| 44 | if (cached < 0) | ||
| 45 | cached = 0; | ||
| 46 | |||
| 47 | get_vmalloc_info(&vmi); | ||
| 48 | |||
| 49 | for (lru = LRU_BASE; lru < NR_LRU_LISTS; lru++) | ||
| 50 | pages[lru] = global_page_state(NR_LRU_BASE + lru); | ||
| 51 | |||
| 52 | /* | ||
| 53 | * Tagged format, for easy grepping and expansion. | ||
| 54 | */ | ||
| 55 | seq_printf(m, | ||
| 56 | "MemTotal: %8lu kB\n" | ||
| 57 | "MemFree: %8lu kB\n" | ||
| 58 | "Buffers: %8lu kB\n" | ||
| 59 | "Cached: %8lu kB\n" | ||
| 60 | "SwapCached: %8lu kB\n" | ||
| 61 | "Active: %8lu kB\n" | ||
| 62 | "Inactive: %8lu kB\n" | ||
| 63 | "Active(anon): %8lu kB\n" | ||
| 64 | "Inactive(anon): %8lu kB\n" | ||
| 65 | "Active(file): %8lu kB\n" | ||
| 66 | "Inactive(file): %8lu kB\n" | ||
| 67 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
| 68 | "Unevictable: %8lu kB\n" | ||
| 69 | "Mlocked: %8lu kB\n" | ||
| 70 | #endif | ||
| 71 | #ifdef CONFIG_HIGHMEM | ||
| 72 | "HighTotal: %8lu kB\n" | ||
| 73 | "HighFree: %8lu kB\n" | ||
| 74 | "LowTotal: %8lu kB\n" | ||
| 75 | "LowFree: %8lu kB\n" | ||
| 76 | #endif | ||
| 77 | "SwapTotal: %8lu kB\n" | ||
| 78 | "SwapFree: %8lu kB\n" | ||
| 79 | "Dirty: %8lu kB\n" | ||
| 80 | "Writeback: %8lu kB\n" | ||
| 81 | "AnonPages: %8lu kB\n" | ||
| 82 | "Mapped: %8lu kB\n" | ||
| 83 | "Slab: %8lu kB\n" | ||
| 84 | "SReclaimable: %8lu kB\n" | ||
| 85 | "SUnreclaim: %8lu kB\n" | ||
| 86 | "PageTables: %8lu kB\n" | ||
| 87 | #ifdef CONFIG_QUICKLIST | ||
| 88 | "Quicklists: %8lu kB\n" | ||
| 89 | #endif | ||
| 90 | "NFS_Unstable: %8lu kB\n" | ||
| 91 | "Bounce: %8lu kB\n" | ||
| 92 | "WritebackTmp: %8lu kB\n" | ||
| 93 | "CommitLimit: %8lu kB\n" | ||
| 94 | "Committed_AS: %8lu kB\n" | ||
| 95 | "VmallocTotal: %8lu kB\n" | ||
| 96 | "VmallocUsed: %8lu kB\n" | ||
| 97 | "VmallocChunk: %8lu kB\n", | ||
| 98 | K(i.totalram), | ||
| 99 | K(i.freeram), | ||
| 100 | K(i.bufferram), | ||
| 101 | K(cached), | ||
| 102 | K(total_swapcache_pages), | ||
| 103 | K(pages[LRU_ACTIVE_ANON] + pages[LRU_ACTIVE_FILE]), | ||
| 104 | K(pages[LRU_INACTIVE_ANON] + pages[LRU_INACTIVE_FILE]), | ||
| 105 | K(pages[LRU_ACTIVE_ANON]), | ||
| 106 | K(pages[LRU_INACTIVE_ANON]), | ||
| 107 | K(pages[LRU_ACTIVE_FILE]), | ||
| 108 | K(pages[LRU_INACTIVE_FILE]), | ||
| 109 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
| 110 | K(pages[LRU_UNEVICTABLE]), | ||
| 111 | K(global_page_state(NR_MLOCK)), | ||
| 112 | #endif | ||
| 113 | #ifdef CONFIG_HIGHMEM | ||
| 114 | K(i.totalhigh), | ||
| 115 | K(i.freehigh), | ||
| 116 | K(i.totalram-i.totalhigh), | ||
| 117 | K(i.freeram-i.freehigh), | ||
| 118 | #endif | ||
| 119 | K(i.totalswap), | ||
| 120 | K(i.freeswap), | ||
| 121 | K(global_page_state(NR_FILE_DIRTY)), | ||
| 122 | K(global_page_state(NR_WRITEBACK)), | ||
| 123 | K(global_page_state(NR_ANON_PAGES)), | ||
| 124 | K(global_page_state(NR_FILE_MAPPED)), | ||
| 125 | K(global_page_state(NR_SLAB_RECLAIMABLE) + | ||
| 126 | global_page_state(NR_SLAB_UNRECLAIMABLE)), | ||
| 127 | K(global_page_state(NR_SLAB_RECLAIMABLE)), | ||
| 128 | K(global_page_state(NR_SLAB_UNRECLAIMABLE)), | ||
| 129 | K(global_page_state(NR_PAGETABLE)), | ||
| 130 | #ifdef CONFIG_QUICKLIST | ||
| 131 | K(quicklist_total_size()), | ||
| 132 | #endif | ||
| 133 | K(global_page_state(NR_UNSTABLE_NFS)), | ||
| 134 | K(global_page_state(NR_BOUNCE)), | ||
| 135 | K(global_page_state(NR_WRITEBACK_TEMP)), | ||
| 136 | K(allowed), | ||
| 137 | K(committed), | ||
| 138 | (unsigned long)VMALLOC_TOTAL >> 10, | ||
| 139 | vmi.used >> 10, | ||
| 140 | vmi.largest_chunk >> 10 | ||
| 141 | ); | ||
| 142 | |||
| 143 | hugetlb_report_meminfo(m); | ||
| 144 | |||
| 145 | arch_report_meminfo(m); | ||
| 146 | |||
| 147 | return 0; | ||
| 148 | #undef K | ||
| 149 | } | ||
| 150 | |||
| 151 | static int meminfo_proc_open(struct inode *inode, struct file *file) | ||
| 152 | { | ||
| 153 | return single_open(file, meminfo_proc_show, NULL); | ||
| 154 | } | ||
| 155 | |||
| 156 | static const struct file_operations meminfo_proc_fops = { | ||
| 157 | .open = meminfo_proc_open, | ||
| 158 | .read = seq_read, | ||
| 159 | .llseek = seq_lseek, | ||
| 160 | .release = single_release, | ||
| 161 | }; | ||
| 162 | |||
| 163 | static int __init proc_meminfo_init(void) | ||
| 164 | { | ||
| 165 | proc_create("meminfo", 0, NULL, &meminfo_proc_fops); | ||
| 166 | return 0; | ||
| 167 | } | ||
| 168 | module_init(proc_meminfo_init); | ||
diff --git a/fs/proc/page.c b/fs/proc/page.c new file mode 100644 index 000000000000..767d95a6d1b1 --- /dev/null +++ b/fs/proc/page.c | |||
| @@ -0,0 +1,147 @@ | |||
| 1 | #include <linux/bootmem.h> | ||
| 2 | #include <linux/compiler.h> | ||
| 3 | #include <linux/fs.h> | ||
| 4 | #include <linux/init.h> | ||
| 5 | #include <linux/mm.h> | ||
| 6 | #include <linux/mmzone.h> | ||
| 7 | #include <linux/proc_fs.h> | ||
| 8 | #include <linux/seq_file.h> | ||
| 9 | #include <asm/uaccess.h> | ||
| 10 | #include "internal.h" | ||
| 11 | |||
| 12 | #define KPMSIZE sizeof(u64) | ||
| 13 | #define KPMMASK (KPMSIZE - 1) | ||
| 14 | /* /proc/kpagecount - an array exposing page counts | ||
| 15 | * | ||
| 16 | * Each entry is a u64 representing the corresponding | ||
| 17 | * physical page count. | ||
| 18 | */ | ||
| 19 | static ssize_t kpagecount_read(struct file *file, char __user *buf, | ||
| 20 | size_t count, loff_t *ppos) | ||
| 21 | { | ||
| 22 | u64 __user *out = (u64 __user *)buf; | ||
| 23 | struct page *ppage; | ||
| 24 | unsigned long src = *ppos; | ||
| 25 | unsigned long pfn; | ||
| 26 | ssize_t ret = 0; | ||
| 27 | u64 pcount; | ||
| 28 | |||
| 29 | pfn = src / KPMSIZE; | ||
| 30 | count = min_t(size_t, count, (max_pfn * KPMSIZE) - src); | ||
| 31 | if (src & KPMMASK || count & KPMMASK) | ||
| 32 | return -EINVAL; | ||
| 33 | |||
| 34 | while (count > 0) { | ||
| 35 | ppage = NULL; | ||
| 36 | if (pfn_valid(pfn)) | ||
| 37 | ppage = pfn_to_page(pfn); | ||
| 38 | pfn++; | ||
| 39 | if (!ppage) | ||
| 40 | pcount = 0; | ||
| 41 | else | ||
| 42 | pcount = page_mapcount(ppage); | ||
| 43 | |||
| 44 | if (put_user(pcount, out++)) { | ||
| 45 | ret = -EFAULT; | ||
| 46 | break; | ||
| 47 | } | ||
| 48 | |||
| 49 | count -= KPMSIZE; | ||
| 50 | } | ||
| 51 | |||
| 52 | *ppos += (char __user *)out - buf; | ||
| 53 | if (!ret) | ||
| 54 | ret = (char __user *)out - buf; | ||
| 55 | return ret; | ||
| 56 | } | ||
| 57 | |||
| 58 | static const struct file_operations proc_kpagecount_operations = { | ||
| 59 | .llseek = mem_lseek, | ||
| 60 | .read = kpagecount_read, | ||
| 61 | }; | ||
| 62 | |||
| 63 | /* /proc/kpageflags - an array exposing page flags | ||
| 64 | * | ||
| 65 | * Each entry is a u64 representing the corresponding | ||
| 66 | * physical page flags. | ||
| 67 | */ | ||
| 68 | |||
| 69 | /* These macros are used to decouple internal flags from exported ones */ | ||
| 70 | |||
| 71 | #define KPF_LOCKED 0 | ||
| 72 | #define KPF_ERROR 1 | ||
| 73 | #define KPF_REFERENCED 2 | ||
| 74 | #define KPF_UPTODATE 3 | ||
| 75 | #define KPF_DIRTY 4 | ||
| 76 | #define KPF_LRU 5 | ||
| 77 | #define KPF_ACTIVE 6 | ||
| 78 | #define KPF_SLAB 7 | ||
| 79 | #define KPF_WRITEBACK 8 | ||
| 80 | #define KPF_RECLAIM 9 | ||
| 81 | #define KPF_BUDDY 10 | ||
| 82 | |||
| 83 | #define kpf_copy_bit(flags, srcpos, dstpos) (((flags >> srcpos) & 1) << dstpos) | ||
| 84 | |||
| 85 | static ssize_t kpageflags_read(struct file *file, char __user *buf, | ||
| 86 | size_t count, loff_t *ppos) | ||
| 87 | { | ||
| 88 | u64 __user *out = (u64 __user *)buf; | ||
| 89 | struct page *ppage; | ||
| 90 | unsigned long src = *ppos; | ||
| 91 | unsigned long pfn; | ||
| 92 | ssize_t ret = 0; | ||
| 93 | u64 kflags, uflags; | ||
| 94 | |||
| 95 | pfn = src / KPMSIZE; | ||
| 96 | count = min_t(unsigned long, count, (max_pfn * KPMSIZE) - src); | ||
| 97 | if (src & KPMMASK || count & KPMMASK) | ||
| 98 | return -EINVAL; | ||
| 99 | |||
| 100 | while (count > 0) { | ||
| 101 | ppage = NULL; | ||
| 102 | if (pfn_valid(pfn)) | ||
| 103 | ppage = pfn_to_page(pfn); | ||
| 104 | pfn++; | ||
| 105 | if (!ppage) | ||
| 106 | kflags = 0; | ||
| 107 | else | ||
| 108 | kflags = ppage->flags; | ||
| 109 | |||
| 110 | uflags = kpf_copy_bit(KPF_LOCKED, PG_locked, kflags) | | ||
| 111 | kpf_copy_bit(kflags, KPF_ERROR, PG_error) | | ||
| 112 | kpf_copy_bit(kflags, KPF_REFERENCED, PG_referenced) | | ||
| 113 | kpf_copy_bit(kflags, KPF_UPTODATE, PG_uptodate) | | ||
| 114 | kpf_copy_bit(kflags, KPF_DIRTY, PG_dirty) | | ||
| 115 | kpf_copy_bit(kflags, KPF_LRU, PG_lru) | | ||
| 116 | kpf_copy_bit(kflags, KPF_ACTIVE, PG_active) | | ||
| 117 | kpf_copy_bit(kflags, KPF_SLAB, PG_slab) | | ||
| 118 | kpf_copy_bit(kflags, KPF_WRITEBACK, PG_writeback) | | ||
| 119 | kpf_copy_bit(kflags, KPF_RECLAIM, PG_reclaim) | | ||
| 120 | kpf_copy_bit(kflags, KPF_BUDDY, PG_buddy); | ||
| 121 | |||
| 122 | if (put_user(uflags, out++)) { | ||
| 123 | ret = -EFAULT; | ||
| 124 | break; | ||
| 125 | } | ||
| 126 | |||
| 127 | count -= KPMSIZE; | ||
| 128 | } | ||
| 129 | |||
| 130 | *ppos += (char __user *)out - buf; | ||
| 131 | if (!ret) | ||
| 132 | ret = (char __user *)out - buf; | ||
| 133 | return ret; | ||
| 134 | } | ||
| 135 | |||
| 136 | static const struct file_operations proc_kpageflags_operations = { | ||
| 137 | .llseek = mem_lseek, | ||
| 138 | .read = kpageflags_read, | ||
| 139 | }; | ||
| 140 | |||
| 141 | static int __init proc_page_init(void) | ||
| 142 | { | ||
| 143 | proc_create("kpagecount", S_IRUSR, NULL, &proc_kpagecount_operations); | ||
| 144 | proc_create("kpageflags", S_IRUSR, NULL, &proc_kpageflags_operations); | ||
| 145 | return 0; | ||
| 146 | } | ||
| 147 | module_init(proc_page_init); | ||
diff --git a/fs/proc/proc_devtree.c b/fs/proc/proc_devtree.c index eca471bc8512..d777789b7a89 100644 --- a/fs/proc/proc_devtree.c +++ b/fs/proc/proc_devtree.c | |||
| @@ -4,6 +4,7 @@ | |||
| 4 | * Copyright 1997 Paul Mackerras | 4 | * Copyright 1997 Paul Mackerras |
| 5 | */ | 5 | */ |
| 6 | #include <linux/errno.h> | 6 | #include <linux/errno.h> |
| 7 | #include <linux/init.h> | ||
| 7 | #include <linux/time.h> | 8 | #include <linux/time.h> |
| 8 | #include <linux/proc_fs.h> | 9 | #include <linux/proc_fs.h> |
| 9 | #include <linux/stat.h> | 10 | #include <linux/stat.h> |
| @@ -214,7 +215,7 @@ void proc_device_tree_add_node(struct device_node *np, | |||
| 214 | /* | 215 | /* |
| 215 | * Called on initialization to set up the /proc/device-tree subtree | 216 | * Called on initialization to set up the /proc/device-tree subtree |
| 216 | */ | 217 | */ |
| 217 | void proc_device_tree_init(void) | 218 | void __init proc_device_tree_init(void) |
| 218 | { | 219 | { |
| 219 | struct device_node *root; | 220 | struct device_node *root; |
| 220 | if ( !have_of ) | 221 | if ( !have_of ) |
diff --git a/fs/proc/proc_misc.c b/fs/proc/proc_misc.c deleted file mode 100644 index 7ea52c79b2da..000000000000 --- a/fs/proc/proc_misc.c +++ /dev/null | |||
| @@ -1,933 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * linux/fs/proc/proc_misc.c | ||
| 3 | * | ||
| 4 | * linux/fs/proc/array.c | ||
| 5 | * Copyright (C) 1992 by Linus Torvalds | ||
| 6 | * based on ideas by Darren Senn | ||
| 7 | * | ||
| 8 | * This used to be the part of array.c. See the rest of history and credits | ||
| 9 | * there. I took this into a separate file and switched the thing to generic | ||
| 10 | * proc_file_inode_operations, leaving in array.c only per-process stuff. | ||
| 11 | * Inumbers allocation made dynamic (via create_proc_entry()). AV, May 1999. | ||
| 12 | * | ||
| 13 | * Changes: | ||
| 14 | * Fulton Green : Encapsulated position metric calculations. | ||
| 15 | * <kernel@FultonGreen.com> | ||
| 16 | */ | ||
| 17 | |||
| 18 | #include <linux/types.h> | ||
| 19 | #include <linux/errno.h> | ||
| 20 | #include <linux/time.h> | ||
| 21 | #include <linux/kernel.h> | ||
| 22 | #include <linux/kernel_stat.h> | ||
| 23 | #include <linux/fs.h> | ||
| 24 | #include <linux/tty.h> | ||
| 25 | #include <linux/string.h> | ||
| 26 | #include <linux/mman.h> | ||
| 27 | #include <linux/quicklist.h> | ||
| 28 | #include <linux/proc_fs.h> | ||
| 29 | #include <linux/ioport.h> | ||
| 30 | #include <linux/mm.h> | ||
| 31 | #include <linux/mmzone.h> | ||
| 32 | #include <linux/pagemap.h> | ||
| 33 | #include <linux/irq.h> | ||
| 34 | #include <linux/interrupt.h> | ||
| 35 | #include <linux/swap.h> | ||
| 36 | #include <linux/slab.h> | ||
| 37 | #include <linux/genhd.h> | ||
| 38 | #include <linux/smp.h> | ||
| 39 | #include <linux/signal.h> | ||
| 40 | #include <linux/module.h> | ||
| 41 | #include <linux/init.h> | ||
| 42 | #include <linux/seq_file.h> | ||
| 43 | #include <linux/times.h> | ||
| 44 | #include <linux/profile.h> | ||
| 45 | #include <linux/utsname.h> | ||
| 46 | #include <linux/blkdev.h> | ||
| 47 | #include <linux/hugetlb.h> | ||
| 48 | #include <linux/jiffies.h> | ||
| 49 | #include <linux/vmalloc.h> | ||
| 50 | #include <linux/crash_dump.h> | ||
| 51 | #include <linux/pid_namespace.h> | ||
| 52 | #include <linux/bootmem.h> | ||
| 53 | #include <asm/uaccess.h> | ||
| 54 | #include <asm/pgtable.h> | ||
| 55 | #include <asm/io.h> | ||
| 56 | #include <asm/tlb.h> | ||
| 57 | #include <asm/div64.h> | ||
| 58 | #include "internal.h" | ||
| 59 | |||
| 60 | #define LOAD_INT(x) ((x) >> FSHIFT) | ||
| 61 | #define LOAD_FRAC(x) LOAD_INT(((x) & (FIXED_1-1)) * 100) | ||
| 62 | /* | ||
| 63 | * Warning: stuff below (imported functions) assumes that its output will fit | ||
| 64 | * into one page. For some of those functions it may be wrong. Moreover, we | ||
| 65 | * have a way to deal with that gracefully. Right now I used straightforward | ||
| 66 | * wrappers, but this needs further analysis wrt potential overflows. | ||
| 67 | */ | ||
| 68 | extern int get_hardware_list(char *); | ||
| 69 | extern int get_stram_list(char *); | ||
| 70 | extern int get_exec_domain_list(char *); | ||
| 71 | |||
| 72 | static int proc_calc_metrics(char *page, char **start, off_t off, | ||
| 73 | int count, int *eof, int len) | ||
| 74 | { | ||
| 75 | if (len <= off+count) *eof = 1; | ||
| 76 | *start = page + off; | ||
| 77 | len -= off; | ||
| 78 | if (len>count) len = count; | ||
| 79 | if (len<0) len = 0; | ||
| 80 | return len; | ||
| 81 | } | ||
| 82 | |||
| 83 | static int loadavg_read_proc(char *page, char **start, off_t off, | ||
| 84 | int count, int *eof, void *data) | ||
| 85 | { | ||
| 86 | int a, b, c; | ||
| 87 | int len; | ||
| 88 | unsigned long seq; | ||
| 89 | |||
| 90 | do { | ||
| 91 | seq = read_seqbegin(&xtime_lock); | ||
| 92 | a = avenrun[0] + (FIXED_1/200); | ||
| 93 | b = avenrun[1] + (FIXED_1/200); | ||
| 94 | c = avenrun[2] + (FIXED_1/200); | ||
| 95 | } while (read_seqretry(&xtime_lock, seq)); | ||
| 96 | |||
| 97 | len = sprintf(page,"%d.%02d %d.%02d %d.%02d %ld/%d %d\n", | ||
| 98 | LOAD_INT(a), LOAD_FRAC(a), | ||
| 99 | LOAD_INT(b), LOAD_FRAC(b), | ||
| 100 | LOAD_INT(c), LOAD_FRAC(c), | ||
| 101 | nr_running(), nr_threads, | ||
| 102 | task_active_pid_ns(current)->last_pid); | ||
| 103 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 104 | } | ||
| 105 | |||
| 106 | static int uptime_read_proc(char *page, char **start, off_t off, | ||
| 107 | int count, int *eof, void *data) | ||
| 108 | { | ||
| 109 | struct timespec uptime; | ||
| 110 | struct timespec idle; | ||
| 111 | int len; | ||
| 112 | cputime_t idletime = cputime_add(init_task.utime, init_task.stime); | ||
| 113 | |||
| 114 | do_posix_clock_monotonic_gettime(&uptime); | ||
| 115 | monotonic_to_bootbased(&uptime); | ||
| 116 | cputime_to_timespec(idletime, &idle); | ||
| 117 | len = sprintf(page,"%lu.%02lu %lu.%02lu\n", | ||
| 118 | (unsigned long) uptime.tv_sec, | ||
| 119 | (uptime.tv_nsec / (NSEC_PER_SEC / 100)), | ||
| 120 | (unsigned long) idle.tv_sec, | ||
| 121 | (idle.tv_nsec / (NSEC_PER_SEC / 100))); | ||
| 122 | |||
| 123 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 124 | } | ||
| 125 | |||
| 126 | int __attribute__((weak)) arch_report_meminfo(char *page) | ||
| 127 | { | ||
| 128 | return 0; | ||
| 129 | } | ||
| 130 | |||
| 131 | static int meminfo_read_proc(char *page, char **start, off_t off, | ||
| 132 | int count, int *eof, void *data) | ||
| 133 | { | ||
| 134 | struct sysinfo i; | ||
| 135 | int len; | ||
| 136 | unsigned long committed; | ||
| 137 | unsigned long allowed; | ||
| 138 | struct vmalloc_info vmi; | ||
| 139 | long cached; | ||
| 140 | unsigned long pages[NR_LRU_LISTS]; | ||
| 141 | int lru; | ||
| 142 | |||
| 143 | /* | ||
| 144 | * display in kilobytes. | ||
| 145 | */ | ||
| 146 | #define K(x) ((x) << (PAGE_SHIFT - 10)) | ||
| 147 | si_meminfo(&i); | ||
| 148 | si_swapinfo(&i); | ||
| 149 | committed = atomic_long_read(&vm_committed_space); | ||
| 150 | allowed = ((totalram_pages - hugetlb_total_pages()) | ||
| 151 | * sysctl_overcommit_ratio / 100) + total_swap_pages; | ||
| 152 | |||
| 153 | cached = global_page_state(NR_FILE_PAGES) - | ||
| 154 | total_swapcache_pages - i.bufferram; | ||
| 155 | if (cached < 0) | ||
| 156 | cached = 0; | ||
| 157 | |||
| 158 | get_vmalloc_info(&vmi); | ||
| 159 | |||
| 160 | for (lru = LRU_BASE; lru < NR_LRU_LISTS; lru++) | ||
| 161 | pages[lru] = global_page_state(NR_LRU_BASE + lru); | ||
| 162 | |||
| 163 | /* | ||
| 164 | * Tagged format, for easy grepping and expansion. | ||
| 165 | */ | ||
| 166 | len = sprintf(page, | ||
| 167 | "MemTotal: %8lu kB\n" | ||
| 168 | "MemFree: %8lu kB\n" | ||
| 169 | "Buffers: %8lu kB\n" | ||
| 170 | "Cached: %8lu kB\n" | ||
| 171 | "SwapCached: %8lu kB\n" | ||
| 172 | "Active: %8lu kB\n" | ||
| 173 | "Inactive: %8lu kB\n" | ||
| 174 | "Active(anon): %8lu kB\n" | ||
| 175 | "Inactive(anon): %8lu kB\n" | ||
| 176 | "Active(file): %8lu kB\n" | ||
| 177 | "Inactive(file): %8lu kB\n" | ||
| 178 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
| 179 | "Unevictable: %8lu kB\n" | ||
| 180 | "Mlocked: %8lu kB\n" | ||
| 181 | #endif | ||
| 182 | #ifdef CONFIG_HIGHMEM | ||
| 183 | "HighTotal: %8lu kB\n" | ||
| 184 | "HighFree: %8lu kB\n" | ||
| 185 | "LowTotal: %8lu kB\n" | ||
| 186 | "LowFree: %8lu kB\n" | ||
| 187 | #endif | ||
| 188 | "SwapTotal: %8lu kB\n" | ||
| 189 | "SwapFree: %8lu kB\n" | ||
| 190 | "Dirty: %8lu kB\n" | ||
| 191 | "Writeback: %8lu kB\n" | ||
| 192 | "AnonPages: %8lu kB\n" | ||
| 193 | "Mapped: %8lu kB\n" | ||
| 194 | "Slab: %8lu kB\n" | ||
| 195 | "SReclaimable: %8lu kB\n" | ||
| 196 | "SUnreclaim: %8lu kB\n" | ||
| 197 | "PageTables: %8lu kB\n" | ||
| 198 | #ifdef CONFIG_QUICKLIST | ||
| 199 | "Quicklists: %8lu kB\n" | ||
| 200 | #endif | ||
| 201 | "NFS_Unstable: %8lu kB\n" | ||
| 202 | "Bounce: %8lu kB\n" | ||
| 203 | "WritebackTmp: %8lu kB\n" | ||
| 204 | "CommitLimit: %8lu kB\n" | ||
| 205 | "Committed_AS: %8lu kB\n" | ||
| 206 | "VmallocTotal: %8lu kB\n" | ||
| 207 | "VmallocUsed: %8lu kB\n" | ||
| 208 | "VmallocChunk: %8lu kB\n", | ||
| 209 | K(i.totalram), | ||
| 210 | K(i.freeram), | ||
| 211 | K(i.bufferram), | ||
| 212 | K(cached), | ||
| 213 | K(total_swapcache_pages), | ||
| 214 | K(pages[LRU_ACTIVE_ANON] + pages[LRU_ACTIVE_FILE]), | ||
| 215 | K(pages[LRU_INACTIVE_ANON] + pages[LRU_INACTIVE_FILE]), | ||
| 216 | K(pages[LRU_ACTIVE_ANON]), | ||
| 217 | K(pages[LRU_INACTIVE_ANON]), | ||
| 218 | K(pages[LRU_ACTIVE_FILE]), | ||
| 219 | K(pages[LRU_INACTIVE_FILE]), | ||
| 220 | #ifdef CONFIG_UNEVICTABLE_LRU | ||
| 221 | K(pages[LRU_UNEVICTABLE]), | ||
| 222 | K(global_page_state(NR_MLOCK)), | ||
| 223 | #endif | ||
| 224 | #ifdef CONFIG_HIGHMEM | ||
| 225 | K(i.totalhigh), | ||
| 226 | K(i.freehigh), | ||
| 227 | K(i.totalram-i.totalhigh), | ||
| 228 | K(i.freeram-i.freehigh), | ||
| 229 | #endif | ||
| 230 | K(i.totalswap), | ||
| 231 | K(i.freeswap), | ||
| 232 | K(global_page_state(NR_FILE_DIRTY)), | ||
| 233 | K(global_page_state(NR_WRITEBACK)), | ||
| 234 | K(global_page_state(NR_ANON_PAGES)), | ||
| 235 | K(global_page_state(NR_FILE_MAPPED)), | ||
| 236 | K(global_page_state(NR_SLAB_RECLAIMABLE) + | ||
| 237 | global_page_state(NR_SLAB_UNRECLAIMABLE)), | ||
| 238 | K(global_page_state(NR_SLAB_RECLAIMABLE)), | ||
| 239 | K(global_page_state(NR_SLAB_UNRECLAIMABLE)), | ||
| 240 | K(global_page_state(NR_PAGETABLE)), | ||
| 241 | #ifdef CONFIG_QUICKLIST | ||
| 242 | K(quicklist_total_size()), | ||
| 243 | #endif | ||
| 244 | K(global_page_state(NR_UNSTABLE_NFS)), | ||
| 245 | K(global_page_state(NR_BOUNCE)), | ||
| 246 | K(global_page_state(NR_WRITEBACK_TEMP)), | ||
| 247 | K(allowed), | ||
| 248 | K(committed), | ||
| 249 | (unsigned long)VMALLOC_TOTAL >> 10, | ||
| 250 | vmi.used >> 10, | ||
| 251 | vmi.largest_chunk >> 10 | ||
| 252 | ); | ||
| 253 | |||
| 254 | len += hugetlb_report_meminfo(page + len); | ||
| 255 | |||
| 256 | len += arch_report_meminfo(page + len); | ||
| 257 | |||
| 258 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 259 | #undef K | ||
| 260 | } | ||
| 261 | |||
| 262 | static int fragmentation_open(struct inode *inode, struct file *file) | ||
| 263 | { | ||
| 264 | (void)inode; | ||
| 265 | return seq_open(file, &fragmentation_op); | ||
| 266 | } | ||
| 267 | |||
| 268 | static const struct file_operations fragmentation_file_operations = { | ||
| 269 | .open = fragmentation_open, | ||
| 270 | .read = seq_read, | ||
| 271 | .llseek = seq_lseek, | ||
| 272 | .release = seq_release, | ||
| 273 | }; | ||
| 274 | |||
| 275 | static int pagetypeinfo_open(struct inode *inode, struct file *file) | ||
| 276 | { | ||
| 277 | return seq_open(file, &pagetypeinfo_op); | ||
| 278 | } | ||
| 279 | |||
| 280 | static const struct file_operations pagetypeinfo_file_ops = { | ||
| 281 | .open = pagetypeinfo_open, | ||
| 282 | .read = seq_read, | ||
| 283 | .llseek = seq_lseek, | ||
| 284 | .release = seq_release, | ||
| 285 | }; | ||
| 286 | |||
| 287 | static int zoneinfo_open(struct inode *inode, struct file *file) | ||
| 288 | { | ||
| 289 | return seq_open(file, &zoneinfo_op); | ||
| 290 | } | ||
| 291 | |||
| 292 | static const struct file_operations proc_zoneinfo_file_operations = { | ||
| 293 | .open = zoneinfo_open, | ||
| 294 | .read = seq_read, | ||
| 295 | .llseek = seq_lseek, | ||
| 296 | .release = seq_release, | ||
| 297 | }; | ||
| 298 | |||
| 299 | static int version_read_proc(char *page, char **start, off_t off, | ||
| 300 | int count, int *eof, void *data) | ||
| 301 | { | ||
| 302 | int len; | ||
| 303 | |||
| 304 | len = snprintf(page, PAGE_SIZE, linux_proc_banner, | ||
| 305 | utsname()->sysname, | ||
| 306 | utsname()->release, | ||
| 307 | utsname()->version); | ||
| 308 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 309 | } | ||
| 310 | |||
| 311 | extern const struct seq_operations cpuinfo_op; | ||
| 312 | static int cpuinfo_open(struct inode *inode, struct file *file) | ||
| 313 | { | ||
| 314 | return seq_open(file, &cpuinfo_op); | ||
| 315 | } | ||
| 316 | |||
| 317 | static const struct file_operations proc_cpuinfo_operations = { | ||
| 318 | .open = cpuinfo_open, | ||
| 319 | .read = seq_read, | ||
| 320 | .llseek = seq_lseek, | ||
| 321 | .release = seq_release, | ||
| 322 | }; | ||
| 323 | |||
| 324 | static int devinfo_show(struct seq_file *f, void *v) | ||
| 325 | { | ||
| 326 | int i = *(loff_t *) v; | ||
| 327 | |||
| 328 | if (i < CHRDEV_MAJOR_HASH_SIZE) { | ||
| 329 | if (i == 0) | ||
| 330 | seq_printf(f, "Character devices:\n"); | ||
| 331 | chrdev_show(f, i); | ||
| 332 | } | ||
| 333 | #ifdef CONFIG_BLOCK | ||
| 334 | else { | ||
| 335 | i -= CHRDEV_MAJOR_HASH_SIZE; | ||
| 336 | if (i == 0) | ||
| 337 | seq_printf(f, "\nBlock devices:\n"); | ||
| 338 | blkdev_show(f, i); | ||
| 339 | } | ||
| 340 | #endif | ||
| 341 | return 0; | ||
| 342 | } | ||
| 343 | |||
| 344 | static void *devinfo_start(struct seq_file *f, loff_t *pos) | ||
| 345 | { | ||
| 346 | if (*pos < (BLKDEV_MAJOR_HASH_SIZE + CHRDEV_MAJOR_HASH_SIZE)) | ||
| 347 | return pos; | ||
| 348 | return NULL; | ||
| 349 | } | ||
| 350 | |||
| 351 | static void *devinfo_next(struct seq_file *f, void *v, loff_t *pos) | ||
| 352 | { | ||
| 353 | (*pos)++; | ||
| 354 | if (*pos >= (BLKDEV_MAJOR_HASH_SIZE + CHRDEV_MAJOR_HASH_SIZE)) | ||
| 355 | return NULL; | ||
| 356 | return pos; | ||
| 357 | } | ||
| 358 | |||
| 359 | static void devinfo_stop(struct seq_file *f, void *v) | ||
| 360 | { | ||
| 361 | /* Nothing to do */ | ||
| 362 | } | ||
| 363 | |||
| 364 | static const struct seq_operations devinfo_ops = { | ||
| 365 | .start = devinfo_start, | ||
| 366 | .next = devinfo_next, | ||
| 367 | .stop = devinfo_stop, | ||
| 368 | .show = devinfo_show | ||
| 369 | }; | ||
| 370 | |||
| 371 | static int devinfo_open(struct inode *inode, struct file *filp) | ||
| 372 | { | ||
| 373 | return seq_open(filp, &devinfo_ops); | ||
| 374 | } | ||
| 375 | |||
| 376 | static const struct file_operations proc_devinfo_operations = { | ||
| 377 | .open = devinfo_open, | ||
| 378 | .read = seq_read, | ||
| 379 | .llseek = seq_lseek, | ||
| 380 | .release = seq_release, | ||
| 381 | }; | ||
| 382 | |||
| 383 | static int vmstat_open(struct inode *inode, struct file *file) | ||
| 384 | { | ||
| 385 | return seq_open(file, &vmstat_op); | ||
| 386 | } | ||
| 387 | static const struct file_operations proc_vmstat_file_operations = { | ||
| 388 | .open = vmstat_open, | ||
| 389 | .read = seq_read, | ||
| 390 | .llseek = seq_lseek, | ||
| 391 | .release = seq_release, | ||
| 392 | }; | ||
| 393 | |||
| 394 | #ifdef CONFIG_PROC_HARDWARE | ||
| 395 | static int hardware_read_proc(char *page, char **start, off_t off, | ||
| 396 | int count, int *eof, void *data) | ||
| 397 | { | ||
| 398 | int len = get_hardware_list(page); | ||
| 399 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 400 | } | ||
| 401 | #endif | ||
| 402 | |||
| 403 | #ifdef CONFIG_STRAM_PROC | ||
| 404 | static int stram_read_proc(char *page, char **start, off_t off, | ||
| 405 | int count, int *eof, void *data) | ||
| 406 | { | ||
| 407 | int len = get_stram_list(page); | ||
| 408 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 409 | } | ||
| 410 | #endif | ||
| 411 | |||
| 412 | #ifdef CONFIG_BLOCK | ||
| 413 | static int partitions_open(struct inode *inode, struct file *file) | ||
| 414 | { | ||
| 415 | return seq_open(file, &partitions_op); | ||
| 416 | } | ||
| 417 | static const struct file_operations proc_partitions_operations = { | ||
| 418 | .open = partitions_open, | ||
| 419 | .read = seq_read, | ||
| 420 | .llseek = seq_lseek, | ||
| 421 | .release = seq_release, | ||
| 422 | }; | ||
| 423 | |||
| 424 | static int diskstats_open(struct inode *inode, struct file *file) | ||
| 425 | { | ||
| 426 | return seq_open(file, &diskstats_op); | ||
| 427 | } | ||
| 428 | static const struct file_operations proc_diskstats_operations = { | ||
| 429 | .open = diskstats_open, | ||
| 430 | .read = seq_read, | ||
| 431 | .llseek = seq_lseek, | ||
| 432 | .release = seq_release, | ||
| 433 | }; | ||
| 434 | #endif | ||
| 435 | |||
| 436 | #ifdef CONFIG_MODULES | ||
| 437 | extern const struct seq_operations modules_op; | ||
| 438 | static int modules_open(struct inode *inode, struct file *file) | ||
| 439 | { | ||
| 440 | return seq_open(file, &modules_op); | ||
| 441 | } | ||
| 442 | static const struct file_operations proc_modules_operations = { | ||
| 443 | .open = modules_open, | ||
| 444 | .read = seq_read, | ||
| 445 | .llseek = seq_lseek, | ||
| 446 | .release = seq_release, | ||
| 447 | }; | ||
| 448 | #endif | ||
| 449 | |||
| 450 | #ifdef CONFIG_SLABINFO | ||
| 451 | static int slabinfo_open(struct inode *inode, struct file *file) | ||
| 452 | { | ||
| 453 | return seq_open(file, &slabinfo_op); | ||
| 454 | } | ||
| 455 | static const struct file_operations proc_slabinfo_operations = { | ||
| 456 | .open = slabinfo_open, | ||
| 457 | .read = seq_read, | ||
| 458 | .write = slabinfo_write, | ||
| 459 | .llseek = seq_lseek, | ||
| 460 | .release = seq_release, | ||
| 461 | }; | ||
| 462 | |||
| 463 | #ifdef CONFIG_DEBUG_SLAB_LEAK | ||
| 464 | extern const struct seq_operations slabstats_op; | ||
| 465 | static int slabstats_open(struct inode *inode, struct file *file) | ||
| 466 | { | ||
| 467 | unsigned long *n = kzalloc(PAGE_SIZE, GFP_KERNEL); | ||
| 468 | int ret = -ENOMEM; | ||
| 469 | if (n) { | ||
| 470 | ret = seq_open(file, &slabstats_op); | ||
| 471 | if (!ret) { | ||
| 472 | struct seq_file *m = file->private_data; | ||
| 473 | *n = PAGE_SIZE / (2 * sizeof(unsigned long)); | ||
| 474 | m->private = n; | ||
| 475 | n = NULL; | ||
| 476 | } | ||
| 477 | kfree(n); | ||
| 478 | } | ||
| 479 | return ret; | ||
| 480 | } | ||
| 481 | |||
| 482 | static const struct file_operations proc_slabstats_operations = { | ||
| 483 | .open = slabstats_open, | ||
| 484 | .read = seq_read, | ||
| 485 | .llseek = seq_lseek, | ||
| 486 | .release = seq_release_private, | ||
| 487 | }; | ||
| 488 | #endif | ||
| 489 | #endif | ||
| 490 | |||
| 491 | #ifdef CONFIG_MMU | ||
| 492 | static int vmalloc_open(struct inode *inode, struct file *file) | ||
| 493 | { | ||
| 494 | unsigned int *ptr = NULL; | ||
| 495 | int ret; | ||
| 496 | |||
| 497 | if (NUMA_BUILD) | ||
| 498 | ptr = kmalloc(nr_node_ids * sizeof(unsigned int), GFP_KERNEL); | ||
| 499 | ret = seq_open(file, &vmalloc_op); | ||
| 500 | if (!ret) { | ||
| 501 | struct seq_file *m = file->private_data; | ||
| 502 | m->private = ptr; | ||
| 503 | } else | ||
| 504 | kfree(ptr); | ||
| 505 | return ret; | ||
| 506 | } | ||
| 507 | |||
| 508 | static const struct file_operations proc_vmalloc_operations = { | ||
| 509 | .open = vmalloc_open, | ||
| 510 | .read = seq_read, | ||
| 511 | .llseek = seq_lseek, | ||
| 512 | .release = seq_release_private, | ||
| 513 | }; | ||
| 514 | #endif | ||
| 515 | |||
| 516 | #ifndef arch_irq_stat_cpu | ||
| 517 | #define arch_irq_stat_cpu(cpu) 0 | ||
| 518 | #endif | ||
| 519 | #ifndef arch_irq_stat | ||
| 520 | #define arch_irq_stat() 0 | ||
| 521 | #endif | ||
| 522 | |||
| 523 | static int show_stat(struct seq_file *p, void *v) | ||
| 524 | { | ||
| 525 | int i, j; | ||
| 526 | unsigned long jif; | ||
| 527 | cputime64_t user, nice, system, idle, iowait, irq, softirq, steal; | ||
| 528 | cputime64_t guest; | ||
| 529 | u64 sum = 0; | ||
| 530 | struct timespec boottime; | ||
| 531 | unsigned int per_irq_sum; | ||
| 532 | |||
| 533 | user = nice = system = idle = iowait = | ||
| 534 | irq = softirq = steal = cputime64_zero; | ||
| 535 | guest = cputime64_zero; | ||
| 536 | getboottime(&boottime); | ||
| 537 | jif = boottime.tv_sec; | ||
| 538 | |||
| 539 | for_each_possible_cpu(i) { | ||
| 540 | user = cputime64_add(user, kstat_cpu(i).cpustat.user); | ||
| 541 | nice = cputime64_add(nice, kstat_cpu(i).cpustat.nice); | ||
| 542 | system = cputime64_add(system, kstat_cpu(i).cpustat.system); | ||
| 543 | idle = cputime64_add(idle, kstat_cpu(i).cpustat.idle); | ||
| 544 | iowait = cputime64_add(iowait, kstat_cpu(i).cpustat.iowait); | ||
| 545 | irq = cputime64_add(irq, kstat_cpu(i).cpustat.irq); | ||
| 546 | softirq = cputime64_add(softirq, kstat_cpu(i).cpustat.softirq); | ||
| 547 | steal = cputime64_add(steal, kstat_cpu(i).cpustat.steal); | ||
| 548 | guest = cputime64_add(guest, kstat_cpu(i).cpustat.guest); | ||
| 549 | |||
| 550 | for_each_irq_nr(j) | ||
| 551 | sum += kstat_irqs_cpu(j, i); | ||
| 552 | |||
| 553 | sum += arch_irq_stat_cpu(i); | ||
| 554 | } | ||
| 555 | sum += arch_irq_stat(); | ||
| 556 | |||
| 557 | seq_printf(p, "cpu %llu %llu %llu %llu %llu %llu %llu %llu %llu\n", | ||
| 558 | (unsigned long long)cputime64_to_clock_t(user), | ||
| 559 | (unsigned long long)cputime64_to_clock_t(nice), | ||
| 560 | (unsigned long long)cputime64_to_clock_t(system), | ||
| 561 | (unsigned long long)cputime64_to_clock_t(idle), | ||
| 562 | (unsigned long long)cputime64_to_clock_t(iowait), | ||
| 563 | (unsigned long long)cputime64_to_clock_t(irq), | ||
| 564 | (unsigned long long)cputime64_to_clock_t(softirq), | ||
| 565 | (unsigned long long)cputime64_to_clock_t(steal), | ||
| 566 | (unsigned long long)cputime64_to_clock_t(guest)); | ||
| 567 | for_each_online_cpu(i) { | ||
| 568 | |||
| 569 | /* Copy values here to work around gcc-2.95.3, gcc-2.96 */ | ||
| 570 | user = kstat_cpu(i).cpustat.user; | ||
| 571 | nice = kstat_cpu(i).cpustat.nice; | ||
| 572 | system = kstat_cpu(i).cpustat.system; | ||
| 573 | idle = kstat_cpu(i).cpustat.idle; | ||
| 574 | iowait = kstat_cpu(i).cpustat.iowait; | ||
| 575 | irq = kstat_cpu(i).cpustat.irq; | ||
| 576 | softirq = kstat_cpu(i).cpustat.softirq; | ||
| 577 | steal = kstat_cpu(i).cpustat.steal; | ||
| 578 | guest = kstat_cpu(i).cpustat.guest; | ||
| 579 | seq_printf(p, | ||
| 580 | "cpu%d %llu %llu %llu %llu %llu %llu %llu %llu %llu\n", | ||
| 581 | i, | ||
| 582 | (unsigned long long)cputime64_to_clock_t(user), | ||
| 583 | (unsigned long long)cputime64_to_clock_t(nice), | ||
| 584 | (unsigned long long)cputime64_to_clock_t(system), | ||
| 585 | (unsigned long long)cputime64_to_clock_t(idle), | ||
| 586 | (unsigned long long)cputime64_to_clock_t(iowait), | ||
| 587 | (unsigned long long)cputime64_to_clock_t(irq), | ||
| 588 | (unsigned long long)cputime64_to_clock_t(softirq), | ||
| 589 | (unsigned long long)cputime64_to_clock_t(steal), | ||
| 590 | (unsigned long long)cputime64_to_clock_t(guest)); | ||
| 591 | } | ||
| 592 | seq_printf(p, "intr %llu", (unsigned long long)sum); | ||
| 593 | |||
| 594 | /* sum again ? it could be updated? */ | ||
| 595 | for_each_irq_nr(j) { | ||
| 596 | per_irq_sum = 0; | ||
| 597 | |||
| 598 | for_each_possible_cpu(i) | ||
| 599 | per_irq_sum += kstat_irqs_cpu(j, i); | ||
| 600 | |||
| 601 | seq_printf(p, " %u", per_irq_sum); | ||
| 602 | } | ||
| 603 | |||
| 604 | seq_printf(p, | ||
| 605 | "\nctxt %llu\n" | ||
| 606 | "btime %lu\n" | ||
| 607 | "processes %lu\n" | ||
| 608 | "procs_running %lu\n" | ||
| 609 | "procs_blocked %lu\n", | ||
| 610 | nr_context_switches(), | ||
| 611 | (unsigned long)jif, | ||
| 612 | total_forks, | ||
| 613 | nr_running(), | ||
| 614 | nr_iowait()); | ||
| 615 | |||
| 616 | return 0; | ||
| 617 | } | ||
| 618 | |||
| 619 | static int stat_open(struct inode *inode, struct file *file) | ||
| 620 | { | ||
| 621 | unsigned size = 4096 * (1 + num_possible_cpus() / 32); | ||
| 622 | char *buf; | ||
| 623 | struct seq_file *m; | ||
| 624 | int res; | ||
| 625 | |||
| 626 | /* don't ask for more than the kmalloc() max size, currently 128 KB */ | ||
| 627 | if (size > 128 * 1024) | ||
| 628 | size = 128 * 1024; | ||
| 629 | buf = kmalloc(size, GFP_KERNEL); | ||
| 630 | if (!buf) | ||
| 631 | return -ENOMEM; | ||
| 632 | |||
| 633 | res = single_open(file, show_stat, NULL); | ||
| 634 | if (!res) { | ||
| 635 | m = file->private_data; | ||
| 636 | m->buf = buf; | ||
| 637 | m->size = size; | ||
| 638 | } else | ||
| 639 | kfree(buf); | ||
| 640 | return res; | ||
| 641 | } | ||
| 642 | static const struct file_operations proc_stat_operations = { | ||
| 643 | .open = stat_open, | ||
| 644 | .read = seq_read, | ||
| 645 | .llseek = seq_lseek, | ||
| 646 | .release = single_release, | ||
| 647 | }; | ||
| 648 | |||
| 649 | /* | ||
| 650 | * /proc/interrupts | ||
| 651 | */ | ||
| 652 | static void *int_seq_start(struct seq_file *f, loff_t *pos) | ||
| 653 | { | ||
| 654 | return (*pos <= nr_irqs) ? pos : NULL; | ||
| 655 | } | ||
| 656 | |||
| 657 | |||
| 658 | static void *int_seq_next(struct seq_file *f, void *v, loff_t *pos) | ||
| 659 | { | ||
| 660 | (*pos)++; | ||
| 661 | return (*pos <= nr_irqs) ? pos : NULL; | ||
| 662 | } | ||
| 663 | |||
| 664 | static void int_seq_stop(struct seq_file *f, void *v) | ||
| 665 | { | ||
| 666 | /* Nothing to do */ | ||
| 667 | } | ||
| 668 | |||
| 669 | static const struct seq_operations int_seq_ops = { | ||
| 670 | .start = int_seq_start, | ||
| 671 | .next = int_seq_next, | ||
| 672 | .stop = int_seq_stop, | ||
| 673 | .show = show_interrupts | ||
| 674 | }; | ||
| 675 | |||
| 676 | static int interrupts_open(struct inode *inode, struct file *filp) | ||
| 677 | { | ||
| 678 | return seq_open(filp, &int_seq_ops); | ||
| 679 | } | ||
| 680 | |||
| 681 | static const struct file_operations proc_interrupts_operations = { | ||
| 682 | .open = interrupts_open, | ||
| 683 | .read = seq_read, | ||
| 684 | .llseek = seq_lseek, | ||
| 685 | .release = seq_release, | ||
| 686 | }; | ||
| 687 | |||
| 688 | static int filesystems_read_proc(char *page, char **start, off_t off, | ||
| 689 | int count, int *eof, void *data) | ||
| 690 | { | ||
| 691 | int len = get_filesystem_list(page); | ||
| 692 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 693 | } | ||
| 694 | |||
| 695 | static int cmdline_read_proc(char *page, char **start, off_t off, | ||
| 696 | int count, int *eof, void *data) | ||
| 697 | { | ||
| 698 | int len; | ||
| 699 | |||
| 700 | len = sprintf(page, "%s\n", saved_command_line); | ||
| 701 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 702 | } | ||
| 703 | |||
| 704 | #ifdef CONFIG_FILE_LOCKING | ||
| 705 | static int locks_open(struct inode *inode, struct file *filp) | ||
| 706 | { | ||
| 707 | return seq_open(filp, &locks_seq_operations); | ||
| 708 | } | ||
| 709 | |||
| 710 | static const struct file_operations proc_locks_operations = { | ||
| 711 | .open = locks_open, | ||
| 712 | .read = seq_read, | ||
| 713 | .llseek = seq_lseek, | ||
| 714 | .release = seq_release, | ||
| 715 | }; | ||
| 716 | #endif /* CONFIG_FILE_LOCKING */ | ||
| 717 | |||
| 718 | static int execdomains_read_proc(char *page, char **start, off_t off, | ||
| 719 | int count, int *eof, void *data) | ||
| 720 | { | ||
| 721 | int len = get_exec_domain_list(page); | ||
| 722 | return proc_calc_metrics(page, start, off, count, eof, len); | ||
| 723 | } | ||
| 724 | |||
| 725 | #ifdef CONFIG_PROC_PAGE_MONITOR | ||
| 726 | #define KPMSIZE sizeof(u64) | ||
| 727 | #define KPMMASK (KPMSIZE - 1) | ||
| 728 | /* /proc/kpagecount - an array exposing page counts | ||
| 729 | * | ||
| 730 | * Each entry is a u64 representing the corresponding | ||
| 731 | * physical page count. | ||
| 732 | */ | ||
| 733 | static ssize_t kpagecount_read(struct file *file, char __user *buf, | ||
| 734 | size_t count, loff_t *ppos) | ||
| 735 | { | ||
| 736 | u64 __user *out = (u64 __user *)buf; | ||
| 737 | struct page *ppage; | ||
| 738 | unsigned long src = *ppos; | ||
| 739 | unsigned long pfn; | ||
| 740 | ssize_t ret = 0; | ||
| 741 | u64 pcount; | ||
| 742 | |||
| 743 | pfn = src / KPMSIZE; | ||
| 744 | count = min_t(size_t, count, (max_pfn * KPMSIZE) - src); | ||
| 745 | if (src & KPMMASK || count & KPMMASK) | ||
| 746 | return -EINVAL; | ||
| 747 | |||
| 748 | while (count > 0) { | ||
| 749 | ppage = NULL; | ||
| 750 | if (pfn_valid(pfn)) | ||
| 751 | ppage = pfn_to_page(pfn); | ||
| 752 | pfn++; | ||
| 753 | if (!ppage) | ||
| 754 | pcount = 0; | ||
| 755 | else | ||
| 756 | pcount = page_mapcount(ppage); | ||
| 757 | |||
| 758 | if (put_user(pcount, out++)) { | ||
| 759 | ret = -EFAULT; | ||
| 760 | break; | ||
| 761 | } | ||
| 762 | |||
| 763 | count -= KPMSIZE; | ||
| 764 | } | ||
| 765 | |||
| 766 | *ppos += (char __user *)out - buf; | ||
| 767 | if (!ret) | ||
| 768 | ret = (char __user *)out - buf; | ||
| 769 | return ret; | ||
| 770 | } | ||
| 771 | |||
| 772 | static struct file_operations proc_kpagecount_operations = { | ||
| 773 | .llseek = mem_lseek, | ||
| 774 | .read = kpagecount_read, | ||
| 775 | }; | ||
| 776 | |||
| 777 | /* /proc/kpageflags - an array exposing page flags | ||
| 778 | * | ||
| 779 | * Each entry is a u64 representing the corresponding | ||
| 780 | * physical page flags. | ||
| 781 | */ | ||
| 782 | |||
| 783 | /* These macros are used to decouple internal flags from exported ones */ | ||
| 784 | |||
| 785 | #define KPF_LOCKED 0 | ||
| 786 | #define KPF_ERROR 1 | ||
| 787 | #define KPF_REFERENCED 2 | ||
| 788 | #define KPF_UPTODATE 3 | ||
| 789 | #define KPF_DIRTY 4 | ||
| 790 | #define KPF_LRU 5 | ||
| 791 | #define KPF_ACTIVE 6 | ||
| 792 | #define KPF_SLAB 7 | ||
| 793 | #define KPF_WRITEBACK 8 | ||
| 794 | #define KPF_RECLAIM 9 | ||
| 795 | #define KPF_BUDDY 10 | ||
| 796 | |||
| 797 | #define kpf_copy_bit(flags, srcpos, dstpos) (((flags >> srcpos) & 1) << dstpos) | ||
| 798 | |||
| 799 | static ssize_t kpageflags_read(struct file *file, char __user *buf, | ||
| 800 | size_t count, loff_t *ppos) | ||
| 801 | { | ||
| 802 | u64 __user *out = (u64 __user *)buf; | ||
| 803 | struct page *ppage; | ||
| 804 | unsigned long src = *ppos; | ||
| 805 | unsigned long pfn; | ||
| 806 | ssize_t ret = 0; | ||
| 807 | u64 kflags, uflags; | ||
| 808 | |||
| 809 | pfn = src / KPMSIZE; | ||
| 810 | count = min_t(unsigned long, count, (max_pfn * KPMSIZE) - src); | ||
| 811 | if (src & KPMMASK || count & KPMMASK) | ||
| 812 | return -EINVAL; | ||
| 813 | |||
| 814 | while (count > 0) { | ||
| 815 | ppage = NULL; | ||
| 816 | if (pfn_valid(pfn)) | ||
| 817 | ppage = pfn_to_page(pfn); | ||
| 818 | pfn++; | ||
| 819 | if (!ppage) | ||
| 820 | kflags = 0; | ||
| 821 | else | ||
| 822 | kflags = ppage->flags; | ||
| 823 | |||
| 824 | uflags = kpf_copy_bit(KPF_LOCKED, PG_locked, kflags) | | ||
| 825 | kpf_copy_bit(kflags, KPF_ERROR, PG_error) | | ||
| 826 | kpf_copy_bit(kflags, KPF_REFERENCED, PG_referenced) | | ||
| 827 | kpf_copy_bit(kflags, KPF_UPTODATE, PG_uptodate) | | ||
| 828 | kpf_copy_bit(kflags, KPF_DIRTY, PG_dirty) | | ||
| 829 | kpf_copy_bit(kflags, KPF_LRU, PG_lru) | | ||
| 830 | kpf_copy_bit(kflags, KPF_ACTIVE, PG_active) | | ||
| 831 | kpf_copy_bit(kflags, KPF_SLAB, PG_slab) | | ||
| 832 | kpf_copy_bit(kflags, KPF_WRITEBACK, PG_writeback) | | ||
| 833 | kpf_copy_bit(kflags, KPF_RECLAIM, PG_reclaim) | | ||
| 834 | kpf_copy_bit(kflags, KPF_BUDDY, PG_buddy); | ||
| 835 | |||
| 836 | if (put_user(uflags, out++)) { | ||
| 837 | ret = -EFAULT; | ||
| 838 | break; | ||
| 839 | } | ||
| 840 | |||
| 841 | count -= KPMSIZE; | ||
| 842 | } | ||
| 843 | |||
| 844 | *ppos += (char __user *)out - buf; | ||
| 845 | if (!ret) | ||
| 846 | ret = (char __user *)out - buf; | ||
| 847 | return ret; | ||
| 848 | } | ||
| 849 | |||
| 850 | static struct file_operations proc_kpageflags_operations = { | ||
| 851 | .llseek = mem_lseek, | ||
| 852 | .read = kpageflags_read, | ||
| 853 | }; | ||
| 854 | #endif /* CONFIG_PROC_PAGE_MONITOR */ | ||
| 855 | |||
| 856 | struct proc_dir_entry *proc_root_kcore; | ||
| 857 | |||
| 858 | void __init proc_misc_init(void) | ||
| 859 | { | ||
| 860 | static struct { | ||
| 861 | char *name; | ||
| 862 | int (*read_proc)(char*,char**,off_t,int,int*,void*); | ||
| 863 | } *p, simple_ones[] = { | ||
| 864 | {"loadavg", loadavg_read_proc}, | ||
| 865 | {"uptime", uptime_read_proc}, | ||
| 866 | {"meminfo", meminfo_read_proc}, | ||
| 867 | {"version", version_read_proc}, | ||
| 868 | #ifdef CONFIG_PROC_HARDWARE | ||
| 869 | {"hardware", hardware_read_proc}, | ||
| 870 | #endif | ||
| 871 | #ifdef CONFIG_STRAM_PROC | ||
| 872 | {"stram", stram_read_proc}, | ||
| 873 | #endif | ||
| 874 | {"filesystems", filesystems_read_proc}, | ||
| 875 | {"cmdline", cmdline_read_proc}, | ||
| 876 | {"execdomains", execdomains_read_proc}, | ||
| 877 | {NULL,} | ||
| 878 | }; | ||
| 879 | for (p = simple_ones; p->name; p++) | ||
| 880 | create_proc_read_entry(p->name, 0, NULL, p->read_proc, NULL); | ||
| 881 | |||
| 882 | proc_symlink("mounts", NULL, "self/mounts"); | ||
| 883 | |||
| 884 | /* And now for trickier ones */ | ||
| 885 | #ifdef CONFIG_PRINTK | ||
| 886 | proc_create("kmsg", S_IRUSR, NULL, &proc_kmsg_operations); | ||
| 887 | #endif | ||
| 888 | #ifdef CONFIG_FILE_LOCKING | ||
| 889 | proc_create("locks", 0, NULL, &proc_locks_operations); | ||
| 890 | #endif | ||
| 891 | proc_create("devices", 0, NULL, &proc_devinfo_operations); | ||
| 892 | proc_create("cpuinfo", 0, NULL, &proc_cpuinfo_operations); | ||
| 893 | #ifdef CONFIG_BLOCK | ||
| 894 | proc_create("partitions", 0, NULL, &proc_partitions_operations); | ||
| 895 | #endif | ||
| 896 | proc_create("stat", 0, NULL, &proc_stat_operations); | ||
| 897 | proc_create("interrupts", 0, NULL, &proc_interrupts_operations); | ||
| 898 | #ifdef CONFIG_SLABINFO | ||
| 899 | proc_create("slabinfo",S_IWUSR|S_IRUGO,NULL,&proc_slabinfo_operations); | ||
| 900 | #ifdef CONFIG_DEBUG_SLAB_LEAK | ||
| 901 | proc_create("slab_allocators", 0, NULL, &proc_slabstats_operations); | ||
| 902 | #endif | ||
| 903 | #endif | ||
| 904 | #ifdef CONFIG_MMU | ||
| 905 | proc_create("vmallocinfo", S_IRUSR, NULL, &proc_vmalloc_operations); | ||
| 906 | #endif | ||
| 907 | proc_create("buddyinfo", S_IRUGO, NULL, &fragmentation_file_operations); | ||
| 908 | proc_create("pagetypeinfo", S_IRUGO, NULL, &pagetypeinfo_file_ops); | ||
| 909 | proc_create("vmstat", S_IRUGO, NULL, &proc_vmstat_file_operations); | ||
| 910 | proc_create("zoneinfo", S_IRUGO, NULL, &proc_zoneinfo_file_operations); | ||
| 911 | #ifdef CONFIG_BLOCK | ||
| 912 | proc_create("diskstats", 0, NULL, &proc_diskstats_operations); | ||
| 913 | #endif | ||
| 914 | #ifdef CONFIG_MODULES | ||
| 915 | proc_create("modules", 0, NULL, &proc_modules_operations); | ||
| 916 | #endif | ||
| 917 | #ifdef CONFIG_SCHEDSTATS | ||
| 918 | proc_create("schedstat", 0, NULL, &proc_schedstat_operations); | ||
| 919 | #endif | ||
| 920 | #ifdef CONFIG_PROC_KCORE | ||
| 921 | proc_root_kcore = proc_create("kcore", S_IRUSR, NULL, &proc_kcore_operations); | ||
| 922 | if (proc_root_kcore) | ||
| 923 | proc_root_kcore->size = | ||
| 924 | (size_t)high_memory - PAGE_OFFSET + PAGE_SIZE; | ||
| 925 | #endif | ||
| 926 | #ifdef CONFIG_PROC_PAGE_MONITOR | ||
| 927 | proc_create("kpagecount", S_IRUSR, NULL, &proc_kpagecount_operations); | ||
| 928 | proc_create("kpageflags", S_IRUSR, NULL, &proc_kpageflags_operations); | ||
| 929 | #endif | ||
| 930 | #ifdef CONFIG_PROC_VMCORE | ||
| 931 | proc_vmcore = proc_create("vmcore", S_IRUSR, NULL, &proc_vmcore_operations); | ||
| 932 | #endif | ||
| 933 | } | ||
diff --git a/fs/proc/proc_sysctl.c b/fs/proc/proc_sysctl.c index 7b997754a25e..94fcfff6863a 100644 --- a/fs/proc/proc_sysctl.c +++ b/fs/proc/proc_sysctl.c | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * /proc/sys support | 2 | * /proc/sys support |
| 3 | */ | 3 | */ |
| 4 | 4 | #include <linux/init.h> | |
| 5 | #include <linux/sysctl.h> | 5 | #include <linux/sysctl.h> |
| 6 | #include <linux/proc_fs.h> | 6 | #include <linux/proc_fs.h> |
| 7 | #include <linux/security.h> | 7 | #include <linux/security.h> |
| @@ -402,7 +402,7 @@ static struct dentry_operations proc_sys_dentry_operations = { | |||
| 402 | .d_compare = proc_sys_compare, | 402 | .d_compare = proc_sys_compare, |
| 403 | }; | 403 | }; |
| 404 | 404 | ||
| 405 | int proc_sys_init(void) | 405 | int __init proc_sys_init(void) |
| 406 | { | 406 | { |
| 407 | struct proc_dir_entry *proc_sys_root; | 407 | struct proc_dir_entry *proc_sys_root; |
| 408 | 408 | ||
diff --git a/fs/proc/root.c b/fs/proc/root.c index 95117538a4f6..7761602af9de 100644 --- a/fs/proc/root.c +++ b/fs/proc/root.c | |||
| @@ -104,9 +104,9 @@ static struct file_system_type proc_fs_type = { | |||
| 104 | 104 | ||
| 105 | void __init proc_root_init(void) | 105 | void __init proc_root_init(void) |
| 106 | { | 106 | { |
| 107 | int err = proc_init_inodecache(); | 107 | int err; |
| 108 | if (err) | 108 | |
| 109 | return; | 109 | proc_init_inodecache(); |
| 110 | err = register_filesystem(&proc_fs_type); | 110 | err = register_filesystem(&proc_fs_type); |
| 111 | if (err) | 111 | if (err) |
| 112 | return; | 112 | return; |
| @@ -117,7 +117,7 @@ void __init proc_root_init(void) | |||
| 117 | return; | 117 | return; |
| 118 | } | 118 | } |
| 119 | 119 | ||
| 120 | proc_misc_init(); | 120 | proc_symlink("mounts", NULL, "self/mounts"); |
| 121 | 121 | ||
| 122 | proc_net_init(); | 122 | proc_net_init(); |
| 123 | 123 | ||
diff --git a/fs/proc/stat.c b/fs/proc/stat.c new file mode 100644 index 000000000000..81904f07679d --- /dev/null +++ b/fs/proc/stat.c | |||
| @@ -0,0 +1,153 @@ | |||
| 1 | #include <linux/cpumask.h> | ||
| 2 | #include <linux/fs.h> | ||
| 3 | #include <linux/gfp.h> | ||
| 4 | #include <linux/init.h> | ||
| 5 | #include <linux/interrupt.h> | ||
| 6 | #include <linux/kernel_stat.h> | ||
| 7 | #include <linux/proc_fs.h> | ||
| 8 | #include <linux/sched.h> | ||
| 9 | #include <linux/seq_file.h> | ||
| 10 | #include <linux/slab.h> | ||
| 11 | #include <linux/time.h> | ||
| 12 | #include <asm/cputime.h> | ||
| 13 | |||
| 14 | #ifndef arch_irq_stat_cpu | ||
| 15 | #define arch_irq_stat_cpu(cpu) 0 | ||
| 16 | #endif | ||
| 17 | #ifndef arch_irq_stat | ||
| 18 | #define arch_irq_stat() 0 | ||
| 19 | #endif | ||
| 20 | |||
| 21 | static int show_stat(struct seq_file *p, void *v) | ||
| 22 | { | ||
| 23 | int i, j; | ||
| 24 | unsigned long jif; | ||
| 25 | cputime64_t user, nice, system, idle, iowait, irq, softirq, steal; | ||
| 26 | cputime64_t guest; | ||
| 27 | u64 sum = 0; | ||
| 28 | struct timespec boottime; | ||
| 29 | unsigned int per_irq_sum; | ||
| 30 | |||
| 31 | user = nice = system = idle = iowait = | ||
| 32 | irq = softirq = steal = cputime64_zero; | ||
| 33 | guest = cputime64_zero; | ||
| 34 | getboottime(&boottime); | ||
| 35 | jif = boottime.tv_sec; | ||
| 36 | |||
| 37 | for_each_possible_cpu(i) { | ||
| 38 | user = cputime64_add(user, kstat_cpu(i).cpustat.user); | ||
| 39 | nice = cputime64_add(nice, kstat_cpu(i).cpustat.nice); | ||
| 40 | system = cputime64_add(system, kstat_cpu(i).cpustat.system); | ||
| 41 | idle = cputime64_add(idle, kstat_cpu(i).cpustat.idle); | ||
| 42 | iowait = cputime64_add(iowait, kstat_cpu(i).cpustat.iowait); | ||
| 43 | irq = cputime64_add(irq, kstat_cpu(i).cpustat.irq); | ||
| 44 | softirq = cputime64_add(softirq, kstat_cpu(i).cpustat.softirq); | ||
| 45 | steal = cputime64_add(steal, kstat_cpu(i).cpustat.steal); | ||
| 46 | guest = cputime64_add(guest, kstat_cpu(i).cpustat.guest); | ||
| 47 | |||
| 48 | for_each_irq_nr(j) | ||
| 49 | sum += kstat_irqs_cpu(j, i); | ||
| 50 | |||
| 51 | sum += arch_irq_stat_cpu(i); | ||
| 52 | } | ||
| 53 | sum += arch_irq_stat(); | ||
| 54 | |||
| 55 | seq_printf(p, "cpu %llu %llu %llu %llu %llu %llu %llu %llu %llu\n", | ||
| 56 | (unsigned long long)cputime64_to_clock_t(user), | ||
| 57 | (unsigned long long)cputime64_to_clock_t(nice), | ||
| 58 | (unsigned long long)cputime64_to_clock_t(system), | ||
| 59 | (unsigned long long)cputime64_to_clock_t(idle), | ||
| 60 | (unsigned long long)cputime64_to_clock_t(iowait), | ||
| 61 | (unsigned long long)cputime64_to_clock_t(irq), | ||
| 62 | (unsigned long long)cputime64_to_clock_t(softirq), | ||
| 63 | (unsigned long long)cputime64_to_clock_t(steal), | ||
| 64 | (unsigned long long)cputime64_to_clock_t(guest)); | ||
| 65 | for_each_online_cpu(i) { | ||
| 66 | |||
| 67 | /* Copy values here to work around gcc-2.95.3, gcc-2.96 */ | ||
| 68 | user = kstat_cpu(i).cpustat.user; | ||
| 69 | nice = kstat_cpu(i).cpustat.nice; | ||
| 70 | system = kstat_cpu(i).cpustat.system; | ||
| 71 | idle = kstat_cpu(i).cpustat.idle; | ||
| 72 | iowait = kstat_cpu(i).cpustat.iowait; | ||
| 73 | irq = kstat_cpu(i).cpustat.irq; | ||
| 74 | softirq = kstat_cpu(i).cpustat.softirq; | ||
| 75 | steal = kstat_cpu(i).cpustat.steal; | ||
| 76 | guest = kstat_cpu(i).cpustat.guest; | ||
| 77 | seq_printf(p, | ||
| 78 | "cpu%d %llu %llu %llu %llu %llu %llu %llu %llu %llu\n", | ||
| 79 | i, | ||
| 80 | (unsigned long long)cputime64_to_clock_t(user), | ||
| 81 | (unsigned long long)cputime64_to_clock_t(nice), | ||
| 82 | (unsigned long long)cputime64_to_clock_t(system), | ||
| 83 | (unsigned long long)cputime64_to_clock_t(idle), | ||
| 84 | (unsigned long long)cputime64_to_clock_t(iowait), | ||
| 85 | (unsigned long long)cputime64_to_clock_t(irq), | ||
| 86 | (unsigned long long)cputime64_to_clock_t(softirq), | ||
| 87 | (unsigned long long)cputime64_to_clock_t(steal), | ||
| 88 | (unsigned long long)cputime64_to_clock_t(guest)); | ||
| 89 | } | ||
| 90 | seq_printf(p, "intr %llu", (unsigned long long)sum); | ||
| 91 | |||
| 92 | /* sum again ? it could be updated? */ | ||
| 93 | for_each_irq_nr(j) { | ||
| 94 | per_irq_sum = 0; | ||
| 95 | |||
| 96 | for_each_possible_cpu(i) | ||
| 97 | per_irq_sum += kstat_irqs_cpu(j, i); | ||
| 98 | |||
| 99 | seq_printf(p, " %u", per_irq_sum); | ||
| 100 | } | ||
| 101 | |||
| 102 | seq_printf(p, | ||
| 103 | "\nctxt %llu\n" | ||
| 104 | "btime %lu\n" | ||
| 105 | "processes %lu\n" | ||
| 106 | "procs_running %lu\n" | ||
| 107 | "procs_blocked %lu\n", | ||
| 108 | nr_context_switches(), | ||
| 109 | (unsigned long)jif, | ||
| 110 | total_forks, | ||
| 111 | nr_running(), | ||
| 112 | nr_iowait()); | ||
| 113 | |||
| 114 | return 0; | ||
| 115 | } | ||
| 116 | |||
| 117 | static int stat_open(struct inode *inode, struct file *file) | ||
| 118 | { | ||
| 119 | unsigned size = 4096 * (1 + num_possible_cpus() / 32); | ||
| 120 | char *buf; | ||
| 121 | struct seq_file *m; | ||
| 122 | int res; | ||
| 123 | |||
| 124 | /* don't ask for more than the kmalloc() max size, currently 128 KB */ | ||
| 125 | if (size > 128 * 1024) | ||
| 126 | size = 128 * 1024; | ||
| 127 | buf = kmalloc(size, GFP_KERNEL); | ||
| 128 | if (!buf) | ||
| 129 | return -ENOMEM; | ||
| 130 | |||
| 131 | res = single_open(file, show_stat, NULL); | ||
| 132 | if (!res) { | ||
| 133 | m = file->private_data; | ||
| 134 | m->buf = buf; | ||
| 135 | m->size = size; | ||
| 136 | } else | ||
| 137 | kfree(buf); | ||
| 138 | return res; | ||
| 139 | } | ||
| 140 | |||
| 141 | static const struct file_operations proc_stat_operations = { | ||
| 142 | .open = stat_open, | ||
| 143 | .read = seq_read, | ||
| 144 | .llseek = seq_lseek, | ||
| 145 | .release = single_release, | ||
| 146 | }; | ||
| 147 | |||
| 148 | static int __init proc_stat_init(void) | ||
| 149 | { | ||
| 150 | proc_create("stat", 0, NULL, &proc_stat_operations); | ||
| 151 | return 0; | ||
| 152 | } | ||
| 153 | module_init(proc_stat_init); | ||
diff --git a/fs/proc/task_mmu.c b/fs/proc/task_mmu.c index 4806830ea2a1..b770c095e45c 100644 --- a/fs/proc/task_mmu.c +++ b/fs/proc/task_mmu.c | |||
| @@ -198,11 +198,8 @@ static int do_maps_open(struct inode *inode, struct file *file, | |||
| 198 | return ret; | 198 | return ret; |
| 199 | } | 199 | } |
| 200 | 200 | ||
| 201 | static int show_map(struct seq_file *m, void *v) | 201 | static void show_map_vma(struct seq_file *m, struct vm_area_struct *vma) |
| 202 | { | 202 | { |
| 203 | struct proc_maps_private *priv = m->private; | ||
| 204 | struct task_struct *task = priv->task; | ||
| 205 | struct vm_area_struct *vma = v; | ||
| 206 | struct mm_struct *mm = vma->vm_mm; | 203 | struct mm_struct *mm = vma->vm_mm; |
| 207 | struct file *file = vma->vm_file; | 204 | struct file *file = vma->vm_file; |
| 208 | int flags = vma->vm_flags; | 205 | int flags = vma->vm_flags; |
| @@ -254,6 +251,15 @@ static int show_map(struct seq_file *m, void *v) | |||
| 254 | } | 251 | } |
| 255 | } | 252 | } |
| 256 | seq_putc(m, '\n'); | 253 | seq_putc(m, '\n'); |
| 254 | } | ||
| 255 | |||
| 256 | static int show_map(struct seq_file *m, void *v) | ||
| 257 | { | ||
| 258 | struct vm_area_struct *vma = v; | ||
| 259 | struct proc_maps_private *priv = m->private; | ||
| 260 | struct task_struct *task = priv->task; | ||
| 261 | |||
| 262 | show_map_vma(m, vma); | ||
| 257 | 263 | ||
| 258 | if (m->count < m->size) /* vma is copied successfully */ | 264 | if (m->count < m->size) /* vma is copied successfully */ |
| 259 | m->version = (vma != get_gate_vma(task))? vma->vm_start: 0; | 265 | m->version = (vma != get_gate_vma(task))? vma->vm_start: 0; |
| @@ -364,9 +370,10 @@ static int smaps_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end, | |||
| 364 | 370 | ||
| 365 | static int show_smap(struct seq_file *m, void *v) | 371 | static int show_smap(struct seq_file *m, void *v) |
| 366 | { | 372 | { |
| 373 | struct proc_maps_private *priv = m->private; | ||
| 374 | struct task_struct *task = priv->task; | ||
| 367 | struct vm_area_struct *vma = v; | 375 | struct vm_area_struct *vma = v; |
| 368 | struct mem_size_stats mss; | 376 | struct mem_size_stats mss; |
| 369 | int ret; | ||
| 370 | struct mm_walk smaps_walk = { | 377 | struct mm_walk smaps_walk = { |
| 371 | .pmd_entry = smaps_pte_range, | 378 | .pmd_entry = smaps_pte_range, |
| 372 | .mm = vma->vm_mm, | 379 | .mm = vma->vm_mm, |
| @@ -378,9 +385,7 @@ static int show_smap(struct seq_file *m, void *v) | |||
| 378 | if (vma->vm_mm && !is_vm_hugetlb_page(vma)) | 385 | if (vma->vm_mm && !is_vm_hugetlb_page(vma)) |
| 379 | walk_page_range(vma->vm_start, vma->vm_end, &smaps_walk); | 386 | walk_page_range(vma->vm_start, vma->vm_end, &smaps_walk); |
| 380 | 387 | ||
| 381 | ret = show_map(m, v); | 388 | show_map_vma(m, vma); |
| 382 | if (ret) | ||
| 383 | return ret; | ||
| 384 | 389 | ||
| 385 | seq_printf(m, | 390 | seq_printf(m, |
| 386 | "Size: %8lu kB\n" | 391 | "Size: %8lu kB\n" |
| @@ -402,7 +407,9 @@ static int show_smap(struct seq_file *m, void *v) | |||
| 402 | mss.referenced >> 10, | 407 | mss.referenced >> 10, |
| 403 | mss.swap >> 10); | 408 | mss.swap >> 10); |
| 404 | 409 | ||
| 405 | return ret; | 410 | if (m->count < m->size) /* vma is copied successfully */ |
| 411 | m->version = (vma != get_gate_vma(task)) ? vma->vm_start : 0; | ||
| 412 | return 0; | ||
| 406 | } | 413 | } |
| 407 | 414 | ||
| 408 | static const struct seq_operations proc_pid_smaps_op = { | 415 | static const struct seq_operations proc_pid_smaps_op = { |
diff --git a/fs/proc/uptime.c b/fs/proc/uptime.c new file mode 100644 index 000000000000..0c10a0b3f146 --- /dev/null +++ b/fs/proc/uptime.c | |||
| @@ -0,0 +1,43 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/proc_fs.h> | ||
| 4 | #include <linux/sched.h> | ||
| 5 | #include <linux/seq_file.h> | ||
| 6 | #include <linux/time.h> | ||
| 7 | #include <asm/cputime.h> | ||
| 8 | |||
| 9 | static int uptime_proc_show(struct seq_file *m, void *v) | ||
| 10 | { | ||
| 11 | struct timespec uptime; | ||
| 12 | struct timespec idle; | ||
| 13 | cputime_t idletime = cputime_add(init_task.utime, init_task.stime); | ||
| 14 | |||
| 15 | do_posix_clock_monotonic_gettime(&uptime); | ||
| 16 | monotonic_to_bootbased(&uptime); | ||
| 17 | cputime_to_timespec(idletime, &idle); | ||
| 18 | seq_printf(m, "%lu.%02lu %lu.%02lu\n", | ||
| 19 | (unsigned long) uptime.tv_sec, | ||
| 20 | (uptime.tv_nsec / (NSEC_PER_SEC / 100)), | ||
| 21 | (unsigned long) idle.tv_sec, | ||
| 22 | (idle.tv_nsec / (NSEC_PER_SEC / 100))); | ||
| 23 | return 0; | ||
| 24 | } | ||
| 25 | |||
| 26 | static int uptime_proc_open(struct inode *inode, struct file *file) | ||
| 27 | { | ||
| 28 | return single_open(file, uptime_proc_show, NULL); | ||
| 29 | } | ||
| 30 | |||
| 31 | static const struct file_operations uptime_proc_fops = { | ||
| 32 | .open = uptime_proc_open, | ||
| 33 | .read = seq_read, | ||
| 34 | .llseek = seq_lseek, | ||
| 35 | .release = single_release, | ||
| 36 | }; | ||
| 37 | |||
| 38 | static int __init proc_uptime_init(void) | ||
| 39 | { | ||
| 40 | proc_create("uptime", 0, NULL, &uptime_proc_fops); | ||
| 41 | return 0; | ||
| 42 | } | ||
| 43 | module_init(proc_uptime_init); | ||
diff --git a/fs/proc/version.c b/fs/proc/version.c new file mode 100644 index 000000000000..76817a60678c --- /dev/null +++ b/fs/proc/version.c | |||
| @@ -0,0 +1,34 @@ | |||
| 1 | #include <linux/fs.h> | ||
| 2 | #include <linux/init.h> | ||
| 3 | #include <linux/kernel.h> | ||
| 4 | #include <linux/proc_fs.h> | ||
| 5 | #include <linux/seq_file.h> | ||
| 6 | #include <linux/utsname.h> | ||
| 7 | |||
| 8 | static int version_proc_show(struct seq_file *m, void *v) | ||
| 9 | { | ||
| 10 | seq_printf(m, linux_proc_banner, | ||
| 11 | utsname()->sysname, | ||
| 12 | utsname()->release, | ||
| 13 | utsname()->version); | ||
| 14 | return 0; | ||
| 15 | } | ||
| 16 | |||
| 17 | static int version_proc_open(struct inode *inode, struct file *file) | ||
| 18 | { | ||
| 19 | return single_open(file, version_proc_show, NULL); | ||
| 20 | } | ||
| 21 | |||
| 22 | static const struct file_operations version_proc_fops = { | ||
| 23 | .open = version_proc_open, | ||
| 24 | .read = seq_read, | ||
| 25 | .llseek = seq_lseek, | ||
| 26 | .release = single_release, | ||
| 27 | }; | ||
| 28 | |||
| 29 | static int __init proc_version_init(void) | ||
| 30 | { | ||
| 31 | proc_create("version", 0, NULL, &version_proc_fops); | ||
| 32 | return 0; | ||
| 33 | } | ||
| 34 | module_init(proc_version_init); | ||
diff --git a/fs/proc/vmcore.c b/fs/proc/vmcore.c index cd9ca67f841b..03ec59504906 100644 --- a/fs/proc/vmcore.c +++ b/fs/proc/vmcore.c | |||
| @@ -32,7 +32,7 @@ static size_t elfcorebuf_sz; | |||
| 32 | /* Total size of vmcore file. */ | 32 | /* Total size of vmcore file. */ |
| 33 | static u64 vmcore_size; | 33 | static u64 vmcore_size; |
| 34 | 34 | ||
| 35 | struct proc_dir_entry *proc_vmcore = NULL; | 35 | static struct proc_dir_entry *proc_vmcore = NULL; |
| 36 | 36 | ||
| 37 | /* Reads a page from the oldmem device from given offset. */ | 37 | /* Reads a page from the oldmem device from given offset. */ |
| 38 | static ssize_t read_from_oldmem(char *buf, size_t count, | 38 | static ssize_t read_from_oldmem(char *buf, size_t count, |
| @@ -162,7 +162,7 @@ static ssize_t read_vmcore(struct file *file, char __user *buffer, | |||
| 162 | return acc; | 162 | return acc; |
| 163 | } | 163 | } |
| 164 | 164 | ||
| 165 | const struct file_operations proc_vmcore_operations = { | 165 | static const struct file_operations proc_vmcore_operations = { |
| 166 | .read = read_vmcore, | 166 | .read = read_vmcore, |
| 167 | }; | 167 | }; |
| 168 | 168 | ||
| @@ -652,7 +652,7 @@ static int __init vmcore_init(void) | |||
| 652 | return rc; | 652 | return rc; |
| 653 | } | 653 | } |
| 654 | 654 | ||
| 655 | /* Initialize /proc/vmcore size if proc is already up. */ | 655 | proc_vmcore = proc_create("vmcore", S_IRUSR, NULL, &proc_vmcore_operations); |
| 656 | if (proc_vmcore) | 656 | if (proc_vmcore) |
| 657 | proc_vmcore->size = vmcore_size; | 657 | proc_vmcore->size = vmcore_size; |
| 658 | return 0; | 658 | return 0; |
diff --git a/fs/select.c b/fs/select.c index da0e88201c3a..448e44001286 100644 --- a/fs/select.c +++ b/fs/select.c | |||
| @@ -24,9 +24,64 @@ | |||
| 24 | #include <linux/fdtable.h> | 24 | #include <linux/fdtable.h> |
| 25 | #include <linux/fs.h> | 25 | #include <linux/fs.h> |
| 26 | #include <linux/rcupdate.h> | 26 | #include <linux/rcupdate.h> |
| 27 | #include <linux/hrtimer.h> | ||
| 27 | 28 | ||
| 28 | #include <asm/uaccess.h> | 29 | #include <asm/uaccess.h> |
| 29 | 30 | ||
| 31 | |||
| 32 | /* | ||
| 33 | * Estimate expected accuracy in ns from a timeval. | ||
| 34 | * | ||
| 35 | * After quite a bit of churning around, we've settled on | ||
| 36 | * a simple thing of taking 0.1% of the timeout as the | ||
| 37 | * slack, with a cap of 100 msec. | ||
| 38 | * "nice" tasks get a 0.5% slack instead. | ||
| 39 | * | ||
| 40 | * Consider this comment an open invitation to come up with even | ||
| 41 | * better solutions.. | ||
| 42 | */ | ||
| 43 | |||
| 44 | static long __estimate_accuracy(struct timespec *tv) | ||
| 45 | { | ||
| 46 | long slack; | ||
| 47 | int divfactor = 1000; | ||
| 48 | |||
| 49 | if (task_nice(current) > 0) | ||
| 50 | divfactor = divfactor / 5; | ||
| 51 | |||
| 52 | slack = tv->tv_nsec / divfactor; | ||
| 53 | slack += tv->tv_sec * (NSEC_PER_SEC/divfactor); | ||
| 54 | |||
| 55 | if (slack > 100 * NSEC_PER_MSEC) | ||
| 56 | slack = 100 * NSEC_PER_MSEC; | ||
| 57 | |||
| 58 | if (slack < 0) | ||
| 59 | slack = 0; | ||
| 60 | return slack; | ||
| 61 | } | ||
| 62 | |||
| 63 | static long estimate_accuracy(struct timespec *tv) | ||
| 64 | { | ||
| 65 | unsigned long ret; | ||
| 66 | struct timespec now; | ||
| 67 | |||
| 68 | /* | ||
| 69 | * Realtime tasks get a slack of 0 for obvious reasons. | ||
| 70 | */ | ||
| 71 | |||
| 72 | if (rt_task(current)) | ||
| 73 | return 0; | ||
| 74 | |||
| 75 | ktime_get_ts(&now); | ||
| 76 | now = timespec_sub(*tv, now); | ||
| 77 | ret = __estimate_accuracy(&now); | ||
| 78 | if (ret < current->timer_slack_ns) | ||
| 79 | return current->timer_slack_ns; | ||
| 80 | return ret; | ||
| 81 | } | ||
| 82 | |||
| 83 | |||
| 84 | |||
| 30 | struct poll_table_page { | 85 | struct poll_table_page { |
| 31 | struct poll_table_page * next; | 86 | struct poll_table_page * next; |
| 32 | struct poll_table_entry * entry; | 87 | struct poll_table_entry * entry; |
| @@ -130,6 +185,79 @@ static void __pollwait(struct file *filp, wait_queue_head_t *wait_address, | |||
| 130 | add_wait_queue(wait_address, &entry->wait); | 185 | add_wait_queue(wait_address, &entry->wait); |
| 131 | } | 186 | } |
| 132 | 187 | ||
| 188 | /** | ||
| 189 | * poll_select_set_timeout - helper function to setup the timeout value | ||
| 190 | * @to: pointer to timespec variable for the final timeout | ||
| 191 | * @sec: seconds (from user space) | ||
| 192 | * @nsec: nanoseconds (from user space) | ||
| 193 | * | ||
| 194 | * Note, we do not use a timespec for the user space value here, That | ||
| 195 | * way we can use the function for timeval and compat interfaces as well. | ||
| 196 | * | ||
| 197 | * Returns -EINVAL if sec/nsec are not normalized. Otherwise 0. | ||
| 198 | */ | ||
| 199 | int poll_select_set_timeout(struct timespec *to, long sec, long nsec) | ||
| 200 | { | ||
| 201 | struct timespec ts = {.tv_sec = sec, .tv_nsec = nsec}; | ||
| 202 | |||
| 203 | if (!timespec_valid(&ts)) | ||
| 204 | return -EINVAL; | ||
| 205 | |||
| 206 | /* Optimize for the zero timeout value here */ | ||
| 207 | if (!sec && !nsec) { | ||
| 208 | to->tv_sec = to->tv_nsec = 0; | ||
| 209 | } else { | ||
| 210 | ktime_get_ts(to); | ||
| 211 | *to = timespec_add_safe(*to, ts); | ||
| 212 | } | ||
| 213 | return 0; | ||
| 214 | } | ||
| 215 | |||
| 216 | static int poll_select_copy_remaining(struct timespec *end_time, void __user *p, | ||
| 217 | int timeval, int ret) | ||
| 218 | { | ||
| 219 | struct timespec rts; | ||
| 220 | struct timeval rtv; | ||
| 221 | |||
| 222 | if (!p) | ||
| 223 | return ret; | ||
| 224 | |||
| 225 | if (current->personality & STICKY_TIMEOUTS) | ||
| 226 | goto sticky; | ||
| 227 | |||
| 228 | /* No update for zero timeout */ | ||
| 229 | if (!end_time->tv_sec && !end_time->tv_nsec) | ||
| 230 | return ret; | ||
| 231 | |||
| 232 | ktime_get_ts(&rts); | ||
| 233 | rts = timespec_sub(*end_time, rts); | ||
| 234 | if (rts.tv_sec < 0) | ||
| 235 | rts.tv_sec = rts.tv_nsec = 0; | ||
| 236 | |||
| 237 | if (timeval) { | ||
| 238 | rtv.tv_sec = rts.tv_sec; | ||
| 239 | rtv.tv_usec = rts.tv_nsec / NSEC_PER_USEC; | ||
| 240 | |||
| 241 | if (!copy_to_user(p, &rtv, sizeof(rtv))) | ||
| 242 | return ret; | ||
| 243 | |||
| 244 | } else if (!copy_to_user(p, &rts, sizeof(rts))) | ||
| 245 | return ret; | ||
| 246 | |||
| 247 | /* | ||
| 248 | * If an application puts its timeval in read-only memory, we | ||
| 249 | * don't want the Linux-specific update to the timeval to | ||
| 250 | * cause a fault after the select has completed | ||
| 251 | * successfully. However, because we're not updating the | ||
| 252 | * timeval, we can't restart the system call. | ||
| 253 | */ | ||
| 254 | |||
| 255 | sticky: | ||
| 256 | if (ret == -ERESTARTNOHAND) | ||
| 257 | ret = -EINTR; | ||
| 258 | return ret; | ||
| 259 | } | ||
| 260 | |||
| 133 | #define FDS_IN(fds, n) (fds->in + n) | 261 | #define FDS_IN(fds, n) (fds->in + n) |
| 134 | #define FDS_OUT(fds, n) (fds->out + n) | 262 | #define FDS_OUT(fds, n) (fds->out + n) |
| 135 | #define FDS_EX(fds, n) (fds->ex + n) | 263 | #define FDS_EX(fds, n) (fds->ex + n) |
| @@ -182,11 +310,13 @@ get_max: | |||
| 182 | #define POLLOUT_SET (POLLWRBAND | POLLWRNORM | POLLOUT | POLLERR) | 310 | #define POLLOUT_SET (POLLWRBAND | POLLWRNORM | POLLOUT | POLLERR) |
| 183 | #define POLLEX_SET (POLLPRI) | 311 | #define POLLEX_SET (POLLPRI) |
| 184 | 312 | ||
| 185 | int do_select(int n, fd_set_bits *fds, s64 *timeout) | 313 | int do_select(int n, fd_set_bits *fds, struct timespec *end_time) |
| 186 | { | 314 | { |
| 315 | ktime_t expire, *to = NULL; | ||
| 187 | struct poll_wqueues table; | 316 | struct poll_wqueues table; |
| 188 | poll_table *wait; | 317 | poll_table *wait; |
| 189 | int retval, i; | 318 | int retval, i, timed_out = 0; |
| 319 | unsigned long slack = 0; | ||
| 190 | 320 | ||
| 191 | rcu_read_lock(); | 321 | rcu_read_lock(); |
| 192 | retval = max_select_fd(n, fds); | 322 | retval = max_select_fd(n, fds); |
| @@ -198,12 +328,17 @@ int do_select(int n, fd_set_bits *fds, s64 *timeout) | |||
| 198 | 328 | ||
| 199 | poll_initwait(&table); | 329 | poll_initwait(&table); |
| 200 | wait = &table.pt; | 330 | wait = &table.pt; |
| 201 | if (!*timeout) | 331 | if (end_time && !end_time->tv_sec && !end_time->tv_nsec) { |
| 202 | wait = NULL; | 332 | wait = NULL; |
| 333 | timed_out = 1; | ||
| 334 | } | ||
| 335 | |||
| 336 | if (end_time && !timed_out) | ||
| 337 | slack = estimate_accuracy(end_time); | ||
| 338 | |||
| 203 | retval = 0; | 339 | retval = 0; |
| 204 | for (;;) { | 340 | for (;;) { |
| 205 | unsigned long *rinp, *routp, *rexp, *inp, *outp, *exp; | 341 | unsigned long *rinp, *routp, *rexp, *inp, *outp, *exp; |
| 206 | long __timeout; | ||
| 207 | 342 | ||
| 208 | set_current_state(TASK_INTERRUPTIBLE); | 343 | set_current_state(TASK_INTERRUPTIBLE); |
| 209 | 344 | ||
| @@ -259,27 +394,25 @@ int do_select(int n, fd_set_bits *fds, s64 *timeout) | |||
| 259 | cond_resched(); | 394 | cond_resched(); |
| 260 | } | 395 | } |
| 261 | wait = NULL; | 396 | wait = NULL; |
| 262 | if (retval || !*timeout || signal_pending(current)) | 397 | if (retval || timed_out || signal_pending(current)) |
| 263 | break; | 398 | break; |
| 264 | if (table.error) { | 399 | if (table.error) { |
| 265 | retval = table.error; | 400 | retval = table.error; |
| 266 | break; | 401 | break; |
| 267 | } | 402 | } |
| 268 | 403 | ||
| 269 | if (*timeout < 0) { | 404 | /* |
| 270 | /* Wait indefinitely */ | 405 | * If this is the first loop and we have a timeout |
| 271 | __timeout = MAX_SCHEDULE_TIMEOUT; | 406 | * given, then we convert to ktime_t and set the to |
| 272 | } else if (unlikely(*timeout >= (s64)MAX_SCHEDULE_TIMEOUT - 1)) { | 407 | * pointer to the expiry value. |
| 273 | /* Wait for longer than MAX_SCHEDULE_TIMEOUT. Do it in a loop */ | 408 | */ |
| 274 | __timeout = MAX_SCHEDULE_TIMEOUT - 1; | 409 | if (end_time && !to) { |
| 275 | *timeout -= __timeout; | 410 | expire = timespec_to_ktime(*end_time); |
| 276 | } else { | 411 | to = &expire; |
| 277 | __timeout = *timeout; | ||
| 278 | *timeout = 0; | ||
| 279 | } | 412 | } |
| 280 | __timeout = schedule_timeout(__timeout); | 413 | |
| 281 | if (*timeout >= 0) | 414 | if (!schedule_hrtimeout_range(to, slack, HRTIMER_MODE_ABS)) |
| 282 | *timeout += __timeout; | 415 | timed_out = 1; |
| 283 | } | 416 | } |
| 284 | __set_current_state(TASK_RUNNING); | 417 | __set_current_state(TASK_RUNNING); |
| 285 | 418 | ||
| @@ -300,7 +433,7 @@ int do_select(int n, fd_set_bits *fds, s64 *timeout) | |||
| 300 | ((unsigned long) (MAX_SCHEDULE_TIMEOUT / HZ)-1) | 433 | ((unsigned long) (MAX_SCHEDULE_TIMEOUT / HZ)-1) |
| 301 | 434 | ||
| 302 | int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, | 435 | int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, |
| 303 | fd_set __user *exp, s64 *timeout) | 436 | fd_set __user *exp, struct timespec *end_time) |
| 304 | { | 437 | { |
| 305 | fd_set_bits fds; | 438 | fd_set_bits fds; |
| 306 | void *bits; | 439 | void *bits; |
| @@ -351,7 +484,7 @@ int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, | |||
| 351 | zero_fd_set(n, fds.res_out); | 484 | zero_fd_set(n, fds.res_out); |
| 352 | zero_fd_set(n, fds.res_ex); | 485 | zero_fd_set(n, fds.res_ex); |
| 353 | 486 | ||
| 354 | ret = do_select(n, &fds, timeout); | 487 | ret = do_select(n, &fds, end_time); |
| 355 | 488 | ||
| 356 | if (ret < 0) | 489 | if (ret < 0) |
| 357 | goto out; | 490 | goto out; |
| @@ -377,7 +510,7 @@ out_nofds: | |||
| 377 | asmlinkage long sys_select(int n, fd_set __user *inp, fd_set __user *outp, | 510 | asmlinkage long sys_select(int n, fd_set __user *inp, fd_set __user *outp, |
| 378 | fd_set __user *exp, struct timeval __user *tvp) | 511 | fd_set __user *exp, struct timeval __user *tvp) |
| 379 | { | 512 | { |
| 380 | s64 timeout = -1; | 513 | struct timespec end_time, *to = NULL; |
| 381 | struct timeval tv; | 514 | struct timeval tv; |
| 382 | int ret; | 515 | int ret; |
| 383 | 516 | ||
| @@ -385,43 +518,14 @@ asmlinkage long sys_select(int n, fd_set __user *inp, fd_set __user *outp, | |||
| 385 | if (copy_from_user(&tv, tvp, sizeof(tv))) | 518 | if (copy_from_user(&tv, tvp, sizeof(tv))) |
| 386 | return -EFAULT; | 519 | return -EFAULT; |
| 387 | 520 | ||
| 388 | if (tv.tv_sec < 0 || tv.tv_usec < 0) | 521 | to = &end_time; |
| 522 | if (poll_select_set_timeout(to, tv.tv_sec, | ||
| 523 | tv.tv_usec * NSEC_PER_USEC)) | ||
| 389 | return -EINVAL; | 524 | return -EINVAL; |
| 390 | |||
| 391 | /* Cast to u64 to make GCC stop complaining */ | ||
| 392 | if ((u64)tv.tv_sec >= (u64)MAX_INT64_SECONDS) | ||
| 393 | timeout = -1; /* infinite */ | ||
| 394 | else { | ||
| 395 | timeout = DIV_ROUND_UP(tv.tv_usec, USEC_PER_SEC/HZ); | ||
| 396 | timeout += tv.tv_sec * HZ; | ||
| 397 | } | ||
| 398 | } | 525 | } |
| 399 | 526 | ||
| 400 | ret = core_sys_select(n, inp, outp, exp, &timeout); | 527 | ret = core_sys_select(n, inp, outp, exp, to); |
| 401 | 528 | ret = poll_select_copy_remaining(&end_time, tvp, 1, ret); | |
| 402 | if (tvp) { | ||
| 403 | struct timeval rtv; | ||
| 404 | |||
| 405 | if (current->personality & STICKY_TIMEOUTS) | ||
| 406 | goto sticky; | ||
| 407 | rtv.tv_usec = jiffies_to_usecs(do_div((*(u64*)&timeout), HZ)); | ||
| 408 | rtv.tv_sec = timeout; | ||
| 409 | if (timeval_compare(&rtv, &tv) >= 0) | ||
| 410 | rtv = tv; | ||
| 411 | if (copy_to_user(tvp, &rtv, sizeof(rtv))) { | ||
| 412 | sticky: | ||
| 413 | /* | ||
| 414 | * If an application puts its timeval in read-only | ||
| 415 | * memory, we don't want the Linux-specific update to | ||
| 416 | * the timeval to cause a fault after the select has | ||
| 417 | * completed successfully. However, because we're not | ||
| 418 | * updating the timeval, we can't restart the system | ||
| 419 | * call. | ||
| 420 | */ | ||
| 421 | if (ret == -ERESTARTNOHAND) | ||
| 422 | ret = -EINTR; | ||
| 423 | } | ||
| 424 | } | ||
| 425 | 529 | ||
| 426 | return ret; | 530 | return ret; |
| 427 | } | 531 | } |
| @@ -431,25 +535,17 @@ asmlinkage long sys_pselect7(int n, fd_set __user *inp, fd_set __user *outp, | |||
| 431 | fd_set __user *exp, struct timespec __user *tsp, | 535 | fd_set __user *exp, struct timespec __user *tsp, |
| 432 | const sigset_t __user *sigmask, size_t sigsetsize) | 536 | const sigset_t __user *sigmask, size_t sigsetsize) |
| 433 | { | 537 | { |
| 434 | s64 timeout = MAX_SCHEDULE_TIMEOUT; | ||
| 435 | sigset_t ksigmask, sigsaved; | 538 | sigset_t ksigmask, sigsaved; |
| 436 | struct timespec ts; | 539 | struct timespec ts, end_time, *to = NULL; |
| 437 | int ret; | 540 | int ret; |
| 438 | 541 | ||
| 439 | if (tsp) { | 542 | if (tsp) { |
| 440 | if (copy_from_user(&ts, tsp, sizeof(ts))) | 543 | if (copy_from_user(&ts, tsp, sizeof(ts))) |
| 441 | return -EFAULT; | 544 | return -EFAULT; |
| 442 | 545 | ||
| 443 | if (ts.tv_sec < 0 || ts.tv_nsec < 0) | 546 | to = &end_time; |
| 547 | if (poll_select_set_timeout(to, ts.tv_sec, ts.tv_nsec)) | ||
| 444 | return -EINVAL; | 548 | return -EINVAL; |
| 445 | |||
| 446 | /* Cast to u64 to make GCC stop complaining */ | ||
| 447 | if ((u64)ts.tv_sec >= (u64)MAX_INT64_SECONDS) | ||
| 448 | timeout = -1; /* infinite */ | ||
| 449 | else { | ||
| 450 | timeout = DIV_ROUND_UP(ts.tv_nsec, NSEC_PER_SEC/HZ); | ||
| 451 | timeout += ts.tv_sec * HZ; | ||
| 452 | } | ||
| 453 | } | 549 | } |
| 454 | 550 | ||
| 455 | if (sigmask) { | 551 | if (sigmask) { |
| @@ -463,32 +559,8 @@ asmlinkage long sys_pselect7(int n, fd_set __user *inp, fd_set __user *outp, | |||
| 463 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); | 559 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); |
| 464 | } | 560 | } |
| 465 | 561 | ||
| 466 | ret = core_sys_select(n, inp, outp, exp, &timeout); | 562 | ret = core_sys_select(n, inp, outp, exp, &end_time); |
| 467 | 563 | ret = poll_select_copy_remaining(&end_time, tsp, 0, ret); | |
| 468 | if (tsp) { | ||
| 469 | struct timespec rts; | ||
| 470 | |||
| 471 | if (current->personality & STICKY_TIMEOUTS) | ||
| 472 | goto sticky; | ||
| 473 | rts.tv_nsec = jiffies_to_usecs(do_div((*(u64*)&timeout), HZ)) * | ||
| 474 | 1000; | ||
| 475 | rts.tv_sec = timeout; | ||
| 476 | if (timespec_compare(&rts, &ts) >= 0) | ||
| 477 | rts = ts; | ||
| 478 | if (copy_to_user(tsp, &rts, sizeof(rts))) { | ||
| 479 | sticky: | ||
| 480 | /* | ||
| 481 | * If an application puts its timeval in read-only | ||
| 482 | * memory, we don't want the Linux-specific update to | ||
| 483 | * the timeval to cause a fault after the select has | ||
| 484 | * completed successfully. However, because we're not | ||
| 485 | * updating the timeval, we can't restart the system | ||
| 486 | * call. | ||
| 487 | */ | ||
| 488 | if (ret == -ERESTARTNOHAND) | ||
| 489 | ret = -EINTR; | ||
| 490 | } | ||
| 491 | } | ||
| 492 | 564 | ||
| 493 | if (ret == -ERESTARTNOHAND) { | 565 | if (ret == -ERESTARTNOHAND) { |
| 494 | /* | 566 | /* |
| @@ -574,18 +646,24 @@ static inline unsigned int do_pollfd(struct pollfd *pollfd, poll_table *pwait) | |||
| 574 | } | 646 | } |
| 575 | 647 | ||
| 576 | static int do_poll(unsigned int nfds, struct poll_list *list, | 648 | static int do_poll(unsigned int nfds, struct poll_list *list, |
| 577 | struct poll_wqueues *wait, s64 *timeout) | 649 | struct poll_wqueues *wait, struct timespec *end_time) |
| 578 | { | 650 | { |
| 579 | int count = 0; | ||
| 580 | poll_table* pt = &wait->pt; | 651 | poll_table* pt = &wait->pt; |
| 652 | ktime_t expire, *to = NULL; | ||
| 653 | int timed_out = 0, count = 0; | ||
| 654 | unsigned long slack = 0; | ||
| 581 | 655 | ||
| 582 | /* Optimise the no-wait case */ | 656 | /* Optimise the no-wait case */ |
| 583 | if (!(*timeout)) | 657 | if (end_time && !end_time->tv_sec && !end_time->tv_nsec) { |
| 584 | pt = NULL; | 658 | pt = NULL; |
| 659 | timed_out = 1; | ||
| 660 | } | ||
| 661 | |||
| 662 | if (end_time && !timed_out) | ||
| 663 | slack = estimate_accuracy(end_time); | ||
| 585 | 664 | ||
| 586 | for (;;) { | 665 | for (;;) { |
| 587 | struct poll_list *walk; | 666 | struct poll_list *walk; |
| 588 | long __timeout; | ||
| 589 | 667 | ||
| 590 | set_current_state(TASK_INTERRUPTIBLE); | 668 | set_current_state(TASK_INTERRUPTIBLE); |
| 591 | for (walk = list; walk != NULL; walk = walk->next) { | 669 | for (walk = list; walk != NULL; walk = walk->next) { |
| @@ -617,27 +695,21 @@ static int do_poll(unsigned int nfds, struct poll_list *list, | |||
| 617 | if (signal_pending(current)) | 695 | if (signal_pending(current)) |
| 618 | count = -EINTR; | 696 | count = -EINTR; |
| 619 | } | 697 | } |
| 620 | if (count || !*timeout) | 698 | if (count || timed_out) |
| 621 | break; | 699 | break; |
| 622 | 700 | ||
| 623 | if (*timeout < 0) { | 701 | /* |
| 624 | /* Wait indefinitely */ | 702 | * If this is the first loop and we have a timeout |
| 625 | __timeout = MAX_SCHEDULE_TIMEOUT; | 703 | * given, then we convert to ktime_t and set the to |
| 626 | } else if (unlikely(*timeout >= (s64)MAX_SCHEDULE_TIMEOUT-1)) { | 704 | * pointer to the expiry value. |
| 627 | /* | 705 | */ |
| 628 | * Wait for longer than MAX_SCHEDULE_TIMEOUT. Do it in | 706 | if (end_time && !to) { |
| 629 | * a loop | 707 | expire = timespec_to_ktime(*end_time); |
| 630 | */ | 708 | to = &expire; |
| 631 | __timeout = MAX_SCHEDULE_TIMEOUT - 1; | ||
| 632 | *timeout -= __timeout; | ||
| 633 | } else { | ||
| 634 | __timeout = *timeout; | ||
| 635 | *timeout = 0; | ||
| 636 | } | 709 | } |
| 637 | 710 | ||
| 638 | __timeout = schedule_timeout(__timeout); | 711 | if (!schedule_hrtimeout_range(to, slack, HRTIMER_MODE_ABS)) |
| 639 | if (*timeout >= 0) | 712 | timed_out = 1; |
| 640 | *timeout += __timeout; | ||
| 641 | } | 713 | } |
| 642 | __set_current_state(TASK_RUNNING); | 714 | __set_current_state(TASK_RUNNING); |
| 643 | return count; | 715 | return count; |
| @@ -646,7 +718,8 @@ static int do_poll(unsigned int nfds, struct poll_list *list, | |||
| 646 | #define N_STACK_PPS ((sizeof(stack_pps) - sizeof(struct poll_list)) / \ | 718 | #define N_STACK_PPS ((sizeof(stack_pps) - sizeof(struct poll_list)) / \ |
| 647 | sizeof(struct pollfd)) | 719 | sizeof(struct pollfd)) |
| 648 | 720 | ||
| 649 | int do_sys_poll(struct pollfd __user *ufds, unsigned int nfds, s64 *timeout) | 721 | int do_sys_poll(struct pollfd __user *ufds, unsigned int nfds, |
| 722 | struct timespec *end_time) | ||
| 650 | { | 723 | { |
| 651 | struct poll_wqueues table; | 724 | struct poll_wqueues table; |
| 652 | int err = -EFAULT, fdcount, len, size; | 725 | int err = -EFAULT, fdcount, len, size; |
| @@ -686,7 +759,7 @@ int do_sys_poll(struct pollfd __user *ufds, unsigned int nfds, s64 *timeout) | |||
| 686 | } | 759 | } |
| 687 | 760 | ||
| 688 | poll_initwait(&table); | 761 | poll_initwait(&table); |
| 689 | fdcount = do_poll(nfds, head, &table, timeout); | 762 | fdcount = do_poll(nfds, head, &table, end_time); |
| 690 | poll_freewait(&table); | 763 | poll_freewait(&table); |
| 691 | 764 | ||
| 692 | for (walk = head; walk; walk = walk->next) { | 765 | for (walk = head; walk; walk = walk->next) { |
| @@ -712,16 +785,21 @@ out_fds: | |||
| 712 | 785 | ||
| 713 | static long do_restart_poll(struct restart_block *restart_block) | 786 | static long do_restart_poll(struct restart_block *restart_block) |
| 714 | { | 787 | { |
| 715 | struct pollfd __user *ufds = (struct pollfd __user*)restart_block->arg0; | 788 | struct pollfd __user *ufds = restart_block->poll.ufds; |
| 716 | int nfds = restart_block->arg1; | 789 | int nfds = restart_block->poll.nfds; |
| 717 | s64 timeout = ((s64)restart_block->arg3<<32) | (s64)restart_block->arg2; | 790 | struct timespec *to = NULL, end_time; |
| 718 | int ret; | 791 | int ret; |
| 719 | 792 | ||
| 720 | ret = do_sys_poll(ufds, nfds, &timeout); | 793 | if (restart_block->poll.has_timeout) { |
| 794 | end_time.tv_sec = restart_block->poll.tv_sec; | ||
| 795 | end_time.tv_nsec = restart_block->poll.tv_nsec; | ||
| 796 | to = &end_time; | ||
| 797 | } | ||
| 798 | |||
| 799 | ret = do_sys_poll(ufds, nfds, to); | ||
| 800 | |||
| 721 | if (ret == -EINTR) { | 801 | if (ret == -EINTR) { |
| 722 | restart_block->fn = do_restart_poll; | 802 | restart_block->fn = do_restart_poll; |
| 723 | restart_block->arg2 = timeout & 0xFFFFFFFF; | ||
| 724 | restart_block->arg3 = (u64)timeout >> 32; | ||
| 725 | ret = -ERESTART_RESTARTBLOCK; | 803 | ret = -ERESTART_RESTARTBLOCK; |
| 726 | } | 804 | } |
| 727 | return ret; | 805 | return ret; |
| @@ -730,31 +808,32 @@ static long do_restart_poll(struct restart_block *restart_block) | |||
| 730 | asmlinkage long sys_poll(struct pollfd __user *ufds, unsigned int nfds, | 808 | asmlinkage long sys_poll(struct pollfd __user *ufds, unsigned int nfds, |
| 731 | long timeout_msecs) | 809 | long timeout_msecs) |
| 732 | { | 810 | { |
| 733 | s64 timeout_jiffies; | 811 | struct timespec end_time, *to = NULL; |
| 734 | int ret; | 812 | int ret; |
| 735 | 813 | ||
| 736 | if (timeout_msecs > 0) { | 814 | if (timeout_msecs >= 0) { |
| 737 | #if HZ > 1000 | 815 | to = &end_time; |
| 738 | /* We can only overflow if HZ > 1000 */ | 816 | poll_select_set_timeout(to, timeout_msecs / MSEC_PER_SEC, |
| 739 | if (timeout_msecs / 1000 > (s64)0x7fffffffffffffffULL / (s64)HZ) | 817 | NSEC_PER_MSEC * (timeout_msecs % MSEC_PER_SEC)); |
| 740 | timeout_jiffies = -1; | ||
| 741 | else | ||
| 742 | #endif | ||
| 743 | timeout_jiffies = msecs_to_jiffies(timeout_msecs) + 1; | ||
| 744 | } else { | ||
| 745 | /* Infinite (< 0) or no (0) timeout */ | ||
| 746 | timeout_jiffies = timeout_msecs; | ||
| 747 | } | 818 | } |
| 748 | 819 | ||
| 749 | ret = do_sys_poll(ufds, nfds, &timeout_jiffies); | 820 | ret = do_sys_poll(ufds, nfds, to); |
| 821 | |||
| 750 | if (ret == -EINTR) { | 822 | if (ret == -EINTR) { |
| 751 | struct restart_block *restart_block; | 823 | struct restart_block *restart_block; |
| 824 | |||
| 752 | restart_block = ¤t_thread_info()->restart_block; | 825 | restart_block = ¤t_thread_info()->restart_block; |
| 753 | restart_block->fn = do_restart_poll; | 826 | restart_block->fn = do_restart_poll; |
| 754 | restart_block->arg0 = (unsigned long)ufds; | 827 | restart_block->poll.ufds = ufds; |
| 755 | restart_block->arg1 = nfds; | 828 | restart_block->poll.nfds = nfds; |
| 756 | restart_block->arg2 = timeout_jiffies & 0xFFFFFFFF; | 829 | |
| 757 | restart_block->arg3 = (u64)timeout_jiffies >> 32; | 830 | if (timeout_msecs >= 0) { |
| 831 | restart_block->poll.tv_sec = end_time.tv_sec; | ||
| 832 | restart_block->poll.tv_nsec = end_time.tv_nsec; | ||
| 833 | restart_block->poll.has_timeout = 1; | ||
| 834 | } else | ||
| 835 | restart_block->poll.has_timeout = 0; | ||
| 836 | |||
| 758 | ret = -ERESTART_RESTARTBLOCK; | 837 | ret = -ERESTART_RESTARTBLOCK; |
| 759 | } | 838 | } |
| 760 | return ret; | 839 | return ret; |
| @@ -766,21 +845,16 @@ asmlinkage long sys_ppoll(struct pollfd __user *ufds, unsigned int nfds, | |||
| 766 | size_t sigsetsize) | 845 | size_t sigsetsize) |
| 767 | { | 846 | { |
| 768 | sigset_t ksigmask, sigsaved; | 847 | sigset_t ksigmask, sigsaved; |
| 769 | struct timespec ts; | 848 | struct timespec ts, end_time, *to = NULL; |
| 770 | s64 timeout = -1; | ||
| 771 | int ret; | 849 | int ret; |
| 772 | 850 | ||
| 773 | if (tsp) { | 851 | if (tsp) { |
| 774 | if (copy_from_user(&ts, tsp, sizeof(ts))) | 852 | if (copy_from_user(&ts, tsp, sizeof(ts))) |
| 775 | return -EFAULT; | 853 | return -EFAULT; |
| 776 | 854 | ||
| 777 | /* Cast to u64 to make GCC stop complaining */ | 855 | to = &end_time; |
| 778 | if ((u64)ts.tv_sec >= (u64)MAX_INT64_SECONDS) | 856 | if (poll_select_set_timeout(to, ts.tv_sec, ts.tv_nsec)) |
| 779 | timeout = -1; /* infinite */ | 857 | return -EINVAL; |
| 780 | else { | ||
| 781 | timeout = DIV_ROUND_UP(ts.tv_nsec, NSEC_PER_SEC/HZ); | ||
| 782 | timeout += ts.tv_sec * HZ; | ||
| 783 | } | ||
| 784 | } | 858 | } |
| 785 | 859 | ||
| 786 | if (sigmask) { | 860 | if (sigmask) { |
| @@ -794,7 +868,7 @@ asmlinkage long sys_ppoll(struct pollfd __user *ufds, unsigned int nfds, | |||
| 794 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); | 868 | sigprocmask(SIG_SETMASK, &ksigmask, &sigsaved); |
| 795 | } | 869 | } |
| 796 | 870 | ||
| 797 | ret = do_sys_poll(ufds, nfds, &timeout); | 871 | ret = do_sys_poll(ufds, nfds, to); |
| 798 | 872 | ||
| 799 | /* We can restart this syscall, usually */ | 873 | /* We can restart this syscall, usually */ |
| 800 | if (ret == -EINTR) { | 874 | if (ret == -EINTR) { |
| @@ -812,31 +886,7 @@ asmlinkage long sys_ppoll(struct pollfd __user *ufds, unsigned int nfds, | |||
| 812 | } else if (sigmask) | 886 | } else if (sigmask) |
| 813 | sigprocmask(SIG_SETMASK, &sigsaved, NULL); | 887 | sigprocmask(SIG_SETMASK, &sigsaved, NULL); |
| 814 | 888 | ||
| 815 | if (tsp && timeout >= 0) { | 889 | ret = poll_select_copy_remaining(&end_time, tsp, 0, ret); |
| 816 | struct timespec rts; | ||
| 817 | |||
| 818 | if (current->personality & STICKY_TIMEOUTS) | ||
| 819 | goto sticky; | ||
| 820 | /* Yes, we know it's actually an s64, but it's also positive. */ | ||
| 821 | rts.tv_nsec = jiffies_to_usecs(do_div((*(u64*)&timeout), HZ)) * | ||
| 822 | 1000; | ||
| 823 | rts.tv_sec = timeout; | ||
| 824 | if (timespec_compare(&rts, &ts) >= 0) | ||
| 825 | rts = ts; | ||
| 826 | if (copy_to_user(tsp, &rts, sizeof(rts))) { | ||
| 827 | sticky: | ||
| 828 | /* | ||
| 829 | * If an application puts its timeval in read-only | ||
| 830 | * memory, we don't want the Linux-specific update to | ||
| 831 | * the timeval to cause a fault after the select has | ||
| 832 | * completed successfully. However, because we're not | ||
| 833 | * updating the timeval, we can't restart the system | ||
| 834 | * call. | ||
| 835 | */ | ||
| 836 | if (ret == -ERESTARTNOHAND && timeout >= 0) | ||
| 837 | ret = -EINTR; | ||
| 838 | } | ||
| 839 | } | ||
| 840 | 890 | ||
| 841 | return ret; | 891 | return ret; |
| 842 | } | 892 | } |
diff --git a/fs/timerfd.c b/fs/timerfd.c index c502c60e4f54..0862f0e49d0c 100644 --- a/fs/timerfd.c +++ b/fs/timerfd.c | |||
| @@ -52,11 +52,9 @@ static enum hrtimer_restart timerfd_tmrproc(struct hrtimer *htmr) | |||
| 52 | 52 | ||
| 53 | static ktime_t timerfd_get_remaining(struct timerfd_ctx *ctx) | 53 | static ktime_t timerfd_get_remaining(struct timerfd_ctx *ctx) |
| 54 | { | 54 | { |
| 55 | ktime_t now, remaining; | 55 | ktime_t remaining; |
| 56 | |||
| 57 | now = ctx->tmr.base->get_time(); | ||
| 58 | remaining = ktime_sub(ctx->tmr.expires, now); | ||
| 59 | 56 | ||
| 57 | remaining = hrtimer_expires_remaining(&ctx->tmr); | ||
| 60 | return remaining.tv64 < 0 ? ktime_set(0, 0): remaining; | 58 | return remaining.tv64 < 0 ? ktime_set(0, 0): remaining; |
| 61 | } | 59 | } |
| 62 | 60 | ||
| @@ -74,7 +72,7 @@ static void timerfd_setup(struct timerfd_ctx *ctx, int flags, | |||
| 74 | ctx->ticks = 0; | 72 | ctx->ticks = 0; |
| 75 | ctx->tintv = timespec_to_ktime(ktmr->it_interval); | 73 | ctx->tintv = timespec_to_ktime(ktmr->it_interval); |
| 76 | hrtimer_init(&ctx->tmr, ctx->clockid, htmode); | 74 | hrtimer_init(&ctx->tmr, ctx->clockid, htmode); |
| 77 | ctx->tmr.expires = texp; | 75 | hrtimer_set_expires(&ctx->tmr, texp); |
| 78 | ctx->tmr.function = timerfd_tmrproc; | 76 | ctx->tmr.function = timerfd_tmrproc; |
| 79 | if (texp.tv64 != 0) | 77 | if (texp.tv64 != 0) |
| 80 | hrtimer_start(&ctx->tmr, texp, htmode); | 78 | hrtimer_start(&ctx->tmr, texp, htmode); |
diff --git a/include/asm-m68k/machdep.h b/include/asm-m68k/machdep.h index 26d2b91209c5..5637dcef314e 100644 --- a/include/asm-m68k/machdep.h +++ b/include/asm-m68k/machdep.h | |||
| @@ -14,7 +14,7 @@ extern void (*mach_sched_init) (irq_handler_t handler); | |||
| 14 | /* machine dependent irq functions */ | 14 | /* machine dependent irq functions */ |
| 15 | extern void (*mach_init_IRQ) (void); | 15 | extern void (*mach_init_IRQ) (void); |
| 16 | extern void (*mach_get_model) (char *model); | 16 | extern void (*mach_get_model) (char *model); |
| 17 | extern int (*mach_get_hardware_list) (char *buffer); | 17 | extern void (*mach_get_hardware_list) (struct seq_file *m); |
| 18 | /* machine dependent timer functions */ | 18 | /* machine dependent timer functions */ |
| 19 | extern unsigned long (*mach_gettimeoffset)(void); | 19 | extern unsigned long (*mach_gettimeoffset)(void); |
| 20 | extern int (*mach_hwclk)(int, struct rtc_time*); | 20 | extern int (*mach_hwclk)(int, struct rtc_time*); |
diff --git a/include/linux/crash_dump.h b/include/linux/crash_dump.h index 0acf3b737e2e..2dac064d8359 100644 --- a/include/linux/crash_dump.h +++ b/include/linux/crash_dump.h | |||
| @@ -14,8 +14,6 @@ extern unsigned long long elfcorehdr_addr; | |||
| 14 | 14 | ||
| 15 | extern ssize_t copy_oldmem_page(unsigned long, char *, size_t, | 15 | extern ssize_t copy_oldmem_page(unsigned long, char *, size_t, |
| 16 | unsigned long, int); | 16 | unsigned long, int); |
| 17 | extern const struct file_operations proc_vmcore_operations; | ||
| 18 | extern struct proc_dir_entry *proc_vmcore; | ||
| 19 | 17 | ||
| 20 | /* Architecture code defines this if there are other possible ELF | 18 | /* Architecture code defines this if there are other possible ELF |
| 21 | * machine types, e.g. on bi-arch capable hardware. */ | 19 | * machine types, e.g. on bi-arch capable hardware. */ |
diff --git a/include/linux/fs.h b/include/linux/fs.h index 43659ae52e4d..5b248d61430c 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
| @@ -1042,7 +1042,6 @@ extern int vfs_setlease(struct file *, long, struct file_lock **); | |||
| 1042 | extern int lease_modify(struct file_lock **, int); | 1042 | extern int lease_modify(struct file_lock **, int); |
| 1043 | extern int lock_may_read(struct inode *, loff_t start, unsigned long count); | 1043 | extern int lock_may_read(struct inode *, loff_t start, unsigned long count); |
| 1044 | extern int lock_may_write(struct inode *, loff_t start, unsigned long count); | 1044 | extern int lock_may_write(struct inode *, loff_t start, unsigned long count); |
| 1045 | extern struct seq_operations locks_seq_operations; | ||
| 1046 | #else /* !CONFIG_FILE_LOCKING */ | 1045 | #else /* !CONFIG_FILE_LOCKING */ |
| 1047 | #define fcntl_getlk(a, b) ({ -EINVAL; }) | 1046 | #define fcntl_getlk(a, b) ({ -EINVAL; }) |
| 1048 | #define fcntl_setlk(a, b, c, d) ({ -EACCES; }) | 1047 | #define fcntl_setlk(a, b, c, d) ({ -EACCES; }) |
diff --git a/include/linux/genhd.h b/include/linux/genhd.h index 206cdf96c3a7..e439e6aed832 100644 --- a/include/linux/genhd.h +++ b/include/linux/genhd.h | |||
| @@ -25,9 +25,6 @@ extern struct device_type part_type; | |||
| 25 | extern struct kobject *block_depr; | 25 | extern struct kobject *block_depr; |
| 26 | extern struct class block_class; | 26 | extern struct class block_class; |
| 27 | 27 | ||
| 28 | extern const struct seq_operations partitions_op; | ||
| 29 | extern const struct seq_operations diskstats_op; | ||
| 30 | |||
| 31 | enum { | 28 | enum { |
| 32 | /* These three have identical behaviour; use the second one if DOS FDISK gets | 29 | /* These three have identical behaviour; use the second one if DOS FDISK gets |
| 33 | confused about extended/logical partitions starting past cylinder 1023. */ | 30 | confused about extended/logical partitions starting past cylinder 1023. */ |
diff --git a/include/linux/hrtimer.h b/include/linux/hrtimer.h index 9a4e35cd5f79..2b3645b1acf4 100644 --- a/include/linux/hrtimer.h +++ b/include/linux/hrtimer.h | |||
| @@ -20,6 +20,8 @@ | |||
| 20 | #include <linux/init.h> | 20 | #include <linux/init.h> |
| 21 | #include <linux/list.h> | 21 | #include <linux/list.h> |
| 22 | #include <linux/wait.h> | 22 | #include <linux/wait.h> |
| 23 | #include <linux/percpu.h> | ||
| 24 | |||
| 23 | 25 | ||
| 24 | struct hrtimer_clock_base; | 26 | struct hrtimer_clock_base; |
| 25 | struct hrtimer_cpu_base; | 27 | struct hrtimer_cpu_base; |
| @@ -101,9 +103,14 @@ enum hrtimer_cb_mode { | |||
| 101 | /** | 103 | /** |
| 102 | * struct hrtimer - the basic hrtimer structure | 104 | * struct hrtimer - the basic hrtimer structure |
| 103 | * @node: red black tree node for time ordered insertion | 105 | * @node: red black tree node for time ordered insertion |
| 104 | * @expires: the absolute expiry time in the hrtimers internal | 106 | * @_expires: the absolute expiry time in the hrtimers internal |
| 105 | * representation. The time is related to the clock on | 107 | * representation. The time is related to the clock on |
| 106 | * which the timer is based. | 108 | * which the timer is based. Is setup by adding |
| 109 | * slack to the _softexpires value. For non range timers | ||
| 110 | * identical to _softexpires. | ||
| 111 | * @_softexpires: the absolute earliest expiry time of the hrtimer. | ||
| 112 | * The time which was given as expiry time when the timer | ||
| 113 | * was armed. | ||
| 107 | * @function: timer expiry callback function | 114 | * @function: timer expiry callback function |
| 108 | * @base: pointer to the timer base (per cpu and per clock) | 115 | * @base: pointer to the timer base (per cpu and per clock) |
| 109 | * @state: state information (See bit values above) | 116 | * @state: state information (See bit values above) |
| @@ -121,7 +128,8 @@ enum hrtimer_cb_mode { | |||
| 121 | */ | 128 | */ |
| 122 | struct hrtimer { | 129 | struct hrtimer { |
| 123 | struct rb_node node; | 130 | struct rb_node node; |
| 124 | ktime_t expires; | 131 | ktime_t _expires; |
| 132 | ktime_t _softexpires; | ||
| 125 | enum hrtimer_restart (*function)(struct hrtimer *); | 133 | enum hrtimer_restart (*function)(struct hrtimer *); |
| 126 | struct hrtimer_clock_base *base; | 134 | struct hrtimer_clock_base *base; |
| 127 | unsigned long state; | 135 | unsigned long state; |
| @@ -201,6 +209,71 @@ struct hrtimer_cpu_base { | |||
| 201 | #endif | 209 | #endif |
| 202 | }; | 210 | }; |
| 203 | 211 | ||
| 212 | static inline void hrtimer_set_expires(struct hrtimer *timer, ktime_t time) | ||
| 213 | { | ||
| 214 | timer->_expires = time; | ||
| 215 | timer->_softexpires = time; | ||
| 216 | } | ||
| 217 | |||
| 218 | static inline void hrtimer_set_expires_range(struct hrtimer *timer, ktime_t time, ktime_t delta) | ||
| 219 | { | ||
| 220 | timer->_softexpires = time; | ||
| 221 | timer->_expires = ktime_add_safe(time, delta); | ||
| 222 | } | ||
| 223 | |||
| 224 | static inline void hrtimer_set_expires_range_ns(struct hrtimer *timer, ktime_t time, unsigned long delta) | ||
| 225 | { | ||
| 226 | timer->_softexpires = time; | ||
| 227 | timer->_expires = ktime_add_safe(time, ns_to_ktime(delta)); | ||
| 228 | } | ||
| 229 | |||
| 230 | static inline void hrtimer_set_expires_tv64(struct hrtimer *timer, s64 tv64) | ||
| 231 | { | ||
| 232 | timer->_expires.tv64 = tv64; | ||
| 233 | timer->_softexpires.tv64 = tv64; | ||
| 234 | } | ||
| 235 | |||
| 236 | static inline void hrtimer_add_expires(struct hrtimer *timer, ktime_t time) | ||
| 237 | { | ||
| 238 | timer->_expires = ktime_add_safe(timer->_expires, time); | ||
| 239 | timer->_softexpires = ktime_add_safe(timer->_softexpires, time); | ||
| 240 | } | ||
| 241 | |||
| 242 | static inline void hrtimer_add_expires_ns(struct hrtimer *timer, unsigned long ns) | ||
| 243 | { | ||
| 244 | timer->_expires = ktime_add_ns(timer->_expires, ns); | ||
| 245 | timer->_softexpires = ktime_add_ns(timer->_softexpires, ns); | ||
| 246 | } | ||
| 247 | |||
| 248 | static inline ktime_t hrtimer_get_expires(const struct hrtimer *timer) | ||
| 249 | { | ||
| 250 | return timer->_expires; | ||
| 251 | } | ||
| 252 | |||
| 253 | static inline ktime_t hrtimer_get_softexpires(const struct hrtimer *timer) | ||
| 254 | { | ||
| 255 | return timer->_softexpires; | ||
| 256 | } | ||
| 257 | |||
| 258 | static inline s64 hrtimer_get_expires_tv64(const struct hrtimer *timer) | ||
| 259 | { | ||
| 260 | return timer->_expires.tv64; | ||
| 261 | } | ||
| 262 | static inline s64 hrtimer_get_softexpires_tv64(const struct hrtimer *timer) | ||
| 263 | { | ||
| 264 | return timer->_softexpires.tv64; | ||
| 265 | } | ||
| 266 | |||
| 267 | static inline s64 hrtimer_get_expires_ns(const struct hrtimer *timer) | ||
| 268 | { | ||
| 269 | return ktime_to_ns(timer->_expires); | ||
| 270 | } | ||
| 271 | |||
| 272 | static inline ktime_t hrtimer_expires_remaining(const struct hrtimer *timer) | ||
| 273 | { | ||
| 274 | return ktime_sub(timer->_expires, timer->base->get_time()); | ||
| 275 | } | ||
| 276 | |||
| 204 | #ifdef CONFIG_HIGH_RES_TIMERS | 277 | #ifdef CONFIG_HIGH_RES_TIMERS |
| 205 | struct clock_event_device; | 278 | struct clock_event_device; |
| 206 | 279 | ||
| @@ -221,6 +294,8 @@ static inline int hrtimer_is_hres_active(struct hrtimer *timer) | |||
| 221 | return timer->base->cpu_base->hres_active; | 294 | return timer->base->cpu_base->hres_active; |
| 222 | } | 295 | } |
| 223 | 296 | ||
| 297 | extern void hrtimer_peek_ahead_timers(void); | ||
| 298 | |||
| 224 | /* | 299 | /* |
| 225 | * The resolution of the clocks. The resolution value is returned in | 300 | * The resolution of the clocks. The resolution value is returned in |
| 226 | * the clock_getres() system call to give application programmers an | 301 | * the clock_getres() system call to give application programmers an |
| @@ -243,6 +318,7 @@ static inline int hrtimer_is_hres_active(struct hrtimer *timer) | |||
| 243 | * is expired in the next softirq when the clock was advanced. | 318 | * is expired in the next softirq when the clock was advanced. |
| 244 | */ | 319 | */ |
| 245 | static inline void clock_was_set(void) { } | 320 | static inline void clock_was_set(void) { } |
| 321 | static inline void hrtimer_peek_ahead_timers(void) { } | ||
| 246 | 322 | ||
| 247 | static inline void hres_timers_resume(void) { } | 323 | static inline void hres_timers_resume(void) { } |
| 248 | 324 | ||
| @@ -264,6 +340,10 @@ static inline int hrtimer_is_hres_active(struct hrtimer *timer) | |||
| 264 | extern ktime_t ktime_get(void); | 340 | extern ktime_t ktime_get(void); |
| 265 | extern ktime_t ktime_get_real(void); | 341 | extern ktime_t ktime_get_real(void); |
| 266 | 342 | ||
| 343 | |||
| 344 | DECLARE_PER_CPU(struct tick_device, tick_cpu_device); | ||
| 345 | |||
| 346 | |||
| 267 | /* Exported timer functions: */ | 347 | /* Exported timer functions: */ |
| 268 | 348 | ||
| 269 | /* Initialize timers: */ | 349 | /* Initialize timers: */ |
| @@ -288,12 +368,25 @@ static inline void destroy_hrtimer_on_stack(struct hrtimer *timer) { } | |||
| 288 | /* Basic timer operations: */ | 368 | /* Basic timer operations: */ |
| 289 | extern int hrtimer_start(struct hrtimer *timer, ktime_t tim, | 369 | extern int hrtimer_start(struct hrtimer *timer, ktime_t tim, |
| 290 | const enum hrtimer_mode mode); | 370 | const enum hrtimer_mode mode); |
| 371 | extern int hrtimer_start_range_ns(struct hrtimer *timer, ktime_t tim, | ||
| 372 | unsigned long range_ns, const enum hrtimer_mode mode); | ||
| 291 | extern int hrtimer_cancel(struct hrtimer *timer); | 373 | extern int hrtimer_cancel(struct hrtimer *timer); |
| 292 | extern int hrtimer_try_to_cancel(struct hrtimer *timer); | 374 | extern int hrtimer_try_to_cancel(struct hrtimer *timer); |
| 293 | 375 | ||
| 376 | static inline int hrtimer_start_expires(struct hrtimer *timer, | ||
| 377 | enum hrtimer_mode mode) | ||
| 378 | { | ||
| 379 | unsigned long delta; | ||
| 380 | ktime_t soft, hard; | ||
| 381 | soft = hrtimer_get_softexpires(timer); | ||
| 382 | hard = hrtimer_get_expires(timer); | ||
| 383 | delta = ktime_to_ns(ktime_sub(hard, soft)); | ||
| 384 | return hrtimer_start_range_ns(timer, soft, delta, mode); | ||
| 385 | } | ||
| 386 | |||
| 294 | static inline int hrtimer_restart(struct hrtimer *timer) | 387 | static inline int hrtimer_restart(struct hrtimer *timer) |
| 295 | { | 388 | { |
| 296 | return hrtimer_start(timer, timer->expires, HRTIMER_MODE_ABS); | 389 | return hrtimer_start_expires(timer, HRTIMER_MODE_ABS); |
| 297 | } | 390 | } |
| 298 | 391 | ||
| 299 | /* Query timers: */ | 392 | /* Query timers: */ |
| @@ -350,6 +443,10 @@ extern long hrtimer_nanosleep_restart(struct restart_block *restart_block); | |||
| 350 | extern void hrtimer_init_sleeper(struct hrtimer_sleeper *sl, | 443 | extern void hrtimer_init_sleeper(struct hrtimer_sleeper *sl, |
| 351 | struct task_struct *tsk); | 444 | struct task_struct *tsk); |
| 352 | 445 | ||
| 446 | extern int schedule_hrtimeout_range(ktime_t *expires, unsigned long delta, | ||
| 447 | const enum hrtimer_mode mode); | ||
| 448 | extern int schedule_hrtimeout(ktime_t *expires, const enum hrtimer_mode mode); | ||
| 449 | |||
| 353 | /* Soft interrupt function to run the hrtimer queues: */ | 450 | /* Soft interrupt function to run the hrtimer queues: */ |
| 354 | extern void hrtimer_run_queues(void); | 451 | extern void hrtimer_run_queues(void); |
| 355 | extern void hrtimer_run_pending(void); | 452 | extern void hrtimer_run_pending(void); |
diff --git a/include/linux/hugetlb.h b/include/linux/hugetlb.h index 32e0ef0f6e1f..e1c8afc002c0 100644 --- a/include/linux/hugetlb.h +++ b/include/linux/hugetlb.h | |||
| @@ -27,7 +27,7 @@ void unmap_hugepage_range(struct vm_area_struct *, | |||
| 27 | void __unmap_hugepage_range(struct vm_area_struct *, | 27 | void __unmap_hugepage_range(struct vm_area_struct *, |
| 28 | unsigned long, unsigned long, struct page *); | 28 | unsigned long, unsigned long, struct page *); |
| 29 | int hugetlb_prefault(struct address_space *, struct vm_area_struct *); | 29 | int hugetlb_prefault(struct address_space *, struct vm_area_struct *); |
| 30 | int hugetlb_report_meminfo(char *); | 30 | void hugetlb_report_meminfo(struct seq_file *); |
| 31 | int hugetlb_report_node_meminfo(int, char *); | 31 | int hugetlb_report_node_meminfo(int, char *); |
| 32 | unsigned long hugetlb_total_pages(void); | 32 | unsigned long hugetlb_total_pages(void); |
| 33 | int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma, | 33 | int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma, |
| @@ -79,7 +79,9 @@ static inline unsigned long hugetlb_total_pages(void) | |||
| 79 | #define copy_hugetlb_page_range(src, dst, vma) ({ BUG(); 0; }) | 79 | #define copy_hugetlb_page_range(src, dst, vma) ({ BUG(); 0; }) |
| 80 | #define hugetlb_prefault(mapping, vma) ({ BUG(); 0; }) | 80 | #define hugetlb_prefault(mapping, vma) ({ BUG(); 0; }) |
| 81 | #define unmap_hugepage_range(vma, start, end, page) BUG() | 81 | #define unmap_hugepage_range(vma, start, end, page) BUG() |
| 82 | #define hugetlb_report_meminfo(buf) 0 | 82 | static inline void hugetlb_report_meminfo(struct seq_file *m) |
| 83 | { | ||
| 84 | } | ||
| 83 | #define hugetlb_report_node_meminfo(n, buf) 0 | 85 | #define hugetlb_report_node_meminfo(n, buf) 0 |
| 84 | #define follow_huge_pmd(mm, addr, pmd, write) NULL | 86 | #define follow_huge_pmd(mm, addr, pmd, write) NULL |
| 85 | #define follow_huge_pud(mm, addr, pud, write) NULL | 87 | #define follow_huge_pud(mm, addr, pud, write) NULL |
diff --git a/include/linux/init_task.h b/include/linux/init_task.h index 021d8e720c79..23fd8909b9e5 100644 --- a/include/linux/init_task.h +++ b/include/linux/init_task.h | |||
| @@ -170,6 +170,7 @@ extern struct group_info init_groups; | |||
| 170 | .cpu_timers = INIT_CPU_TIMERS(tsk.cpu_timers), \ | 170 | .cpu_timers = INIT_CPU_TIMERS(tsk.cpu_timers), \ |
| 171 | .fs_excl = ATOMIC_INIT(0), \ | 171 | .fs_excl = ATOMIC_INIT(0), \ |
| 172 | .pi_lock = __SPIN_LOCK_UNLOCKED(tsk.pi_lock), \ | 172 | .pi_lock = __SPIN_LOCK_UNLOCKED(tsk.pi_lock), \ |
| 173 | .timer_slack_ns = 50000, /* 50 usec default slack */ \ | ||
| 173 | .pids = { \ | 174 | .pids = { \ |
| 174 | [PIDTYPE_PID] = INIT_PID_LINK(PIDTYPE_PID), \ | 175 | [PIDTYPE_PID] = INIT_PID_LINK(PIDTYPE_PID), \ |
| 175 | [PIDTYPE_PGID] = INIT_PID_LINK(PIDTYPE_PGID), \ | 176 | [PIDTYPE_PGID] = INIT_PID_LINK(PIDTYPE_PGID), \ |
diff --git a/include/linux/leds.h b/include/linux/leds.h index d41ccb56146a..d3a73f5a48c3 100644 --- a/include/linux/leds.h +++ b/include/linux/leds.h | |||
| @@ -123,7 +123,7 @@ extern void ledtrig_ide_activity(void); | |||
| 123 | */ | 123 | */ |
| 124 | struct led_info { | 124 | struct led_info { |
| 125 | const char *name; | 125 | const char *name; |
| 126 | char *default_trigger; | 126 | const char *default_trigger; |
| 127 | int flags; | 127 | int flags; |
| 128 | }; | 128 | }; |
| 129 | 129 | ||
| @@ -135,7 +135,7 @@ struct led_platform_data { | |||
| 135 | /* For the leds-gpio driver */ | 135 | /* For the leds-gpio driver */ |
| 136 | struct gpio_led { | 136 | struct gpio_led { |
| 137 | const char *name; | 137 | const char *name; |
| 138 | char *default_trigger; | 138 | const char *default_trigger; |
| 139 | unsigned gpio; | 139 | unsigned gpio; |
| 140 | u8 active_low; | 140 | u8 active_low; |
| 141 | }; | 141 | }; |
diff --git a/include/linux/libata.h b/include/linux/libata.h index c261aa0584b1..507f53ef8038 100644 --- a/include/linux/libata.h +++ b/include/linux/libata.h | |||
| @@ -695,7 +695,6 @@ struct ata_port { | |||
| 695 | unsigned int cbl; /* cable type; ATA_CBL_xxx */ | 695 | unsigned int cbl; /* cable type; ATA_CBL_xxx */ |
| 696 | 696 | ||
| 697 | struct ata_queued_cmd qcmd[ATA_MAX_QUEUE]; | 697 | struct ata_queued_cmd qcmd[ATA_MAX_QUEUE]; |
| 698 | unsigned long qc_allocated; | ||
| 699 | unsigned int qc_active; | 698 | unsigned int qc_active; |
| 700 | int nr_active_links; /* #links with active qcs */ | 699 | int nr_active_links; /* #links with active qcs */ |
| 701 | 700 | ||
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 64875859d654..c8bcb59adfdf 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
| @@ -541,6 +541,14 @@ struct net_device | |||
| 541 | #define NETIF_F_V6_CSUM (NETIF_F_GEN_CSUM | NETIF_F_IPV6_CSUM) | 541 | #define NETIF_F_V6_CSUM (NETIF_F_GEN_CSUM | NETIF_F_IPV6_CSUM) |
| 542 | #define NETIF_F_ALL_CSUM (NETIF_F_V4_CSUM | NETIF_F_V6_CSUM) | 542 | #define NETIF_F_ALL_CSUM (NETIF_F_V4_CSUM | NETIF_F_V6_CSUM) |
| 543 | 543 | ||
| 544 | /* | ||
| 545 | * If one device supports one of these features, then enable them | ||
| 546 | * for all in netdev_increment_features. | ||
| 547 | */ | ||
| 548 | #define NETIF_F_ONE_FOR_ALL (NETIF_F_GSO_SOFTWARE | NETIF_F_GSO_ROBUST | \ | ||
| 549 | NETIF_F_SG | NETIF_F_HIGHDMA | \ | ||
| 550 | NETIF_F_FRAGLIST) | ||
| 551 | |||
| 544 | /* Interface index. Unique device identifier */ | 552 | /* Interface index. Unique device identifier */ |
| 545 | int ifindex; | 553 | int ifindex; |
| 546 | int iflink; | 554 | int iflink; |
| @@ -1698,7 +1706,9 @@ extern char *netdev_drivername(const struct net_device *dev, char *buffer, int l | |||
| 1698 | 1706 | ||
| 1699 | extern void linkwatch_run_queue(void); | 1707 | extern void linkwatch_run_queue(void); |
| 1700 | 1708 | ||
| 1701 | extern int netdev_compute_features(unsigned long all, unsigned long one); | 1709 | unsigned long netdev_increment_features(unsigned long all, unsigned long one, |
| 1710 | unsigned long mask); | ||
| 1711 | unsigned long netdev_fix_features(unsigned long features, const char *name); | ||
| 1702 | 1712 | ||
| 1703 | static inline int net_gso_ok(int features, int gso_type) | 1713 | static inline int net_gso_ok(int features, int gso_type) |
| 1704 | { | 1714 | { |
diff --git a/include/linux/poll.h b/include/linux/poll.h index ef453828877a..badd98ab06f6 100644 --- a/include/linux/poll.h +++ b/include/linux/poll.h | |||
| @@ -114,11 +114,13 @@ void zero_fd_set(unsigned long nr, unsigned long *fdset) | |||
| 114 | 114 | ||
| 115 | #define MAX_INT64_SECONDS (((s64)(~((u64)0)>>1)/HZ)-1) | 115 | #define MAX_INT64_SECONDS (((s64)(~((u64)0)>>1)/HZ)-1) |
| 116 | 116 | ||
| 117 | extern int do_select(int n, fd_set_bits *fds, s64 *timeout); | 117 | extern int do_select(int n, fd_set_bits *fds, struct timespec *end_time); |
| 118 | extern int do_sys_poll(struct pollfd __user * ufds, unsigned int nfds, | 118 | extern int do_sys_poll(struct pollfd __user * ufds, unsigned int nfds, |
| 119 | s64 *timeout); | 119 | struct timespec *end_time); |
| 120 | extern int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, | 120 | extern int core_sys_select(int n, fd_set __user *inp, fd_set __user *outp, |
| 121 | fd_set __user *exp, s64 *timeout); | 121 | fd_set __user *exp, struct timespec *end_time); |
| 122 | |||
| 123 | extern int poll_select_set_timeout(struct timespec *to, long sec, long nsec); | ||
| 122 | 124 | ||
| 123 | #endif /* KERNEL */ | 125 | #endif /* KERNEL */ |
| 124 | 126 | ||
diff --git a/include/linux/prctl.h b/include/linux/prctl.h index 5ad79198d6f9..48d887e3c6e7 100644 --- a/include/linux/prctl.h +++ b/include/linux/prctl.h | |||
| @@ -78,4 +78,11 @@ | |||
| 78 | #define PR_GET_SECUREBITS 27 | 78 | #define PR_GET_SECUREBITS 27 |
| 79 | #define PR_SET_SECUREBITS 28 | 79 | #define PR_SET_SECUREBITS 28 |
| 80 | 80 | ||
| 81 | /* | ||
| 82 | * Get/set the timerslack as used by poll/select/nanosleep | ||
| 83 | * A value of 0 means "use default" | ||
| 84 | */ | ||
| 85 | #define PR_SET_TIMERSLACK 29 | ||
| 86 | #define PR_GET_TIMERSLACK 30 | ||
| 87 | |||
| 81 | #endif /* _LINUX_PRCTL_H */ | 88 | #endif /* _LINUX_PRCTL_H */ |
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index 27d534f4470d..b8bdb96eff78 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h | |||
| @@ -97,12 +97,9 @@ struct vmcore { | |||
| 97 | 97 | ||
| 98 | #ifdef CONFIG_PROC_FS | 98 | #ifdef CONFIG_PROC_FS |
| 99 | 99 | ||
| 100 | extern struct proc_dir_entry *proc_root_kcore; | ||
| 101 | |||
| 102 | extern spinlock_t proc_subdir_lock; | 100 | extern spinlock_t proc_subdir_lock; |
| 103 | 101 | ||
| 104 | extern void proc_root_init(void); | 102 | extern void proc_root_init(void); |
| 105 | extern void proc_misc_init(void); | ||
| 106 | 103 | ||
| 107 | void proc_flush_task(struct task_struct *task); | 104 | void proc_flush_task(struct task_struct *task); |
| 108 | struct dentry *proc_pid_lookup(struct inode *dir, struct dentry * dentry, struct nameidata *); | 105 | struct dentry *proc_pid_lookup(struct inode *dir, struct dentry * dentry, struct nameidata *); |
| @@ -138,8 +135,6 @@ extern struct inode *proc_get_inode(struct super_block *, unsigned int, struct p | |||
| 138 | extern int proc_readdir(struct file *, void *, filldir_t); | 135 | extern int proc_readdir(struct file *, void *, filldir_t); |
| 139 | extern struct dentry *proc_lookup(struct inode *, struct dentry *, struct nameidata *); | 136 | extern struct dentry *proc_lookup(struct inode *, struct dentry *, struct nameidata *); |
| 140 | 137 | ||
| 141 | extern const struct file_operations proc_kcore_operations; | ||
| 142 | |||
| 143 | extern int pid_ns_prepare_proc(struct pid_namespace *ns); | 138 | extern int pid_ns_prepare_proc(struct pid_namespace *ns); |
| 144 | extern void pid_ns_release_proc(struct pid_namespace *ns); | 139 | extern void pid_ns_release_proc(struct pid_namespace *ns); |
| 145 | 140 | ||
diff --git a/include/linux/sched.h b/include/linux/sched.h index 10bff55b0824..8478f334d732 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
| @@ -680,10 +680,6 @@ struct sched_info { | |||
| 680 | }; | 680 | }; |
| 681 | #endif /* defined(CONFIG_SCHEDSTATS) || defined(CONFIG_TASK_DELAY_ACCT) */ | 681 | #endif /* defined(CONFIG_SCHEDSTATS) || defined(CONFIG_TASK_DELAY_ACCT) */ |
| 682 | 682 | ||
| 683 | #ifdef CONFIG_SCHEDSTATS | ||
| 684 | extern const struct file_operations proc_schedstat_operations; | ||
| 685 | #endif /* CONFIG_SCHEDSTATS */ | ||
| 686 | |||
| 687 | #ifdef CONFIG_TASK_DELAY_ACCT | 683 | #ifdef CONFIG_TASK_DELAY_ACCT |
| 688 | struct task_delay_info { | 684 | struct task_delay_info { |
| 689 | spinlock_t lock; | 685 | spinlock_t lock; |
| @@ -1345,6 +1341,12 @@ struct task_struct { | |||
| 1345 | int latency_record_count; | 1341 | int latency_record_count; |
| 1346 | struct latency_record latency_record[LT_SAVECOUNT]; | 1342 | struct latency_record latency_record[LT_SAVECOUNT]; |
| 1347 | #endif | 1343 | #endif |
| 1344 | /* | ||
| 1345 | * time slack values; these are used to round up poll() and | ||
| 1346 | * select() etc timeout values. These are in nanoseconds. | ||
| 1347 | */ | ||
| 1348 | unsigned long timer_slack_ns; | ||
| 1349 | unsigned long default_timer_slack_ns; | ||
| 1348 | }; | 1350 | }; |
| 1349 | 1351 | ||
| 1350 | /* | 1352 | /* |
diff --git a/include/linux/slab.h b/include/linux/slab.h index 5ff9676c1e2c..ba965c84ae06 100644 --- a/include/linux/slab.h +++ b/include/linux/slab.h | |||
| @@ -288,9 +288,4 @@ static inline void *kzalloc_node(size_t size, gfp_t flags, int node) | |||
| 288 | return kmalloc_node(size, flags | __GFP_ZERO, node); | 288 | return kmalloc_node(size, flags | __GFP_ZERO, node); |
| 289 | } | 289 | } |
| 290 | 290 | ||
| 291 | #ifdef CONFIG_SLABINFO | ||
| 292 | extern const struct seq_operations slabinfo_op; | ||
| 293 | ssize_t slabinfo_write(struct file *, const char __user *, size_t, loff_t *); | ||
| 294 | #endif | ||
| 295 | |||
| 296 | #endif /* _LINUX_SLAB_H */ | 291 | #endif /* _LINUX_SLAB_H */ |
diff --git a/include/linux/smc911x.h b/include/linux/smc911x.h index b58f54c24183..521f37143fae 100644 --- a/include/linux/smc911x.h +++ b/include/linux/smc911x.h | |||
| @@ -7,6 +7,7 @@ | |||
| 7 | struct smc911x_platdata { | 7 | struct smc911x_platdata { |
| 8 | unsigned long flags; | 8 | unsigned long flags; |
| 9 | unsigned long irq_flags; /* IRQF_... */ | 9 | unsigned long irq_flags; /* IRQF_... */ |
| 10 | int irq_polarity; | ||
| 10 | }; | 11 | }; |
| 11 | 12 | ||
| 12 | #endif /* __SMC911X_H__ */ | 13 | #endif /* __SMC911X_H__ */ |
diff --git a/include/linux/thread_info.h b/include/linux/thread_info.h index 38a56477f27a..e6b820f8b56b 100644 --- a/include/linux/thread_info.h +++ b/include/linux/thread_info.h | |||
| @@ -38,6 +38,14 @@ struct restart_block { | |||
| 38 | #endif | 38 | #endif |
| 39 | u64 expires; | 39 | u64 expires; |
| 40 | } nanosleep; | 40 | } nanosleep; |
| 41 | /* For poll */ | ||
| 42 | struct { | ||
| 43 | struct pollfd __user *ufds; | ||
| 44 | int nfds; | ||
| 45 | int has_timeout; | ||
| 46 | unsigned long tv_sec; | ||
| 47 | unsigned long tv_nsec; | ||
| 48 | } poll; | ||
| 41 | }; | 49 | }; |
| 42 | }; | 50 | }; |
| 43 | 51 | ||
diff --git a/include/linux/time.h b/include/linux/time.h index 4f1c9db57707..ce321ac5c8f8 100644 --- a/include/linux/time.h +++ b/include/linux/time.h | |||
| @@ -40,6 +40,8 @@ extern struct timezone sys_tz; | |||
| 40 | #define NSEC_PER_SEC 1000000000L | 40 | #define NSEC_PER_SEC 1000000000L |
| 41 | #define FSEC_PER_SEC 1000000000000000L | 41 | #define FSEC_PER_SEC 1000000000000000L |
| 42 | 42 | ||
| 43 | #define TIME_T_MAX (time_t)((1UL << ((sizeof(time_t) << 3) - 1)) - 1) | ||
| 44 | |||
| 43 | static inline int timespec_equal(const struct timespec *a, | 45 | static inline int timespec_equal(const struct timespec *a, |
| 44 | const struct timespec *b) | 46 | const struct timespec *b) |
| 45 | { | 47 | { |
| @@ -74,6 +76,8 @@ extern unsigned long mktime(const unsigned int year, const unsigned int mon, | |||
| 74 | const unsigned int min, const unsigned int sec); | 76 | const unsigned int min, const unsigned int sec); |
| 75 | 77 | ||
| 76 | extern void set_normalized_timespec(struct timespec *ts, time_t sec, long nsec); | 78 | extern void set_normalized_timespec(struct timespec *ts, time_t sec, long nsec); |
| 79 | extern struct timespec timespec_add_safe(const struct timespec lhs, | ||
| 80 | const struct timespec rhs); | ||
| 77 | 81 | ||
| 78 | /* | 82 | /* |
| 79 | * sub = lhs - rhs, in normalized form | 83 | * sub = lhs - rhs, in normalized form |
diff --git a/include/linux/vmalloc.h b/include/linux/vmalloc.h index 4c28c4d564e2..307b88577eaa 100644 --- a/include/linux/vmalloc.h +++ b/include/linux/vmalloc.h | |||
| @@ -103,6 +103,4 @@ extern void free_vm_area(struct vm_struct *area); | |||
| 103 | extern rwlock_t vmlist_lock; | 103 | extern rwlock_t vmlist_lock; |
| 104 | extern struct vm_struct *vmlist; | 104 | extern struct vm_struct *vmlist; |
| 105 | 105 | ||
| 106 | extern const struct seq_operations vmalloc_op; | ||
| 107 | |||
| 108 | #endif /* _LINUX_VMALLOC_H */ | 106 | #endif /* _LINUX_VMALLOC_H */ |
diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h index 9cd3ab0f554d..524cd1b28ecb 100644 --- a/include/linux/vmstat.h +++ b/include/linux/vmstat.h | |||
| @@ -54,10 +54,6 @@ enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT, | |||
| 54 | NR_VM_EVENT_ITEMS | 54 | NR_VM_EVENT_ITEMS |
| 55 | }; | 55 | }; |
| 56 | 56 | ||
| 57 | extern const struct seq_operations fragmentation_op; | ||
| 58 | extern const struct seq_operations pagetypeinfo_op; | ||
| 59 | extern const struct seq_operations zoneinfo_op; | ||
| 60 | extern const struct seq_operations vmstat_op; | ||
| 61 | extern int sysctl_stat_interval; | 57 | extern int sysctl_stat_interval; |
| 62 | 58 | ||
| 63 | #ifdef CONFIG_VM_EVENT_COUNTERS | 59 | #ifdef CONFIG_VM_EVENT_COUNTERS |
diff --git a/include/math-emu/op-common.h b/include/math-emu/op-common.h index cc1ec396f8d6..f456534dcaf9 100644 --- a/include/math-emu/op-common.h +++ b/include/math-emu/op-common.h | |||
| @@ -139,18 +139,27 @@ do { \ | |||
| 139 | if (X##_e <= _FP_WFRACBITS_##fs) \ | 139 | if (X##_e <= _FP_WFRACBITS_##fs) \ |
| 140 | { \ | 140 | { \ |
| 141 | _FP_FRAC_SRS_##wc(X, X##_e, _FP_WFRACBITS_##fs); \ | 141 | _FP_FRAC_SRS_##wc(X, X##_e, _FP_WFRACBITS_##fs); \ |
| 142 | _FP_ROUND(wc, X); \ | ||
| 143 | if (_FP_FRAC_HIGH_##fs(X) \ | 142 | if (_FP_FRAC_HIGH_##fs(X) \ |
| 144 | & (_FP_OVERFLOW_##fs >> 1)) \ | 143 | & (_FP_OVERFLOW_##fs >> 1)) \ |
| 145 | { \ | 144 | { \ |
| 146 | X##_e = 1; \ | 145 | X##_e = 1; \ |
| 147 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ | 146 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ |
| 148 | FP_SET_EXCEPTION(FP_EX_INEXACT); \ | ||
| 149 | } \ | 147 | } \ |
| 150 | else \ | 148 | else \ |
| 151 | { \ | 149 | { \ |
| 152 | X##_e = 0; \ | 150 | _FP_ROUND(wc, X); \ |
| 153 | _FP_FRAC_SRL_##wc(X, _FP_WORKBITS); \ | 151 | if (_FP_FRAC_HIGH_##fs(X) \ |
| 152 | & (_FP_OVERFLOW_##fs >> 1)) \ | ||
| 153 | { \ | ||
| 154 | X##_e = 1; \ | ||
| 155 | _FP_FRAC_SET_##wc(X, _FP_ZEROFRAC_##wc); \ | ||
| 156 | FP_SET_EXCEPTION(FP_EX_INEXACT); \ | ||
| 157 | } \ | ||
| 158 | else \ | ||
| 159 | { \ | ||
| 160 | X##_e = 0; \ | ||
| 161 | _FP_FRAC_SRL_##wc(X, _FP_WORKBITS); \ | ||
| 162 | } \ | ||
| 154 | } \ | 163 | } \ |
| 155 | if ((FP_CUR_EXCEPTIONS & FP_EX_INEXACT) || \ | 164 | if ((FP_CUR_EXCEPTIONS & FP_EX_INEXACT) || \ |
| 156 | (FP_TRAPPING_EXCEPTIONS & FP_EX_UNDERFLOW)) \ | 165 | (FP_TRAPPING_EXCEPTIONS & FP_EX_UNDERFLOW)) \ |
| @@ -494,6 +503,8 @@ do { \ | |||
| 494 | R##_c = FP_CLS_NAN; \ | 503 | R##_c = FP_CLS_NAN; \ |
| 495 | _FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \ | 504 | _FP_FRAC_SET_##wc(R, _FP_NANFRAC_##fs); \ |
| 496 | FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_IDI);\ | 505 | FP_SET_EXCEPTION(FP_EX_INVALID | FP_EX_INVALID_IDI);\ |
| 506 | break; \ | ||
| 507 | \ | ||
| 497 | case _FP_CLS_COMBINE(FP_CLS_ZERO,FP_CLS_ZERO): \ | 508 | case _FP_CLS_COMBINE(FP_CLS_ZERO,FP_CLS_ZERO): \ |
| 498 | R##_s = _FP_NANSIGN_##fs; \ | 509 | R##_s = _FP_NANSIGN_##fs; \ |
| 499 | R##_c = FP_CLS_NAN; \ | 510 | R##_c = FP_CLS_NAN; \ |
diff --git a/include/net/sctp/sm.h b/include/net/sctp/sm.h index 029a54a02396..c1dd89365833 100644 --- a/include/net/sctp/sm.h +++ b/include/net/sctp/sm.h | |||
| @@ -125,6 +125,7 @@ sctp_state_fn_t sctp_sf_beat_8_3; | |||
| 125 | sctp_state_fn_t sctp_sf_backbeat_8_3; | 125 | sctp_state_fn_t sctp_sf_backbeat_8_3; |
| 126 | sctp_state_fn_t sctp_sf_do_9_2_final; | 126 | sctp_state_fn_t sctp_sf_do_9_2_final; |
| 127 | sctp_state_fn_t sctp_sf_do_9_2_shutdown; | 127 | sctp_state_fn_t sctp_sf_do_9_2_shutdown; |
| 128 | sctp_state_fn_t sctp_sf_do_9_2_shut_ctsn; | ||
| 128 | sctp_state_fn_t sctp_sf_do_ecn_cwr; | 129 | sctp_state_fn_t sctp_sf_do_ecn_cwr; |
| 129 | sctp_state_fn_t sctp_sf_do_ecne; | 130 | sctp_state_fn_t sctp_sf_do_ecne; |
| 130 | sctp_state_fn_t sctp_sf_ootb; | 131 | sctp_state_fn_t sctp_sf_ootb; |
diff --git a/kernel/exec_domain.c b/kernel/exec_domain.c index 0d407e886735..0511716e9424 100644 --- a/kernel/exec_domain.c +++ b/kernel/exec_domain.c | |||
| @@ -12,7 +12,9 @@ | |||
| 12 | #include <linux/kmod.h> | 12 | #include <linux/kmod.h> |
| 13 | #include <linux/module.h> | 13 | #include <linux/module.h> |
| 14 | #include <linux/personality.h> | 14 | #include <linux/personality.h> |
| 15 | #include <linux/proc_fs.h> | ||
| 15 | #include <linux/sched.h> | 16 | #include <linux/sched.h> |
| 17 | #include <linux/seq_file.h> | ||
| 16 | #include <linux/syscalls.h> | 18 | #include <linux/syscalls.h> |
| 17 | #include <linux/sysctl.h> | 19 | #include <linux/sysctl.h> |
| 18 | #include <linux/types.h> | 20 | #include <linux/types.h> |
| @@ -173,20 +175,39 @@ __set_personality(u_long personality) | |||
| 173 | return 0; | 175 | return 0; |
| 174 | } | 176 | } |
| 175 | 177 | ||
| 176 | int | 178 | #ifdef CONFIG_PROC_FS |
| 177 | get_exec_domain_list(char *page) | 179 | static int execdomains_proc_show(struct seq_file *m, void *v) |
| 178 | { | 180 | { |
| 179 | struct exec_domain *ep; | 181 | struct exec_domain *ep; |
| 180 | int len = 0; | ||
| 181 | 182 | ||
| 182 | read_lock(&exec_domains_lock); | 183 | read_lock(&exec_domains_lock); |
| 183 | for (ep = exec_domains; ep && len < PAGE_SIZE - 80; ep = ep->next) | 184 | for (ep = exec_domains; ep; ep = ep->next) |
| 184 | len += sprintf(page + len, "%d-%d\t%-16s\t[%s]\n", | 185 | seq_printf(m, "%d-%d\t%-16s\t[%s]\n", |
| 185 | ep->pers_low, ep->pers_high, ep->name, | 186 | ep->pers_low, ep->pers_high, ep->name, |
| 186 | module_name(ep->module)); | 187 | module_name(ep->module)); |
| 187 | read_unlock(&exec_domains_lock); | 188 | read_unlock(&exec_domains_lock); |
| 188 | return (len); | 189 | return 0; |
| 190 | } | ||
| 191 | |||
| 192 | static int execdomains_proc_open(struct inode *inode, struct file *file) | ||
| 193 | { | ||
| 194 | return single_open(file, execdomains_proc_show, NULL); | ||
| 195 | } | ||
| 196 | |||
| 197 | static const struct file_operations execdomains_proc_fops = { | ||
| 198 | .open = execdomains_proc_open, | ||
| 199 | .read = seq_read, | ||
| 200 | .llseek = seq_lseek, | ||
| 201 | .release = single_release, | ||
| 202 | }; | ||
| 203 | |||
| 204 | static int __init proc_execdomains_init(void) | ||
| 205 | { | ||
| 206 | proc_create("execdomains", 0, NULL, &execdomains_proc_fops); | ||
| 207 | return 0; | ||
| 189 | } | 208 | } |
| 209 | module_init(proc_execdomains_init); | ||
| 210 | #endif | ||
| 190 | 211 | ||
| 191 | asmlinkage long | 212 | asmlinkage long |
| 192 | sys_personality(u_long personality) | 213 | sys_personality(u_long personality) |
diff --git a/kernel/fork.c b/kernel/fork.c index 4d093552dd6e..f6083561dfe0 100644 --- a/kernel/fork.c +++ b/kernel/fork.c | |||
| @@ -1018,6 +1018,8 @@ static struct task_struct *copy_process(unsigned long clone_flags, | |||
| 1018 | p->prev_utime = cputime_zero; | 1018 | p->prev_utime = cputime_zero; |
| 1019 | p->prev_stime = cputime_zero; | 1019 | p->prev_stime = cputime_zero; |
| 1020 | 1020 | ||
| 1021 | p->default_timer_slack_ns = current->timer_slack_ns; | ||
| 1022 | |||
| 1021 | #ifdef CONFIG_DETECT_SOFTLOCKUP | 1023 | #ifdef CONFIG_DETECT_SOFTLOCKUP |
| 1022 | p->last_switch_count = 0; | 1024 | p->last_switch_count = 0; |
| 1023 | p->last_switch_timestamp = 0; | 1025 | p->last_switch_timestamp = 0; |
diff --git a/kernel/futex.c b/kernel/futex.c index 7d1136e97c14..8af10027514b 100644 --- a/kernel/futex.c +++ b/kernel/futex.c | |||
| @@ -1296,13 +1296,16 @@ static int futex_wait(u32 __user *uaddr, struct rw_semaphore *fshared, | |||
| 1296 | if (!abs_time) | 1296 | if (!abs_time) |
| 1297 | schedule(); | 1297 | schedule(); |
| 1298 | else { | 1298 | else { |
| 1299 | unsigned long slack; | ||
| 1300 | slack = current->timer_slack_ns; | ||
| 1301 | if (rt_task(current)) | ||
| 1302 | slack = 0; | ||
| 1299 | hrtimer_init_on_stack(&t.timer, CLOCK_MONOTONIC, | 1303 | hrtimer_init_on_stack(&t.timer, CLOCK_MONOTONIC, |
| 1300 | HRTIMER_MODE_ABS); | 1304 | HRTIMER_MODE_ABS); |
| 1301 | hrtimer_init_sleeper(&t, current); | 1305 | hrtimer_init_sleeper(&t, current); |
| 1302 | t.timer.expires = *abs_time; | 1306 | hrtimer_set_expires_range_ns(&t.timer, *abs_time, slack); |
| 1303 | 1307 | ||
| 1304 | hrtimer_start(&t.timer, t.timer.expires, | 1308 | hrtimer_start_expires(&t.timer, HRTIMER_MODE_ABS); |
| 1305 | HRTIMER_MODE_ABS); | ||
| 1306 | if (!hrtimer_active(&t.timer)) | 1309 | if (!hrtimer_active(&t.timer)) |
| 1307 | t.task = NULL; | 1310 | t.task = NULL; |
| 1308 | 1311 | ||
| @@ -1404,7 +1407,7 @@ static int futex_lock_pi(u32 __user *uaddr, struct rw_semaphore *fshared, | |||
| 1404 | hrtimer_init_on_stack(&to->timer, CLOCK_REALTIME, | 1407 | hrtimer_init_on_stack(&to->timer, CLOCK_REALTIME, |
| 1405 | HRTIMER_MODE_ABS); | 1408 | HRTIMER_MODE_ABS); |
| 1406 | hrtimer_init_sleeper(to, current); | 1409 | hrtimer_init_sleeper(to, current); |
| 1407 | to->timer.expires = *time; | 1410 | hrtimer_set_expires(&to->timer, *time); |
| 1408 | } | 1411 | } |
| 1409 | 1412 | ||
| 1410 | q.pi_state = NULL; | 1413 | q.pi_state = NULL; |
diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c index 95978f48e039..2b465dfde426 100644 --- a/kernel/hrtimer.c +++ b/kernel/hrtimer.c | |||
| @@ -517,7 +517,7 @@ static void hrtimer_force_reprogram(struct hrtimer_cpu_base *cpu_base) | |||
| 517 | if (!base->first) | 517 | if (!base->first) |
| 518 | continue; | 518 | continue; |
| 519 | timer = rb_entry(base->first, struct hrtimer, node); | 519 | timer = rb_entry(base->first, struct hrtimer, node); |
| 520 | expires = ktime_sub(timer->expires, base->offset); | 520 | expires = ktime_sub(hrtimer_get_expires(timer), base->offset); |
| 521 | if (expires.tv64 < cpu_base->expires_next.tv64) | 521 | if (expires.tv64 < cpu_base->expires_next.tv64) |
| 522 | cpu_base->expires_next = expires; | 522 | cpu_base->expires_next = expires; |
| 523 | } | 523 | } |
| @@ -539,10 +539,10 @@ static int hrtimer_reprogram(struct hrtimer *timer, | |||
| 539 | struct hrtimer_clock_base *base) | 539 | struct hrtimer_clock_base *base) |
| 540 | { | 540 | { |
| 541 | ktime_t *expires_next = &__get_cpu_var(hrtimer_bases).expires_next; | 541 | ktime_t *expires_next = &__get_cpu_var(hrtimer_bases).expires_next; |
| 542 | ktime_t expires = ktime_sub(timer->expires, base->offset); | 542 | ktime_t expires = ktime_sub(hrtimer_get_expires(timer), base->offset); |
| 543 | int res; | 543 | int res; |
| 544 | 544 | ||
| 545 | WARN_ON_ONCE(timer->expires.tv64 < 0); | 545 | WARN_ON_ONCE(hrtimer_get_expires_tv64(timer) < 0); |
| 546 | 546 | ||
| 547 | /* | 547 | /* |
| 548 | * When the callback is running, we do not reprogram the clock event | 548 | * When the callback is running, we do not reprogram the clock event |
| @@ -795,7 +795,7 @@ u64 hrtimer_forward(struct hrtimer *timer, ktime_t now, ktime_t interval) | |||
| 795 | u64 orun = 1; | 795 | u64 orun = 1; |
| 796 | ktime_t delta; | 796 | ktime_t delta; |
| 797 | 797 | ||
| 798 | delta = ktime_sub(now, timer->expires); | 798 | delta = ktime_sub(now, hrtimer_get_expires(timer)); |
| 799 | 799 | ||
| 800 | if (delta.tv64 < 0) | 800 | if (delta.tv64 < 0) |
| 801 | return 0; | 801 | return 0; |
| @@ -807,8 +807,8 @@ u64 hrtimer_forward(struct hrtimer *timer, ktime_t now, ktime_t interval) | |||
| 807 | s64 incr = ktime_to_ns(interval); | 807 | s64 incr = ktime_to_ns(interval); |
| 808 | 808 | ||
| 809 | orun = ktime_divns(delta, incr); | 809 | orun = ktime_divns(delta, incr); |
| 810 | timer->expires = ktime_add_ns(timer->expires, incr * orun); | 810 | hrtimer_add_expires_ns(timer, incr * orun); |
| 811 | if (timer->expires.tv64 > now.tv64) | 811 | if (hrtimer_get_expires_tv64(timer) > now.tv64) |
| 812 | return orun; | 812 | return orun; |
| 813 | /* | 813 | /* |
| 814 | * This (and the ktime_add() below) is the | 814 | * This (and the ktime_add() below) is the |
| @@ -816,7 +816,7 @@ u64 hrtimer_forward(struct hrtimer *timer, ktime_t now, ktime_t interval) | |||
| 816 | */ | 816 | */ |
| 817 | orun++; | 817 | orun++; |
| 818 | } | 818 | } |
| 819 | timer->expires = ktime_add_safe(timer->expires, interval); | 819 | hrtimer_add_expires(timer, interval); |
| 820 | 820 | ||
| 821 | return orun; | 821 | return orun; |
| 822 | } | 822 | } |
| @@ -848,7 +848,8 @@ static void enqueue_hrtimer(struct hrtimer *timer, | |||
| 848 | * We dont care about collisions. Nodes with | 848 | * We dont care about collisions. Nodes with |
| 849 | * the same expiry time stay together. | 849 | * the same expiry time stay together. |
| 850 | */ | 850 | */ |
| 851 | if (timer->expires.tv64 < entry->expires.tv64) { | 851 | if (hrtimer_get_expires_tv64(timer) < |
| 852 | hrtimer_get_expires_tv64(entry)) { | ||
| 852 | link = &(*link)->rb_left; | 853 | link = &(*link)->rb_left; |
| 853 | } else { | 854 | } else { |
| 854 | link = &(*link)->rb_right; | 855 | link = &(*link)->rb_right; |
| @@ -945,9 +946,10 @@ remove_hrtimer(struct hrtimer *timer, struct hrtimer_clock_base *base) | |||
| 945 | } | 946 | } |
| 946 | 947 | ||
| 947 | /** | 948 | /** |
| 948 | * hrtimer_start - (re)start an relative timer on the current CPU | 949 | * hrtimer_start_range_ns - (re)start an hrtimer on the current CPU |
| 949 | * @timer: the timer to be added | 950 | * @timer: the timer to be added |
| 950 | * @tim: expiry time | 951 | * @tim: expiry time |
| 952 | * @delta_ns: "slack" range for the timer | ||
| 951 | * @mode: expiry mode: absolute (HRTIMER_ABS) or relative (HRTIMER_REL) | 953 | * @mode: expiry mode: absolute (HRTIMER_ABS) or relative (HRTIMER_REL) |
| 952 | * | 954 | * |
| 953 | * Returns: | 955 | * Returns: |
| @@ -955,7 +957,8 @@ remove_hrtimer(struct hrtimer *timer, struct hrtimer_clock_base *base) | |||
| 955 | * 1 when the timer was active | 957 | * 1 when the timer was active |
| 956 | */ | 958 | */ |
| 957 | int | 959 | int |
| 958 | hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode) | 960 | hrtimer_start_range_ns(struct hrtimer *timer, ktime_t tim, unsigned long delta_ns, |
| 961 | const enum hrtimer_mode mode) | ||
| 959 | { | 962 | { |
| 960 | struct hrtimer_clock_base *base, *new_base; | 963 | struct hrtimer_clock_base *base, *new_base; |
| 961 | unsigned long flags; | 964 | unsigned long flags; |
| @@ -983,7 +986,7 @@ hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode) | |||
| 983 | #endif | 986 | #endif |
| 984 | } | 987 | } |
| 985 | 988 | ||
| 986 | timer->expires = tim; | 989 | hrtimer_set_expires_range_ns(timer, tim, delta_ns); |
| 987 | 990 | ||
| 988 | timer_stats_hrtimer_set_start_info(timer); | 991 | timer_stats_hrtimer_set_start_info(timer); |
| 989 | 992 | ||
| @@ -1016,8 +1019,26 @@ hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode) | |||
| 1016 | 1019 | ||
| 1017 | return ret; | 1020 | return ret; |
| 1018 | } | 1021 | } |
| 1022 | EXPORT_SYMBOL_GPL(hrtimer_start_range_ns); | ||
| 1023 | |||
| 1024 | /** | ||
| 1025 | * hrtimer_start - (re)start an hrtimer on the current CPU | ||
| 1026 | * @timer: the timer to be added | ||
| 1027 | * @tim: expiry time | ||
| 1028 | * @mode: expiry mode: absolute (HRTIMER_ABS) or relative (HRTIMER_REL) | ||
| 1029 | * | ||
| 1030 | * Returns: | ||
| 1031 | * 0 on success | ||
| 1032 | * 1 when the timer was active | ||
| 1033 | */ | ||
| 1034 | int | ||
| 1035 | hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode) | ||
| 1036 | { | ||
| 1037 | return hrtimer_start_range_ns(timer, tim, 0, mode); | ||
| 1038 | } | ||
| 1019 | EXPORT_SYMBOL_GPL(hrtimer_start); | 1039 | EXPORT_SYMBOL_GPL(hrtimer_start); |
| 1020 | 1040 | ||
| 1041 | |||
| 1021 | /** | 1042 | /** |
| 1022 | * hrtimer_try_to_cancel - try to deactivate a timer | 1043 | * hrtimer_try_to_cancel - try to deactivate a timer |
| 1023 | * @timer: hrtimer to stop | 1044 | * @timer: hrtimer to stop |
| @@ -1077,7 +1098,7 @@ ktime_t hrtimer_get_remaining(const struct hrtimer *timer) | |||
| 1077 | ktime_t rem; | 1098 | ktime_t rem; |
| 1078 | 1099 | ||
| 1079 | base = lock_hrtimer_base(timer, &flags); | 1100 | base = lock_hrtimer_base(timer, &flags); |
| 1080 | rem = ktime_sub(timer->expires, base->get_time()); | 1101 | rem = hrtimer_expires_remaining(timer); |
| 1081 | unlock_hrtimer_base(timer, &flags); | 1102 | unlock_hrtimer_base(timer, &flags); |
| 1082 | 1103 | ||
| 1083 | return rem; | 1104 | return rem; |
| @@ -1109,7 +1130,7 @@ ktime_t hrtimer_get_next_event(void) | |||
| 1109 | continue; | 1130 | continue; |
| 1110 | 1131 | ||
| 1111 | timer = rb_entry(base->first, struct hrtimer, node); | 1132 | timer = rb_entry(base->first, struct hrtimer, node); |
| 1112 | delta.tv64 = timer->expires.tv64; | 1133 | delta.tv64 = hrtimer_get_expires_tv64(timer); |
| 1113 | delta = ktime_sub(delta, base->get_time()); | 1134 | delta = ktime_sub(delta, base->get_time()); |
| 1114 | if (delta.tv64 < mindelta.tv64) | 1135 | if (delta.tv64 < mindelta.tv64) |
| 1115 | mindelta.tv64 = delta.tv64; | 1136 | mindelta.tv64 = delta.tv64; |
| @@ -1310,10 +1331,23 @@ void hrtimer_interrupt(struct clock_event_device *dev) | |||
| 1310 | 1331 | ||
| 1311 | timer = rb_entry(node, struct hrtimer, node); | 1332 | timer = rb_entry(node, struct hrtimer, node); |
| 1312 | 1333 | ||
| 1313 | if (basenow.tv64 < timer->expires.tv64) { | 1334 | /* |
| 1335 | * The immediate goal for using the softexpires is | ||
| 1336 | * minimizing wakeups, not running timers at the | ||
| 1337 | * earliest interrupt after their soft expiration. | ||
| 1338 | * This allows us to avoid using a Priority Search | ||
| 1339 | * Tree, which can answer a stabbing querry for | ||
| 1340 | * overlapping intervals and instead use the simple | ||
| 1341 | * BST we already have. | ||
| 1342 | * We don't add extra wakeups by delaying timers that | ||
| 1343 | * are right-of a not yet expired timer, because that | ||
| 1344 | * timer will have to trigger a wakeup anyway. | ||
| 1345 | */ | ||
| 1346 | |||
| 1347 | if (basenow.tv64 < hrtimer_get_softexpires_tv64(timer)) { | ||
| 1314 | ktime_t expires; | 1348 | ktime_t expires; |
| 1315 | 1349 | ||
| 1316 | expires = ktime_sub(timer->expires, | 1350 | expires = ktime_sub(hrtimer_get_expires(timer), |
| 1317 | base->offset); | 1351 | base->offset); |
| 1318 | if (expires.tv64 < expires_next.tv64) | 1352 | if (expires.tv64 < expires_next.tv64) |
| 1319 | expires_next = expires; | 1353 | expires_next = expires; |
| @@ -1349,6 +1383,30 @@ void hrtimer_interrupt(struct clock_event_device *dev) | |||
| 1349 | raise_softirq(HRTIMER_SOFTIRQ); | 1383 | raise_softirq(HRTIMER_SOFTIRQ); |
| 1350 | } | 1384 | } |
| 1351 | 1385 | ||
| 1386 | /** | ||
| 1387 | * hrtimer_peek_ahead_timers -- run soft-expired timers now | ||
| 1388 | * | ||
| 1389 | * hrtimer_peek_ahead_timers will peek at the timer queue of | ||
| 1390 | * the current cpu and check if there are any timers for which | ||
| 1391 | * the soft expires time has passed. If any such timers exist, | ||
| 1392 | * they are run immediately and then removed from the timer queue. | ||
| 1393 | * | ||
| 1394 | */ | ||
| 1395 | void hrtimer_peek_ahead_timers(void) | ||
| 1396 | { | ||
| 1397 | struct tick_device *td; | ||
| 1398 | unsigned long flags; | ||
| 1399 | |||
| 1400 | if (!hrtimer_hres_active()) | ||
| 1401 | return; | ||
| 1402 | |||
| 1403 | local_irq_save(flags); | ||
| 1404 | td = &__get_cpu_var(tick_cpu_device); | ||
| 1405 | if (td && td->evtdev) | ||
| 1406 | hrtimer_interrupt(td->evtdev); | ||
| 1407 | local_irq_restore(flags); | ||
| 1408 | } | ||
| 1409 | |||
| 1352 | static void run_hrtimer_softirq(struct softirq_action *h) | 1410 | static void run_hrtimer_softirq(struct softirq_action *h) |
| 1353 | { | 1411 | { |
| 1354 | run_hrtimer_pending(&__get_cpu_var(hrtimer_bases)); | 1412 | run_hrtimer_pending(&__get_cpu_var(hrtimer_bases)); |
| @@ -1414,7 +1472,8 @@ void hrtimer_run_queues(void) | |||
| 1414 | struct hrtimer *timer; | 1472 | struct hrtimer *timer; |
| 1415 | 1473 | ||
| 1416 | timer = rb_entry(node, struct hrtimer, node); | 1474 | timer = rb_entry(node, struct hrtimer, node); |
| 1417 | if (base->softirq_time.tv64 <= timer->expires.tv64) | 1475 | if (base->softirq_time.tv64 <= |
| 1476 | hrtimer_get_expires_tv64(timer)) | ||
| 1418 | break; | 1477 | break; |
| 1419 | 1478 | ||
| 1420 | if (timer->cb_mode == HRTIMER_CB_SOFTIRQ) { | 1479 | if (timer->cb_mode == HRTIMER_CB_SOFTIRQ) { |
| @@ -1462,7 +1521,7 @@ static int __sched do_nanosleep(struct hrtimer_sleeper *t, enum hrtimer_mode mod | |||
| 1462 | 1521 | ||
| 1463 | do { | 1522 | do { |
| 1464 | set_current_state(TASK_INTERRUPTIBLE); | 1523 | set_current_state(TASK_INTERRUPTIBLE); |
| 1465 | hrtimer_start(&t->timer, t->timer.expires, mode); | 1524 | hrtimer_start_expires(&t->timer, mode); |
| 1466 | if (!hrtimer_active(&t->timer)) | 1525 | if (!hrtimer_active(&t->timer)) |
| 1467 | t->task = NULL; | 1526 | t->task = NULL; |
| 1468 | 1527 | ||
| @@ -1484,7 +1543,7 @@ static int update_rmtp(struct hrtimer *timer, struct timespec __user *rmtp) | |||
| 1484 | struct timespec rmt; | 1543 | struct timespec rmt; |
| 1485 | ktime_t rem; | 1544 | ktime_t rem; |
| 1486 | 1545 | ||
| 1487 | rem = ktime_sub(timer->expires, timer->base->get_time()); | 1546 | rem = hrtimer_expires_remaining(timer); |
| 1488 | if (rem.tv64 <= 0) | 1547 | if (rem.tv64 <= 0) |
| 1489 | return 0; | 1548 | return 0; |
| 1490 | rmt = ktime_to_timespec(rem); | 1549 | rmt = ktime_to_timespec(rem); |
| @@ -1503,7 +1562,7 @@ long __sched hrtimer_nanosleep_restart(struct restart_block *restart) | |||
| 1503 | 1562 | ||
| 1504 | hrtimer_init_on_stack(&t.timer, restart->nanosleep.index, | 1563 | hrtimer_init_on_stack(&t.timer, restart->nanosleep.index, |
| 1505 | HRTIMER_MODE_ABS); | 1564 | HRTIMER_MODE_ABS); |
| 1506 | t.timer.expires.tv64 = restart->nanosleep.expires; | 1565 | hrtimer_set_expires_tv64(&t.timer, restart->nanosleep.expires); |
| 1507 | 1566 | ||
| 1508 | if (do_nanosleep(&t, HRTIMER_MODE_ABS)) | 1567 | if (do_nanosleep(&t, HRTIMER_MODE_ABS)) |
| 1509 | goto out; | 1568 | goto out; |
| @@ -1528,9 +1587,14 @@ long hrtimer_nanosleep(struct timespec *rqtp, struct timespec __user *rmtp, | |||
| 1528 | struct restart_block *restart; | 1587 | struct restart_block *restart; |
| 1529 | struct hrtimer_sleeper t; | 1588 | struct hrtimer_sleeper t; |
| 1530 | int ret = 0; | 1589 | int ret = 0; |
| 1590 | unsigned long slack; | ||
| 1591 | |||
| 1592 | slack = current->timer_slack_ns; | ||
| 1593 | if (rt_task(current)) | ||
| 1594 | slack = 0; | ||
| 1531 | 1595 | ||
| 1532 | hrtimer_init_on_stack(&t.timer, clockid, mode); | 1596 | hrtimer_init_on_stack(&t.timer, clockid, mode); |
| 1533 | t.timer.expires = timespec_to_ktime(*rqtp); | 1597 | hrtimer_set_expires_range_ns(&t.timer, timespec_to_ktime(*rqtp), slack); |
| 1534 | if (do_nanosleep(&t, mode)) | 1598 | if (do_nanosleep(&t, mode)) |
| 1535 | goto out; | 1599 | goto out; |
| 1536 | 1600 | ||
| @@ -1550,7 +1614,7 @@ long hrtimer_nanosleep(struct timespec *rqtp, struct timespec __user *rmtp, | |||
| 1550 | restart->fn = hrtimer_nanosleep_restart; | 1614 | restart->fn = hrtimer_nanosleep_restart; |
| 1551 | restart->nanosleep.index = t.timer.base->index; | 1615 | restart->nanosleep.index = t.timer.base->index; |
| 1552 | restart->nanosleep.rmtp = rmtp; | 1616 | restart->nanosleep.rmtp = rmtp; |
| 1553 | restart->nanosleep.expires = t.timer.expires.tv64; | 1617 | restart->nanosleep.expires = hrtimer_get_expires_tv64(&t.timer); |
| 1554 | 1618 | ||
| 1555 | ret = -ERESTART_RESTARTBLOCK; | 1619 | ret = -ERESTART_RESTARTBLOCK; |
| 1556 | out: | 1620 | out: |
| @@ -1752,3 +1816,103 @@ void __init hrtimers_init(void) | |||
| 1752 | #endif | 1816 | #endif |
| 1753 | } | 1817 | } |
| 1754 | 1818 | ||
| 1819 | /** | ||
| 1820 | * schedule_hrtimeout_range - sleep until timeout | ||
| 1821 | * @expires: timeout value (ktime_t) | ||
| 1822 | * @delta: slack in expires timeout (ktime_t) | ||
| 1823 | * @mode: timer mode, HRTIMER_MODE_ABS or HRTIMER_MODE_REL | ||
| 1824 | * | ||
| 1825 | * Make the current task sleep until the given expiry time has | ||
| 1826 | * elapsed. The routine will return immediately unless | ||
| 1827 | * the current task state has been set (see set_current_state()). | ||
| 1828 | * | ||
| 1829 | * The @delta argument gives the kernel the freedom to schedule the | ||
| 1830 | * actual wakeup to a time that is both power and performance friendly. | ||
| 1831 | * The kernel give the normal best effort behavior for "@expires+@delta", | ||
| 1832 | * but may decide to fire the timer earlier, but no earlier than @expires. | ||
| 1833 | * | ||
| 1834 | * You can set the task state as follows - | ||
| 1835 | * | ||
| 1836 | * %TASK_UNINTERRUPTIBLE - at least @timeout time is guaranteed to | ||
| 1837 | * pass before the routine returns. | ||
| 1838 | * | ||
| 1839 | * %TASK_INTERRUPTIBLE - the routine may return early if a signal is | ||
| 1840 | * delivered to the current task. | ||
| 1841 | * | ||
| 1842 | * The current task state is guaranteed to be TASK_RUNNING when this | ||
| 1843 | * routine returns. | ||
| 1844 | * | ||
| 1845 | * Returns 0 when the timer has expired otherwise -EINTR | ||
| 1846 | */ | ||
| 1847 | int __sched schedule_hrtimeout_range(ktime_t *expires, unsigned long delta, | ||
| 1848 | const enum hrtimer_mode mode) | ||
| 1849 | { | ||
| 1850 | struct hrtimer_sleeper t; | ||
| 1851 | |||
| 1852 | /* | ||
| 1853 | * Optimize when a zero timeout value is given. It does not | ||
| 1854 | * matter whether this is an absolute or a relative time. | ||
| 1855 | */ | ||
| 1856 | if (expires && !expires->tv64) { | ||
| 1857 | __set_current_state(TASK_RUNNING); | ||
| 1858 | return 0; | ||
| 1859 | } | ||
| 1860 | |||
| 1861 | /* | ||
| 1862 | * A NULL parameter means "inifinte" | ||
| 1863 | */ | ||
| 1864 | if (!expires) { | ||
| 1865 | schedule(); | ||
| 1866 | __set_current_state(TASK_RUNNING); | ||
| 1867 | return -EINTR; | ||
| 1868 | } | ||
| 1869 | |||
| 1870 | hrtimer_init_on_stack(&t.timer, CLOCK_MONOTONIC, mode); | ||
| 1871 | hrtimer_set_expires_range_ns(&t.timer, *expires, delta); | ||
| 1872 | |||
| 1873 | hrtimer_init_sleeper(&t, current); | ||
| 1874 | |||
| 1875 | hrtimer_start_expires(&t.timer, mode); | ||
| 1876 | if (!hrtimer_active(&t.timer)) | ||
| 1877 | t.task = NULL; | ||
| 1878 | |||
| 1879 | if (likely(t.task)) | ||
| 1880 | schedule(); | ||
| 1881 | |||
| 1882 | hrtimer_cancel(&t.timer); | ||
| 1883 | destroy_hrtimer_on_stack(&t.timer); | ||
| 1884 | |||
| 1885 | __set_current_state(TASK_RUNNING); | ||
| 1886 | |||
| 1887 | return !t.task ? 0 : -EINTR; | ||
| 1888 | } | ||
| 1889 | EXPORT_SYMBOL_GPL(schedule_hrtimeout_range); | ||
| 1890 | |||
| 1891 | /** | ||
| 1892 | * schedule_hrtimeout - sleep until timeout | ||
| 1893 | * @expires: timeout value (ktime_t) | ||
| 1894 | * @mode: timer mode, HRTIMER_MODE_ABS or HRTIMER_MODE_REL | ||
| 1895 | * | ||
| 1896 | * Make the current task sleep until the given expiry time has | ||
| 1897 | * elapsed. The routine will return immediately unless | ||
| 1898 | * the current task state has been set (see set_current_state()). | ||
| 1899 | * | ||
| 1900 | * You can set the task state as follows - | ||
| 1901 | * | ||
| 1902 | * %TASK_UNINTERRUPTIBLE - at least @timeout time is guaranteed to | ||
| 1903 | * pass before the routine returns. | ||
| 1904 | * | ||
| 1905 | * %TASK_INTERRUPTIBLE - the routine may return early if a signal is | ||
| 1906 | * delivered to the current task. | ||
| 1907 | * | ||
| 1908 | * The current task state is guaranteed to be TASK_RUNNING when this | ||
| 1909 | * routine returns. | ||
| 1910 | * | ||
| 1911 | * Returns 0 when the timer has expired otherwise -EINTR | ||
| 1912 | */ | ||
| 1913 | int __sched schedule_hrtimeout(ktime_t *expires, | ||
| 1914 | const enum hrtimer_mode mode) | ||
| 1915 | { | ||
| 1916 | return schedule_hrtimeout_range(expires, 0, mode); | ||
| 1917 | } | ||
| 1918 | EXPORT_SYMBOL_GPL(schedule_hrtimeout); | ||
diff --git a/kernel/module.c b/kernel/module.c index c0f1826e2d9e..1f4cc00e0c20 100644 --- a/kernel/module.c +++ b/kernel/module.c | |||
| @@ -20,11 +20,13 @@ | |||
| 20 | #include <linux/moduleloader.h> | 20 | #include <linux/moduleloader.h> |
| 21 | #include <linux/init.h> | 21 | #include <linux/init.h> |
| 22 | #include <linux/kallsyms.h> | 22 | #include <linux/kallsyms.h> |
| 23 | #include <linux/fs.h> | ||
| 23 | #include <linux/sysfs.h> | 24 | #include <linux/sysfs.h> |
| 24 | #include <linux/kernel.h> | 25 | #include <linux/kernel.h> |
| 25 | #include <linux/slab.h> | 26 | #include <linux/slab.h> |
| 26 | #include <linux/vmalloc.h> | 27 | #include <linux/vmalloc.h> |
| 27 | #include <linux/elf.h> | 28 | #include <linux/elf.h> |
| 29 | #include <linux/proc_fs.h> | ||
| 28 | #include <linux/seq_file.h> | 30 | #include <linux/seq_file.h> |
| 29 | #include <linux/syscalls.h> | 31 | #include <linux/syscalls.h> |
| 30 | #include <linux/fcntl.h> | 32 | #include <linux/fcntl.h> |
| @@ -2556,23 +2558,6 @@ unsigned long module_kallsyms_lookup_name(const char *name) | |||
| 2556 | } | 2558 | } |
| 2557 | #endif /* CONFIG_KALLSYMS */ | 2559 | #endif /* CONFIG_KALLSYMS */ |
| 2558 | 2560 | ||
| 2559 | /* Called by the /proc file system to return a list of modules. */ | ||
| 2560 | static void *m_start(struct seq_file *m, loff_t *pos) | ||
| 2561 | { | ||
| 2562 | mutex_lock(&module_mutex); | ||
| 2563 | return seq_list_start(&modules, *pos); | ||
| 2564 | } | ||
| 2565 | |||
| 2566 | static void *m_next(struct seq_file *m, void *p, loff_t *pos) | ||
| 2567 | { | ||
| 2568 | return seq_list_next(p, &modules, pos); | ||
| 2569 | } | ||
| 2570 | |||
| 2571 | static void m_stop(struct seq_file *m, void *p) | ||
| 2572 | { | ||
| 2573 | mutex_unlock(&module_mutex); | ||
| 2574 | } | ||
| 2575 | |||
| 2576 | static char *module_flags(struct module *mod, char *buf) | 2561 | static char *module_flags(struct module *mod, char *buf) |
| 2577 | { | 2562 | { |
| 2578 | int bx = 0; | 2563 | int bx = 0; |
| @@ -2606,6 +2591,24 @@ static char *module_flags(struct module *mod, char *buf) | |||
| 2606 | return buf; | 2591 | return buf; |
| 2607 | } | 2592 | } |
| 2608 | 2593 | ||
| 2594 | #ifdef CONFIG_PROC_FS | ||
| 2595 | /* Called by the /proc file system to return a list of modules. */ | ||
| 2596 | static void *m_start(struct seq_file *m, loff_t *pos) | ||
| 2597 | { | ||
| 2598 | mutex_lock(&module_mutex); | ||
| 2599 | return seq_list_start(&modules, *pos); | ||
| 2600 | } | ||
| 2601 | |||
| 2602 | static void *m_next(struct seq_file *m, void *p, loff_t *pos) | ||
| 2603 | { | ||
| 2604 | return seq_list_next(p, &modules, pos); | ||
| 2605 | } | ||
| 2606 | |||
| 2607 | static void m_stop(struct seq_file *m, void *p) | ||
| 2608 | { | ||
| 2609 | mutex_unlock(&module_mutex); | ||
| 2610 | } | ||
| 2611 | |||
| 2609 | static int m_show(struct seq_file *m, void *p) | 2612 | static int m_show(struct seq_file *m, void *p) |
| 2610 | { | 2613 | { |
| 2611 | struct module *mod = list_entry(p, struct module, list); | 2614 | struct module *mod = list_entry(p, struct module, list); |
| @@ -2636,13 +2639,33 @@ static int m_show(struct seq_file *m, void *p) | |||
| 2636 | Where refcount is a number or -, and deps is a comma-separated list | 2639 | Where refcount is a number or -, and deps is a comma-separated list |
| 2637 | of depends or -. | 2640 | of depends or -. |
| 2638 | */ | 2641 | */ |
| 2639 | const struct seq_operations modules_op = { | 2642 | static const struct seq_operations modules_op = { |
| 2640 | .start = m_start, | 2643 | .start = m_start, |
| 2641 | .next = m_next, | 2644 | .next = m_next, |
| 2642 | .stop = m_stop, | 2645 | .stop = m_stop, |
| 2643 | .show = m_show | 2646 | .show = m_show |
| 2644 | }; | 2647 | }; |
| 2645 | 2648 | ||
| 2649 | static int modules_open(struct inode *inode, struct file *file) | ||
| 2650 | { | ||
| 2651 | return seq_open(file, &modules_op); | ||
| 2652 | } | ||
| 2653 | |||
| 2654 | static const struct file_operations proc_modules_operations = { | ||
| 2655 | .open = modules_open, | ||
| 2656 | .read = seq_read, | ||
| 2657 | .llseek = seq_lseek, | ||
| 2658 | .release = seq_release, | ||
| 2659 | }; | ||
| 2660 | |||
| 2661 | static int __init proc_modules_init(void) | ||
| 2662 | { | ||
| 2663 | proc_create("modules", 0, NULL, &proc_modules_operations); | ||
| 2664 | return 0; | ||
| 2665 | } | ||
| 2666 | module_init(proc_modules_init); | ||
| 2667 | #endif | ||
| 2668 | |||
| 2646 | /* Given an address, look for it in the module exception tables. */ | 2669 | /* Given an address, look for it in the module exception tables. */ |
| 2647 | const struct exception_table_entry *search_module_extables(unsigned long addr) | 2670 | const struct exception_table_entry *search_module_extables(unsigned long addr) |
| 2648 | { | 2671 | { |
diff --git a/kernel/params.c b/kernel/params.c index b077f1b045d3..a1e3025b19a9 100644 --- a/kernel/params.c +++ b/kernel/params.c | |||
| @@ -510,6 +510,7 @@ fail: | |||
| 510 | return err; | 510 | return err; |
| 511 | } | 511 | } |
| 512 | 512 | ||
| 513 | #ifdef CONFIG_MODULES | ||
| 513 | static void free_module_param_attrs(struct module_kobject *mk) | 514 | static void free_module_param_attrs(struct module_kobject *mk) |
| 514 | { | 515 | { |
| 515 | kfree(mk->mp->grp.attrs); | 516 | kfree(mk->mp->grp.attrs); |
| @@ -517,7 +518,6 @@ static void free_module_param_attrs(struct module_kobject *mk) | |||
| 517 | mk->mp = NULL; | 518 | mk->mp = NULL; |
| 518 | } | 519 | } |
| 519 | 520 | ||
| 520 | #ifdef CONFIG_MODULES | ||
| 521 | /* | 521 | /* |
| 522 | * module_param_sysfs_setup - setup sysfs support for one module | 522 | * module_param_sysfs_setup - setup sysfs support for one module |
| 523 | * @mod: module | 523 | * @mod: module |
diff --git a/kernel/posix-timers.c b/kernel/posix-timers.c index b931d7cedbfa..5e79c662294b 100644 --- a/kernel/posix-timers.c +++ b/kernel/posix-timers.c | |||
| @@ -639,7 +639,7 @@ common_timer_get(struct k_itimer *timr, struct itimerspec *cur_setting) | |||
| 639 | (timr->it_sigev_notify & ~SIGEV_THREAD_ID) == SIGEV_NONE)) | 639 | (timr->it_sigev_notify & ~SIGEV_THREAD_ID) == SIGEV_NONE)) |
| 640 | timr->it_overrun += (unsigned int) hrtimer_forward(timer, now, iv); | 640 | timr->it_overrun += (unsigned int) hrtimer_forward(timer, now, iv); |
| 641 | 641 | ||
| 642 | remaining = ktime_sub(timer->expires, now); | 642 | remaining = ktime_sub(hrtimer_get_expires(timer), now); |
| 643 | /* Return 0 only, when the timer is expired and not pending */ | 643 | /* Return 0 only, when the timer is expired and not pending */ |
| 644 | if (remaining.tv64 <= 0) { | 644 | if (remaining.tv64 <= 0) { |
| 645 | /* | 645 | /* |
| @@ -733,7 +733,7 @@ common_timer_set(struct k_itimer *timr, int flags, | |||
| 733 | hrtimer_init(&timr->it.real.timer, timr->it_clock, mode); | 733 | hrtimer_init(&timr->it.real.timer, timr->it_clock, mode); |
| 734 | timr->it.real.timer.function = posix_timer_fn; | 734 | timr->it.real.timer.function = posix_timer_fn; |
| 735 | 735 | ||
| 736 | timer->expires = timespec_to_ktime(new_setting->it_value); | 736 | hrtimer_set_expires(timer, timespec_to_ktime(new_setting->it_value)); |
| 737 | 737 | ||
| 738 | /* Convert interval */ | 738 | /* Convert interval */ |
| 739 | timr->it.real.interval = timespec_to_ktime(new_setting->it_interval); | 739 | timr->it.real.interval = timespec_to_ktime(new_setting->it_interval); |
| @@ -742,14 +742,12 @@ common_timer_set(struct k_itimer *timr, int flags, | |||
| 742 | if (((timr->it_sigev_notify & ~SIGEV_THREAD_ID) == SIGEV_NONE)) { | 742 | if (((timr->it_sigev_notify & ~SIGEV_THREAD_ID) == SIGEV_NONE)) { |
| 743 | /* Setup correct expiry time for relative timers */ | 743 | /* Setup correct expiry time for relative timers */ |
| 744 | if (mode == HRTIMER_MODE_REL) { | 744 | if (mode == HRTIMER_MODE_REL) { |
| 745 | timer->expires = | 745 | hrtimer_add_expires(timer, timer->base->get_time()); |
| 746 | ktime_add_safe(timer->expires, | ||
| 747 | timer->base->get_time()); | ||
| 748 | } | 746 | } |
| 749 | return 0; | 747 | return 0; |
| 750 | } | 748 | } |
| 751 | 749 | ||
| 752 | hrtimer_start(timer, timer->expires, mode); | 750 | hrtimer_start_expires(timer, mode); |
| 753 | return 0; | 751 | return 0; |
| 754 | } | 752 | } |
| 755 | 753 | ||
diff --git a/kernel/rtmutex.c b/kernel/rtmutex.c index 6522ae5b14a2..69d9cb921ffa 100644 --- a/kernel/rtmutex.c +++ b/kernel/rtmutex.c | |||
| @@ -631,8 +631,7 @@ rt_mutex_slowlock(struct rt_mutex *lock, int state, | |||
| 631 | 631 | ||
| 632 | /* Setup the timer, when timeout != NULL */ | 632 | /* Setup the timer, when timeout != NULL */ |
| 633 | if (unlikely(timeout)) { | 633 | if (unlikely(timeout)) { |
| 634 | hrtimer_start(&timeout->timer, timeout->timer.expires, | 634 | hrtimer_start_expires(&timeout->timer, HRTIMER_MODE_ABS); |
| 635 | HRTIMER_MODE_ABS); | ||
| 636 | if (!hrtimer_active(&timeout->timer)) | 635 | if (!hrtimer_active(&timeout->timer)) |
| 637 | timeout->task = NULL; | 636 | timeout->task = NULL; |
| 638 | } | 637 | } |
diff --git a/kernel/sched.c b/kernel/sched.c index 945a97b9600d..6625c3c4b10d 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
| @@ -55,6 +55,7 @@ | |||
| 55 | #include <linux/cpuset.h> | 55 | #include <linux/cpuset.h> |
| 56 | #include <linux/percpu.h> | 56 | #include <linux/percpu.h> |
| 57 | #include <linux/kthread.h> | 57 | #include <linux/kthread.h> |
| 58 | #include <linux/proc_fs.h> | ||
| 58 | #include <linux/seq_file.h> | 59 | #include <linux/seq_file.h> |
| 59 | #include <linux/sysctl.h> | 60 | #include <linux/sysctl.h> |
| 60 | #include <linux/syscalls.h> | 61 | #include <linux/syscalls.h> |
| @@ -227,9 +228,8 @@ static void start_rt_bandwidth(struct rt_bandwidth *rt_b) | |||
| 227 | 228 | ||
| 228 | now = hrtimer_cb_get_time(&rt_b->rt_period_timer); | 229 | now = hrtimer_cb_get_time(&rt_b->rt_period_timer); |
| 229 | hrtimer_forward(&rt_b->rt_period_timer, now, rt_b->rt_period); | 230 | hrtimer_forward(&rt_b->rt_period_timer, now, rt_b->rt_period); |
| 230 | hrtimer_start(&rt_b->rt_period_timer, | 231 | hrtimer_start_expires(&rt_b->rt_period_timer, |
| 231 | rt_b->rt_period_timer.expires, | 232 | HRTIMER_MODE_ABS); |
| 232 | HRTIMER_MODE_ABS); | ||
| 233 | } | 233 | } |
| 234 | spin_unlock(&rt_b->rt_runtime_lock); | 234 | spin_unlock(&rt_b->rt_runtime_lock); |
| 235 | } | 235 | } |
| @@ -1071,7 +1071,7 @@ static void hrtick_start(struct rq *rq, u64 delay) | |||
| 1071 | struct hrtimer *timer = &rq->hrtick_timer; | 1071 | struct hrtimer *timer = &rq->hrtick_timer; |
| 1072 | ktime_t time = ktime_add_ns(timer->base->get_time(), delay); | 1072 | ktime_t time = ktime_add_ns(timer->base->get_time(), delay); |
| 1073 | 1073 | ||
| 1074 | timer->expires = time; | 1074 | hrtimer_set_expires(timer, time); |
| 1075 | 1075 | ||
| 1076 | if (rq == this_rq()) { | 1076 | if (rq == this_rq()) { |
| 1077 | hrtimer_restart(timer); | 1077 | hrtimer_restart(timer); |
diff --git a/kernel/sched_stats.h b/kernel/sched_stats.h index 2df9d297d292..ee71bec1da66 100644 --- a/kernel/sched_stats.h +++ b/kernel/sched_stats.h | |||
| @@ -90,13 +90,20 @@ static int schedstat_open(struct inode *inode, struct file *file) | |||
| 90 | return res; | 90 | return res; |
| 91 | } | 91 | } |
| 92 | 92 | ||
| 93 | const struct file_operations proc_schedstat_operations = { | 93 | static const struct file_operations proc_schedstat_operations = { |
| 94 | .open = schedstat_open, | 94 | .open = schedstat_open, |
| 95 | .read = seq_read, | 95 | .read = seq_read, |
| 96 | .llseek = seq_lseek, | 96 | .llseek = seq_lseek, |
| 97 | .release = single_release, | 97 | .release = single_release, |
| 98 | }; | 98 | }; |
| 99 | 99 | ||
| 100 | static int __init proc_schedstat_init(void) | ||
| 101 | { | ||
| 102 | proc_create("schedstat", 0, NULL, &proc_schedstat_operations); | ||
| 103 | return 0; | ||
| 104 | } | ||
| 105 | module_init(proc_schedstat_init); | ||
| 106 | |||
| 100 | /* | 107 | /* |
| 101 | * Expects runqueue lock to be held for atomicity of update | 108 | * Expects runqueue lock to be held for atomicity of update |
| 102 | */ | 109 | */ |
diff --git a/kernel/sys.c b/kernel/sys.c index 53879cdae483..31deba8f7d16 100644 --- a/kernel/sys.c +++ b/kernel/sys.c | |||
| @@ -1716,6 +1716,16 @@ asmlinkage long sys_prctl(int option, unsigned long arg2, unsigned long arg3, | |||
| 1716 | case PR_SET_TSC: | 1716 | case PR_SET_TSC: |
| 1717 | error = SET_TSC_CTL(arg2); | 1717 | error = SET_TSC_CTL(arg2); |
| 1718 | break; | 1718 | break; |
| 1719 | case PR_GET_TIMERSLACK: | ||
| 1720 | error = current->timer_slack_ns; | ||
| 1721 | break; | ||
| 1722 | case PR_SET_TIMERSLACK: | ||
| 1723 | if (arg2 <= 0) | ||
| 1724 | current->timer_slack_ns = | ||
| 1725 | current->default_timer_slack_ns; | ||
| 1726 | else | ||
| 1727 | current->timer_slack_ns = arg2; | ||
| 1728 | break; | ||
| 1719 | default: | 1729 | default: |
| 1720 | error = -EINVAL; | 1730 | error = -EINVAL; |
| 1721 | break; | 1731 | break; |
diff --git a/kernel/time.c b/kernel/time.c index 6a08660b4fac..d63a4336fad6 100644 --- a/kernel/time.c +++ b/kernel/time.c | |||
| @@ -669,3 +669,21 @@ EXPORT_SYMBOL(get_jiffies_64); | |||
| 669 | #endif | 669 | #endif |
| 670 | 670 | ||
| 671 | EXPORT_SYMBOL(jiffies); | 671 | EXPORT_SYMBOL(jiffies); |
| 672 | |||
| 673 | /* | ||
| 674 | * Add two timespec values and do a safety check for overflow. | ||
| 675 | * It's assumed that both values are valid (>= 0) | ||
| 676 | */ | ||
| 677 | struct timespec timespec_add_safe(const struct timespec lhs, | ||
| 678 | const struct timespec rhs) | ||
| 679 | { | ||
| 680 | struct timespec res; | ||
| 681 | |||
| 682 | set_normalized_timespec(&res, lhs.tv_sec + rhs.tv_sec, | ||
| 683 | lhs.tv_nsec + rhs.tv_nsec); | ||
| 684 | |||
| 685 | if (res.tv_sec < lhs.tv_sec || res.tv_sec < rhs.tv_sec) | ||
| 686 | res.tv_sec = TIME_T_MAX; | ||
| 687 | |||
| 688 | return res; | ||
| 689 | } | ||
diff --git a/kernel/time/ntp.c b/kernel/time/ntp.c index 1a20715bfd6e..8ff15e5d486b 100644 --- a/kernel/time/ntp.c +++ b/kernel/time/ntp.c | |||
| @@ -142,8 +142,7 @@ static enum hrtimer_restart ntp_leap_second(struct hrtimer *timer) | |||
| 142 | time_state = TIME_OOP; | 142 | time_state = TIME_OOP; |
| 143 | printk(KERN_NOTICE "Clock: " | 143 | printk(KERN_NOTICE "Clock: " |
| 144 | "inserting leap second 23:59:60 UTC\n"); | 144 | "inserting leap second 23:59:60 UTC\n"); |
| 145 | leap_timer.expires = ktime_add_ns(leap_timer.expires, | 145 | hrtimer_add_expires_ns(&leap_timer, NSEC_PER_SEC); |
| 146 | NSEC_PER_SEC); | ||
| 147 | res = HRTIMER_RESTART; | 146 | res = HRTIMER_RESTART; |
| 148 | break; | 147 | break; |
| 149 | case TIME_DEL: | 148 | case TIME_DEL: |
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c index 727c1ae0517a..5bbb1044f847 100644 --- a/kernel/time/tick-sched.c +++ b/kernel/time/tick-sched.c | |||
| @@ -300,7 +300,7 @@ void tick_nohz_stop_sched_tick(int inidle) | |||
| 300 | goto out; | 300 | goto out; |
| 301 | } | 301 | } |
| 302 | 302 | ||
| 303 | ts->idle_tick = ts->sched_timer.expires; | 303 | ts->idle_tick = hrtimer_get_expires(&ts->sched_timer); |
| 304 | ts->tick_stopped = 1; | 304 | ts->tick_stopped = 1; |
| 305 | ts->idle_jiffies = last_jiffies; | 305 | ts->idle_jiffies = last_jiffies; |
| 306 | rcu_enter_nohz(); | 306 | rcu_enter_nohz(); |
| @@ -380,21 +380,21 @@ ktime_t tick_nohz_get_sleep_length(void) | |||
| 380 | static void tick_nohz_restart(struct tick_sched *ts, ktime_t now) | 380 | static void tick_nohz_restart(struct tick_sched *ts, ktime_t now) |
| 381 | { | 381 | { |
| 382 | hrtimer_cancel(&ts->sched_timer); | 382 | hrtimer_cancel(&ts->sched_timer); |
| 383 | ts->sched_timer.expires = ts->idle_tick; | 383 | hrtimer_set_expires(&ts->sched_timer, ts->idle_tick); |
| 384 | 384 | ||
| 385 | while (1) { | 385 | while (1) { |
| 386 | /* Forward the time to expire in the future */ | 386 | /* Forward the time to expire in the future */ |
| 387 | hrtimer_forward(&ts->sched_timer, now, tick_period); | 387 | hrtimer_forward(&ts->sched_timer, now, tick_period); |
| 388 | 388 | ||
| 389 | if (ts->nohz_mode == NOHZ_MODE_HIGHRES) { | 389 | if (ts->nohz_mode == NOHZ_MODE_HIGHRES) { |
| 390 | hrtimer_start(&ts->sched_timer, | 390 | hrtimer_start_expires(&ts->sched_timer, |
| 391 | ts->sched_timer.expires, | ||
| 392 | HRTIMER_MODE_ABS); | 391 | HRTIMER_MODE_ABS); |
| 393 | /* Check, if the timer was already in the past */ | 392 | /* Check, if the timer was already in the past */ |
| 394 | if (hrtimer_active(&ts->sched_timer)) | 393 | if (hrtimer_active(&ts->sched_timer)) |
| 395 | break; | 394 | break; |
| 396 | } else { | 395 | } else { |
| 397 | if (!tick_program_event(ts->sched_timer.expires, 0)) | 396 | if (!tick_program_event( |
| 397 | hrtimer_get_expires(&ts->sched_timer), 0)) | ||
| 398 | break; | 398 | break; |
| 399 | } | 399 | } |
| 400 | /* Update jiffies and reread time */ | 400 | /* Update jiffies and reread time */ |
| @@ -456,14 +456,16 @@ void tick_nohz_restart_sched_tick(void) | |||
| 456 | */ | 456 | */ |
| 457 | ts->tick_stopped = 0; | 457 | ts->tick_stopped = 0; |
| 458 | ts->idle_exittime = now; | 458 | ts->idle_exittime = now; |
| 459 | |||
| 459 | tick_nohz_restart(ts, now); | 460 | tick_nohz_restart(ts, now); |
| 461 | |||
| 460 | local_irq_enable(); | 462 | local_irq_enable(); |
| 461 | } | 463 | } |
| 462 | 464 | ||
| 463 | static int tick_nohz_reprogram(struct tick_sched *ts, ktime_t now) | 465 | static int tick_nohz_reprogram(struct tick_sched *ts, ktime_t now) |
| 464 | { | 466 | { |
| 465 | hrtimer_forward(&ts->sched_timer, now, tick_period); | 467 | hrtimer_forward(&ts->sched_timer, now, tick_period); |
| 466 | return tick_program_event(ts->sched_timer.expires, 0); | 468 | return tick_program_event(hrtimer_get_expires(&ts->sched_timer), 0); |
| 467 | } | 469 | } |
| 468 | 470 | ||
| 469 | /* | 471 | /* |
| @@ -542,7 +544,7 @@ static void tick_nohz_switch_to_nohz(void) | |||
| 542 | next = tick_init_jiffy_update(); | 544 | next = tick_init_jiffy_update(); |
| 543 | 545 | ||
| 544 | for (;;) { | 546 | for (;;) { |
| 545 | ts->sched_timer.expires = next; | 547 | hrtimer_set_expires(&ts->sched_timer, next); |
| 546 | if (!tick_program_event(next, 0)) | 548 | if (!tick_program_event(next, 0)) |
| 547 | break; | 549 | break; |
| 548 | next = ktime_add(next, tick_period); | 550 | next = ktime_add(next, tick_period); |
| @@ -577,7 +579,7 @@ static void tick_nohz_kick_tick(int cpu) | |||
| 577 | * already reached or less/equal than the tick period. | 579 | * already reached or less/equal than the tick period. |
| 578 | */ | 580 | */ |
| 579 | now = ktime_get(); | 581 | now = ktime_get(); |
| 580 | delta = ktime_sub(ts->sched_timer.expires, now); | 582 | delta = ktime_sub(hrtimer_get_expires(&ts->sched_timer), now); |
| 581 | if (delta.tv64 <= tick_period.tv64) | 583 | if (delta.tv64 <= tick_period.tv64) |
| 582 | return; | 584 | return; |
| 583 | 585 | ||
| @@ -678,16 +680,15 @@ void tick_setup_sched_timer(void) | |||
| 678 | ts->sched_timer.cb_mode = HRTIMER_CB_IRQSAFE_PERCPU; | 680 | ts->sched_timer.cb_mode = HRTIMER_CB_IRQSAFE_PERCPU; |
| 679 | 681 | ||
| 680 | /* Get the next period (per cpu) */ | 682 | /* Get the next period (per cpu) */ |
| 681 | ts->sched_timer.expires = tick_init_jiffy_update(); | 683 | hrtimer_set_expires(&ts->sched_timer, tick_init_jiffy_update()); |
| 682 | offset = ktime_to_ns(tick_period) >> 1; | 684 | offset = ktime_to_ns(tick_period) >> 1; |
| 683 | do_div(offset, num_possible_cpus()); | 685 | do_div(offset, num_possible_cpus()); |
| 684 | offset *= smp_processor_id(); | 686 | offset *= smp_processor_id(); |
| 685 | ts->sched_timer.expires = ktime_add_ns(ts->sched_timer.expires, offset); | 687 | hrtimer_add_expires_ns(&ts->sched_timer, offset); |
| 686 | 688 | ||
| 687 | for (;;) { | 689 | for (;;) { |
| 688 | hrtimer_forward(&ts->sched_timer, now, tick_period); | 690 | hrtimer_forward(&ts->sched_timer, now, tick_period); |
| 689 | hrtimer_start(&ts->sched_timer, ts->sched_timer.expires, | 691 | hrtimer_start_expires(&ts->sched_timer, HRTIMER_MODE_ABS); |
| 690 | HRTIMER_MODE_ABS); | ||
| 691 | /* Check, if the timer was already in the past */ | 692 | /* Check, if the timer was already in the past */ |
| 692 | if (hrtimer_active(&ts->sched_timer)) | 693 | if (hrtimer_active(&ts->sched_timer)) |
| 693 | break; | 694 | break; |
diff --git a/kernel/time/timer_list.c b/kernel/time/timer_list.c index f6426911e35a..a999b92a1277 100644 --- a/kernel/time/timer_list.c +++ b/kernel/time/timer_list.c | |||
| @@ -66,9 +66,11 @@ print_timer(struct seq_file *m, struct hrtimer *taddr, struct hrtimer *timer, | |||
| 66 | SEQ_printf(m, ", %s/%d", tmp, timer->start_pid); | 66 | SEQ_printf(m, ", %s/%d", tmp, timer->start_pid); |
| 67 | #endif | 67 | #endif |
| 68 | SEQ_printf(m, "\n"); | 68 | SEQ_printf(m, "\n"); |
| 69 | SEQ_printf(m, " # expires at %Lu nsecs [in %Ld nsecs]\n", | 69 | SEQ_printf(m, " # expires at %Lu-%Lu nsecs [in %Ld to %Ld nsecs]\n", |
| 70 | (unsigned long long)ktime_to_ns(timer->expires), | 70 | (unsigned long long)ktime_to_ns(hrtimer_get_softexpires(timer)), |
| 71 | (long long)(ktime_to_ns(timer->expires) - now)); | 71 | (unsigned long long)ktime_to_ns(hrtimer_get_expires(timer)), |
| 72 | (long long)(ktime_to_ns(hrtimer_get_softexpires(timer)) - now), | ||
| 73 | (long long)(ktime_to_ns(hrtimer_get_expires(timer)) - now)); | ||
| 72 | } | 74 | } |
| 73 | 75 | ||
| 74 | static void | 76 | static void |
diff --git a/lib/string_helpers.c b/lib/string_helpers.c index 8347925030ff..ab431d4cc970 100644 --- a/lib/string_helpers.c +++ b/lib/string_helpers.c | |||
| @@ -23,7 +23,7 @@ | |||
| 23 | int string_get_size(u64 size, const enum string_size_units units, | 23 | int string_get_size(u64 size, const enum string_size_units units, |
| 24 | char *buf, int len) | 24 | char *buf, int len) |
| 25 | { | 25 | { |
| 26 | const char *units_10[] = { "B", "KB", "MB", "GB", "TB", "PB", | 26 | const char *units_10[] = { "B", "kB", "MB", "GB", "TB", "PB", |
| 27 | "EB", "ZB", "YB", NULL}; | 27 | "EB", "ZB", "YB", NULL}; |
| 28 | const char *units_2[] = {"B", "KiB", "MiB", "GiB", "TiB", "PiB", | 28 | const char *units_2[] = {"B", "KiB", "MiB", "GiB", "TiB", "PiB", |
| 29 | "EiB", "ZiB", "YiB", NULL }; | 29 | "EiB", "ZiB", "YiB", NULL }; |
| @@ -31,7 +31,7 @@ int string_get_size(u64 size, const enum string_size_units units, | |||
| 31 | [STRING_UNITS_10] = units_10, | 31 | [STRING_UNITS_10] = units_10, |
| 32 | [STRING_UNITS_2] = units_2, | 32 | [STRING_UNITS_2] = units_2, |
| 33 | }; | 33 | }; |
| 34 | const int divisor[] = { | 34 | const unsigned int divisor[] = { |
| 35 | [STRING_UNITS_10] = 1000, | 35 | [STRING_UNITS_10] = 1000, |
| 36 | [STRING_UNITS_2] = 1024, | 36 | [STRING_UNITS_2] = 1024, |
| 37 | }; | 37 | }; |
| @@ -40,23 +40,27 @@ int string_get_size(u64 size, const enum string_size_units units, | |||
| 40 | char tmp[8]; | 40 | char tmp[8]; |
| 41 | 41 | ||
| 42 | tmp[0] = '\0'; | 42 | tmp[0] = '\0'; |
| 43 | i = 0; | ||
| 44 | if (size >= divisor[units]) { | ||
| 45 | while (size >= divisor[units] && units_str[units][i]) { | ||
| 46 | remainder = do_div(size, divisor[units]); | ||
| 47 | i++; | ||
| 48 | } | ||
| 43 | 49 | ||
| 44 | for (i = 0; size > divisor[units] && units_str[units][i]; i++) | 50 | sf_cap = size; |
| 45 | remainder = do_div(size, divisor[units]); | 51 | for (j = 0; sf_cap*10 < 1000; j++) |
| 52 | sf_cap *= 10; | ||
| 46 | 53 | ||
| 47 | sf_cap = size; | 54 | if (j) { |
| 48 | for (j = 0; sf_cap*10 < 1000; j++) | 55 | remainder *= 1000; |
| 49 | sf_cap *= 10; | 56 | do_div(remainder, divisor[units]); |
| 50 | 57 | snprintf(tmp, sizeof(tmp), ".%03lld", | |
| 51 | if (j) { | 58 | (unsigned long long)remainder); |
| 52 | remainder *= 1000; | 59 | tmp[j+1] = '\0'; |
| 53 | do_div(remainder, divisor[units]); | 60 | } |
| 54 | snprintf(tmp, sizeof(tmp), ".%03lld", | ||
| 55 | (unsigned long long)remainder); | ||
| 56 | tmp[j+1] = '\0'; | ||
| 57 | } | 61 | } |
| 58 | 62 | ||
| 59 | snprintf(buf, len, "%lld%s%s", (unsigned long long)size, | 63 | snprintf(buf, len, "%lld%s %s", (unsigned long long)size, |
| 60 | tmp, units_str[units][i]); | 64 | tmp, units_str[units][i]); |
| 61 | 65 | ||
| 62 | return 0; | 66 | return 0; |
diff --git a/mm/hugetlb.c b/mm/hugetlb.c index ce8cbb29860b..421aee99b84a 100644 --- a/mm/hugetlb.c +++ b/mm/hugetlb.c | |||
| @@ -7,6 +7,7 @@ | |||
| 7 | #include <linux/init.h> | 7 | #include <linux/init.h> |
| 8 | #include <linux/module.h> | 8 | #include <linux/module.h> |
| 9 | #include <linux/mm.h> | 9 | #include <linux/mm.h> |
| 10 | #include <linux/seq_file.h> | ||
| 10 | #include <linux/sysctl.h> | 11 | #include <linux/sysctl.h> |
| 11 | #include <linux/highmem.h> | 12 | #include <linux/highmem.h> |
| 12 | #include <linux/mmu_notifier.h> | 13 | #include <linux/mmu_notifier.h> |
| @@ -1455,10 +1456,10 @@ int hugetlb_overcommit_handler(struct ctl_table *table, int write, | |||
| 1455 | 1456 | ||
| 1456 | #endif /* CONFIG_SYSCTL */ | 1457 | #endif /* CONFIG_SYSCTL */ |
| 1457 | 1458 | ||
| 1458 | int hugetlb_report_meminfo(char *buf) | 1459 | void hugetlb_report_meminfo(struct seq_file *m) |
| 1459 | { | 1460 | { |
| 1460 | struct hstate *h = &default_hstate; | 1461 | struct hstate *h = &default_hstate; |
| 1461 | return sprintf(buf, | 1462 | seq_printf(m, |
| 1462 | "HugePages_Total: %5lu\n" | 1463 | "HugePages_Total: %5lu\n" |
| 1463 | "HugePages_Free: %5lu\n" | 1464 | "HugePages_Free: %5lu\n" |
| 1464 | "HugePages_Rsvd: %5lu\n" | 1465 | "HugePages_Rsvd: %5lu\n" |
| @@ -95,6 +95,7 @@ | |||
| 95 | #include <linux/init.h> | 95 | #include <linux/init.h> |
| 96 | #include <linux/compiler.h> | 96 | #include <linux/compiler.h> |
| 97 | #include <linux/cpuset.h> | 97 | #include <linux/cpuset.h> |
| 98 | #include <linux/proc_fs.h> | ||
| 98 | #include <linux/seq_file.h> | 99 | #include <linux/seq_file.h> |
| 99 | #include <linux/notifier.h> | 100 | #include <linux/notifier.h> |
| 100 | #include <linux/kallsyms.h> | 101 | #include <linux/kallsyms.h> |
| @@ -4258,7 +4259,7 @@ static int s_show(struct seq_file *m, void *p) | |||
| 4258 | * + further values on SMP and with statistics enabled | 4259 | * + further values on SMP and with statistics enabled |
| 4259 | */ | 4260 | */ |
| 4260 | 4261 | ||
| 4261 | const struct seq_operations slabinfo_op = { | 4262 | static const struct seq_operations slabinfo_op = { |
| 4262 | .start = s_start, | 4263 | .start = s_start, |
| 4263 | .next = s_next, | 4264 | .next = s_next, |
| 4264 | .stop = s_stop, | 4265 | .stop = s_stop, |
| @@ -4315,6 +4316,19 @@ ssize_t slabinfo_write(struct file *file, const char __user * buffer, | |||
| 4315 | return res; | 4316 | return res; |
| 4316 | } | 4317 | } |
| 4317 | 4318 | ||
| 4319 | static int slabinfo_open(struct inode *inode, struct file *file) | ||
| 4320 | { | ||
| 4321 | return seq_open(file, &slabinfo_op); | ||
| 4322 | } | ||
| 4323 | |||
| 4324 | static const struct file_operations proc_slabinfo_operations = { | ||
| 4325 | .open = slabinfo_open, | ||
| 4326 | .read = seq_read, | ||
| 4327 | .write = slabinfo_write, | ||
| 4328 | .llseek = seq_lseek, | ||
| 4329 | .release = seq_release, | ||
| 4330 | }; | ||
| 4331 | |||
| 4318 | #ifdef CONFIG_DEBUG_SLAB_LEAK | 4332 | #ifdef CONFIG_DEBUG_SLAB_LEAK |
| 4319 | 4333 | ||
| 4320 | static void *leaks_start(struct seq_file *m, loff_t *pos) | 4334 | static void *leaks_start(struct seq_file *m, loff_t *pos) |
| @@ -4443,13 +4457,47 @@ static int leaks_show(struct seq_file *m, void *p) | |||
| 4443 | return 0; | 4457 | return 0; |
| 4444 | } | 4458 | } |
| 4445 | 4459 | ||
| 4446 | const struct seq_operations slabstats_op = { | 4460 | static const struct seq_operations slabstats_op = { |
| 4447 | .start = leaks_start, | 4461 | .start = leaks_start, |
| 4448 | .next = s_next, | 4462 | .next = s_next, |
| 4449 | .stop = s_stop, | 4463 | .stop = s_stop, |
| 4450 | .show = leaks_show, | 4464 | .show = leaks_show, |
| 4451 | }; | 4465 | }; |
| 4466 | |||
| 4467 | static int slabstats_open(struct inode *inode, struct file *file) | ||
| 4468 | { | ||
| 4469 | unsigned long *n = kzalloc(PAGE_SIZE, GFP_KERNEL); | ||
| 4470 | int ret = -ENOMEM; | ||
| 4471 | if (n) { | ||
| 4472 | ret = seq_open(file, &slabstats_op); | ||
| 4473 | if (!ret) { | ||
| 4474 | struct seq_file *m = file->private_data; | ||
| 4475 | *n = PAGE_SIZE / (2 * sizeof(unsigned long)); | ||
| 4476 | m->private = n; | ||
| 4477 | n = NULL; | ||
| 4478 | } | ||
| 4479 | kfree(n); | ||
| 4480 | } | ||
| 4481 | return ret; | ||
| 4482 | } | ||
| 4483 | |||
| 4484 | static const struct file_operations proc_slabstats_operations = { | ||
| 4485 | .open = slabstats_open, | ||
| 4486 | .read = seq_read, | ||
| 4487 | .llseek = seq_lseek, | ||
| 4488 | .release = seq_release_private, | ||
| 4489 | }; | ||
| 4490 | #endif | ||
| 4491 | |||
| 4492 | static int __init slab_proc_init(void) | ||
| 4493 | { | ||
| 4494 | proc_create("slabinfo",S_IWUSR|S_IRUGO,NULL,&proc_slabinfo_operations); | ||
| 4495 | #ifdef CONFIG_DEBUG_SLAB_LEAK | ||
| 4496 | proc_create("slab_allocators", 0, NULL, &proc_slabstats_operations); | ||
| 4452 | #endif | 4497 | #endif |
| 4498 | return 0; | ||
| 4499 | } | ||
| 4500 | module_init(slab_proc_init); | ||
| 4453 | #endif | 4501 | #endif |
| 4454 | 4502 | ||
| 4455 | /** | 4503 | /** |
| @@ -14,6 +14,7 @@ | |||
| 14 | #include <linux/interrupt.h> | 14 | #include <linux/interrupt.h> |
| 15 | #include <linux/bitops.h> | 15 | #include <linux/bitops.h> |
| 16 | #include <linux/slab.h> | 16 | #include <linux/slab.h> |
| 17 | #include <linux/proc_fs.h> | ||
| 17 | #include <linux/seq_file.h> | 18 | #include <linux/seq_file.h> |
| 18 | #include <linux/cpu.h> | 19 | #include <linux/cpu.h> |
| 19 | #include <linux/cpuset.h> | 20 | #include <linux/cpuset.h> |
| @@ -4417,14 +4418,6 @@ __initcall(slab_sysfs_init); | |||
| 4417 | * The /proc/slabinfo ABI | 4418 | * The /proc/slabinfo ABI |
| 4418 | */ | 4419 | */ |
| 4419 | #ifdef CONFIG_SLABINFO | 4420 | #ifdef CONFIG_SLABINFO |
| 4420 | |||
| 4421 | ssize_t slabinfo_write(struct file *file, const char __user *buffer, | ||
| 4422 | size_t count, loff_t *ppos) | ||
| 4423 | { | ||
| 4424 | return -EINVAL; | ||
| 4425 | } | ||
| 4426 | |||
| 4427 | |||
| 4428 | static void print_slabinfo_header(struct seq_file *m) | 4421 | static void print_slabinfo_header(struct seq_file *m) |
| 4429 | { | 4422 | { |
| 4430 | seq_puts(m, "slabinfo - version: 2.1\n"); | 4423 | seq_puts(m, "slabinfo - version: 2.1\n"); |
| @@ -4492,11 +4485,29 @@ static int s_show(struct seq_file *m, void *p) | |||
| 4492 | return 0; | 4485 | return 0; |
| 4493 | } | 4486 | } |
| 4494 | 4487 | ||
| 4495 | const struct seq_operations slabinfo_op = { | 4488 | static const struct seq_operations slabinfo_op = { |
| 4496 | .start = s_start, | 4489 | .start = s_start, |
| 4497 | .next = s_next, | 4490 | .next = s_next, |
| 4498 | .stop = s_stop, | 4491 | .stop = s_stop, |
| 4499 | .show = s_show, | 4492 | .show = s_show, |
| 4500 | }; | 4493 | }; |
| 4501 | 4494 | ||
| 4495 | static int slabinfo_open(struct inode *inode, struct file *file) | ||
| 4496 | { | ||
| 4497 | return seq_open(file, &slabinfo_op); | ||
| 4498 | } | ||
| 4499 | |||
| 4500 | static const struct file_operations proc_slabinfo_operations = { | ||
| 4501 | .open = slabinfo_open, | ||
| 4502 | .read = seq_read, | ||
| 4503 | .llseek = seq_lseek, | ||
| 4504 | .release = seq_release, | ||
| 4505 | }; | ||
| 4506 | |||
| 4507 | static int __init slab_proc_init(void) | ||
| 4508 | { | ||
| 4509 | proc_create("slabinfo",S_IWUSR|S_IRUGO,NULL,&proc_slabinfo_operations); | ||
| 4510 | return 0; | ||
| 4511 | } | ||
| 4512 | module_init(slab_proc_init); | ||
| 4502 | #endif /* CONFIG_SLABINFO */ | 4513 | #endif /* CONFIG_SLABINFO */ |
diff --git a/mm/vmalloc.c b/mm/vmalloc.c index 65ae576030da..036536945dd9 100644 --- a/mm/vmalloc.c +++ b/mm/vmalloc.c | |||
| @@ -15,6 +15,7 @@ | |||
| 15 | #include <linux/slab.h> | 15 | #include <linux/slab.h> |
| 16 | #include <linux/spinlock.h> | 16 | #include <linux/spinlock.h> |
| 17 | #include <linux/interrupt.h> | 17 | #include <linux/interrupt.h> |
| 18 | #include <linux/proc_fs.h> | ||
| 18 | #include <linux/seq_file.h> | 19 | #include <linux/seq_file.h> |
| 19 | #include <linux/debugobjects.h> | 20 | #include <linux/debugobjects.h> |
| 20 | #include <linux/kallsyms.h> | 21 | #include <linux/kallsyms.h> |
| @@ -1718,11 +1719,41 @@ static int s_show(struct seq_file *m, void *p) | |||
| 1718 | return 0; | 1719 | return 0; |
| 1719 | } | 1720 | } |
| 1720 | 1721 | ||
| 1721 | const struct seq_operations vmalloc_op = { | 1722 | static const struct seq_operations vmalloc_op = { |
| 1722 | .start = s_start, | 1723 | .start = s_start, |
| 1723 | .next = s_next, | 1724 | .next = s_next, |
| 1724 | .stop = s_stop, | 1725 | .stop = s_stop, |
| 1725 | .show = s_show, | 1726 | .show = s_show, |
| 1726 | }; | 1727 | }; |
| 1728 | |||
| 1729 | static int vmalloc_open(struct inode *inode, struct file *file) | ||
| 1730 | { | ||
| 1731 | unsigned int *ptr = NULL; | ||
| 1732 | int ret; | ||
| 1733 | |||
| 1734 | if (NUMA_BUILD) | ||
| 1735 | ptr = kmalloc(nr_node_ids * sizeof(unsigned int), GFP_KERNEL); | ||
| 1736 | ret = seq_open(file, &vmalloc_op); | ||
| 1737 | if (!ret) { | ||
| 1738 | struct seq_file *m = file->private_data; | ||
| 1739 | m->private = ptr; | ||
| 1740 | } else | ||
| 1741 | kfree(ptr); | ||
| 1742 | return ret; | ||
| 1743 | } | ||
| 1744 | |||
| 1745 | static const struct file_operations proc_vmalloc_operations = { | ||
| 1746 | .open = vmalloc_open, | ||
| 1747 | .read = seq_read, | ||
| 1748 | .llseek = seq_lseek, | ||
| 1749 | .release = seq_release_private, | ||
| 1750 | }; | ||
| 1751 | |||
| 1752 | static int __init proc_vmalloc_init(void) | ||
| 1753 | { | ||
| 1754 | proc_create("vmallocinfo", S_IRUSR, NULL, &proc_vmalloc_operations); | ||
| 1755 | return 0; | ||
| 1756 | } | ||
| 1757 | module_init(proc_vmalloc_init); | ||
| 1727 | #endif | 1758 | #endif |
| 1728 | 1759 | ||
diff --git a/mm/vmstat.c b/mm/vmstat.c index 9343227c5c60..c3ccfda23adc 100644 --- a/mm/vmstat.c +++ b/mm/vmstat.c | |||
| @@ -8,7 +8,7 @@ | |||
| 8 | * Copyright (C) 2006 Silicon Graphics, Inc., | 8 | * Copyright (C) 2006 Silicon Graphics, Inc., |
| 9 | * Christoph Lameter <christoph@lameter.com> | 9 | * Christoph Lameter <christoph@lameter.com> |
| 10 | */ | 10 | */ |
| 11 | 11 | #include <linux/fs.h> | |
| 12 | #include <linux/mm.h> | 12 | #include <linux/mm.h> |
| 13 | #include <linux/err.h> | 13 | #include <linux/err.h> |
| 14 | #include <linux/module.h> | 14 | #include <linux/module.h> |
| @@ -384,7 +384,7 @@ void zone_statistics(struct zone *preferred_zone, struct zone *z) | |||
| 384 | #endif | 384 | #endif |
| 385 | 385 | ||
| 386 | #ifdef CONFIG_PROC_FS | 386 | #ifdef CONFIG_PROC_FS |
| 387 | 387 | #include <linux/proc_fs.h> | |
| 388 | #include <linux/seq_file.h> | 388 | #include <linux/seq_file.h> |
| 389 | 389 | ||
| 390 | static char * const migratetype_names[MIGRATE_TYPES] = { | 390 | static char * const migratetype_names[MIGRATE_TYPES] = { |
| @@ -581,20 +581,44 @@ static int pagetypeinfo_show(struct seq_file *m, void *arg) | |||
| 581 | return 0; | 581 | return 0; |
| 582 | } | 582 | } |
| 583 | 583 | ||
| 584 | const struct seq_operations fragmentation_op = { | 584 | static const struct seq_operations fragmentation_op = { |
| 585 | .start = frag_start, | 585 | .start = frag_start, |
| 586 | .next = frag_next, | 586 | .next = frag_next, |
| 587 | .stop = frag_stop, | 587 | .stop = frag_stop, |
| 588 | .show = frag_show, | 588 | .show = frag_show, |
| 589 | }; | 589 | }; |
| 590 | 590 | ||
| 591 | const struct seq_operations pagetypeinfo_op = { | 591 | static int fragmentation_open(struct inode *inode, struct file *file) |
| 592 | { | ||
| 593 | return seq_open(file, &fragmentation_op); | ||
| 594 | } | ||
| 595 | |||
| 596 | static const struct file_operations fragmentation_file_operations = { | ||
| 597 | .open = fragmentation_open, | ||
| 598 | .read = seq_read, | ||
| 599 | .llseek = seq_lseek, | ||
| 600 | .release = seq_release, | ||
| 601 | }; | ||
| 602 | |||
| 603 | static const struct seq_operations pagetypeinfo_op = { | ||
| 592 | .start = frag_start, | 604 | .start = frag_start, |
| 593 | .next = frag_next, | 605 | .next = frag_next, |
| 594 | .stop = frag_stop, | 606 | .stop = frag_stop, |
| 595 | .show = pagetypeinfo_show, | 607 | .show = pagetypeinfo_show, |
| 596 | }; | 608 | }; |
| 597 | 609 | ||
| 610 | static int pagetypeinfo_open(struct inode *inode, struct file *file) | ||
| 611 | { | ||
| 612 | return seq_open(file, &pagetypeinfo_op); | ||
| 613 | } | ||
| 614 | |||
| 615 | static const struct file_operations pagetypeinfo_file_ops = { | ||
| 616 | .open = pagetypeinfo_open, | ||
| 617 | .read = seq_read, | ||
| 618 | .llseek = seq_lseek, | ||
| 619 | .release = seq_release, | ||
| 620 | }; | ||
| 621 | |||
| 598 | #ifdef CONFIG_ZONE_DMA | 622 | #ifdef CONFIG_ZONE_DMA |
| 599 | #define TEXT_FOR_DMA(xx) xx "_dma", | 623 | #define TEXT_FOR_DMA(xx) xx "_dma", |
| 600 | #else | 624 | #else |
| @@ -771,7 +795,7 @@ static int zoneinfo_show(struct seq_file *m, void *arg) | |||
| 771 | return 0; | 795 | return 0; |
| 772 | } | 796 | } |
| 773 | 797 | ||
| 774 | const struct seq_operations zoneinfo_op = { | 798 | static const struct seq_operations zoneinfo_op = { |
| 775 | .start = frag_start, /* iterate over all zones. The same as in | 799 | .start = frag_start, /* iterate over all zones. The same as in |
| 776 | * fragmentation. */ | 800 | * fragmentation. */ |
| 777 | .next = frag_next, | 801 | .next = frag_next, |
| @@ -779,6 +803,18 @@ const struct seq_operations zoneinfo_op = { | |||
| 779 | .show = zoneinfo_show, | 803 | .show = zoneinfo_show, |
| 780 | }; | 804 | }; |
| 781 | 805 | ||
| 806 | static int zoneinfo_open(struct inode *inode, struct file *file) | ||
| 807 | { | ||
| 808 | return seq_open(file, &zoneinfo_op); | ||
| 809 | } | ||
| 810 | |||
| 811 | static const struct file_operations proc_zoneinfo_file_operations = { | ||
| 812 | .open = zoneinfo_open, | ||
| 813 | .read = seq_read, | ||
| 814 | .llseek = seq_lseek, | ||
| 815 | .release = seq_release, | ||
| 816 | }; | ||
| 817 | |||
| 782 | static void *vmstat_start(struct seq_file *m, loff_t *pos) | 818 | static void *vmstat_start(struct seq_file *m, loff_t *pos) |
| 783 | { | 819 | { |
| 784 | unsigned long *v; | 820 | unsigned long *v; |
| @@ -834,13 +870,24 @@ static void vmstat_stop(struct seq_file *m, void *arg) | |||
| 834 | m->private = NULL; | 870 | m->private = NULL; |
| 835 | } | 871 | } |
| 836 | 872 | ||
| 837 | const struct seq_operations vmstat_op = { | 873 | static const struct seq_operations vmstat_op = { |
| 838 | .start = vmstat_start, | 874 | .start = vmstat_start, |
| 839 | .next = vmstat_next, | 875 | .next = vmstat_next, |
| 840 | .stop = vmstat_stop, | 876 | .stop = vmstat_stop, |
| 841 | .show = vmstat_show, | 877 | .show = vmstat_show, |
| 842 | }; | 878 | }; |
| 843 | 879 | ||
| 880 | static int vmstat_open(struct inode *inode, struct file *file) | ||
| 881 | { | ||
| 882 | return seq_open(file, &vmstat_op); | ||
| 883 | } | ||
| 884 | |||
| 885 | static const struct file_operations proc_vmstat_file_operations = { | ||
| 886 | .open = vmstat_open, | ||
| 887 | .read = seq_read, | ||
| 888 | .llseek = seq_lseek, | ||
| 889 | .release = seq_release, | ||
| 890 | }; | ||
| 844 | #endif /* CONFIG_PROC_FS */ | 891 | #endif /* CONFIG_PROC_FS */ |
| 845 | 892 | ||
| 846 | #ifdef CONFIG_SMP | 893 | #ifdef CONFIG_SMP |
| @@ -898,9 +945,11 @@ static int __cpuinit vmstat_cpuup_callback(struct notifier_block *nfb, | |||
| 898 | 945 | ||
| 899 | static struct notifier_block __cpuinitdata vmstat_notifier = | 946 | static struct notifier_block __cpuinitdata vmstat_notifier = |
| 900 | { &vmstat_cpuup_callback, NULL, 0 }; | 947 | { &vmstat_cpuup_callback, NULL, 0 }; |
| 948 | #endif | ||
| 901 | 949 | ||
| 902 | static int __init setup_vmstat(void) | 950 | static int __init setup_vmstat(void) |
| 903 | { | 951 | { |
| 952 | #ifdef CONFIG_SMP | ||
| 904 | int cpu; | 953 | int cpu; |
| 905 | 954 | ||
| 906 | refresh_zone_stat_thresholds(); | 955 | refresh_zone_stat_thresholds(); |
| @@ -908,7 +957,13 @@ static int __init setup_vmstat(void) | |||
| 908 | 957 | ||
| 909 | for_each_online_cpu(cpu) | 958 | for_each_online_cpu(cpu) |
| 910 | start_cpu_timer(cpu); | 959 | start_cpu_timer(cpu); |
| 960 | #endif | ||
| 961 | #ifdef CONFIG_PROC_FS | ||
| 962 | proc_create("buddyinfo", S_IRUGO, NULL, &fragmentation_file_operations); | ||
| 963 | proc_create("pagetypeinfo", S_IRUGO, NULL, &pagetypeinfo_file_ops); | ||
| 964 | proc_create("vmstat", S_IRUGO, NULL, &proc_vmstat_file_operations); | ||
| 965 | proc_create("zoneinfo", S_IRUGO, NULL, &proc_zoneinfo_file_operations); | ||
| 966 | #endif | ||
| 911 | return 0; | 967 | return 0; |
| 912 | } | 968 | } |
| 913 | module_init(setup_vmstat) | 969 | module_init(setup_vmstat) |
| 914 | #endif | ||
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index 22ba8632196f..6c023f0f8252 100644 --- a/net/bridge/br_device.c +++ b/net/bridge/br_device.c | |||
| @@ -179,5 +179,5 @@ void br_dev_setup(struct net_device *dev) | |||
| 179 | 179 | ||
| 180 | dev->features = NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | | 180 | dev->features = NETIF_F_SG | NETIF_F_FRAGLIST | NETIF_F_HIGHDMA | |
| 181 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM | NETIF_F_LLTX | | 181 | NETIF_F_GSO_MASK | NETIF_F_NO_CSUM | NETIF_F_LLTX | |
| 182 | NETIF_F_NETNS_LOCAL; | 182 | NETIF_F_NETNS_LOCAL | NETIF_F_GSO; |
| 183 | } | 183 | } |
diff --git a/net/bridge/br_if.c b/net/bridge/br_if.c index 573e20f7dba4..0a09ccf68c1c 100644 --- a/net/bridge/br_if.c +++ b/net/bridge/br_if.c | |||
| @@ -347,15 +347,21 @@ int br_min_mtu(const struct net_bridge *br) | |||
| 347 | void br_features_recompute(struct net_bridge *br) | 347 | void br_features_recompute(struct net_bridge *br) |
| 348 | { | 348 | { |
| 349 | struct net_bridge_port *p; | 349 | struct net_bridge_port *p; |
| 350 | unsigned long features; | 350 | unsigned long features, mask; |
| 351 | 351 | ||
| 352 | features = br->feature_mask; | 352 | features = mask = br->feature_mask; |
| 353 | if (list_empty(&br->port_list)) | ||
| 354 | goto done; | ||
| 355 | |||
| 356 | features &= ~NETIF_F_ONE_FOR_ALL; | ||
| 353 | 357 | ||
| 354 | list_for_each_entry(p, &br->port_list, list) { | 358 | list_for_each_entry(p, &br->port_list, list) { |
| 355 | features = netdev_compute_features(features, p->dev->features); | 359 | features = netdev_increment_features(features, |
| 360 | p->dev->features, mask); | ||
| 356 | } | 361 | } |
| 357 | 362 | ||
| 358 | br->dev->features = features; | 363 | done: |
| 364 | br->dev->features = netdev_fix_features(features, NULL); | ||
| 359 | } | 365 | } |
| 360 | 366 | ||
| 361 | /* called with RTNL */ | 367 | /* called with RTNL */ |
diff --git a/net/core/dev.c b/net/core/dev.c index b8a4fd0806af..d9038e328cc1 100644 --- a/net/core/dev.c +++ b/net/core/dev.c | |||
| @@ -3947,6 +3947,46 @@ static void netdev_init_queue_locks(struct net_device *dev) | |||
| 3947 | __netdev_init_queue_locks_one(dev, &dev->rx_queue, NULL); | 3947 | __netdev_init_queue_locks_one(dev, &dev->rx_queue, NULL); |
| 3948 | } | 3948 | } |
| 3949 | 3949 | ||
| 3950 | unsigned long netdev_fix_features(unsigned long features, const char *name) | ||
| 3951 | { | ||
| 3952 | /* Fix illegal SG+CSUM combinations. */ | ||
| 3953 | if ((features & NETIF_F_SG) && | ||
| 3954 | !(features & NETIF_F_ALL_CSUM)) { | ||
| 3955 | if (name) | ||
| 3956 | printk(KERN_NOTICE "%s: Dropping NETIF_F_SG since no " | ||
| 3957 | "checksum feature.\n", name); | ||
| 3958 | features &= ~NETIF_F_SG; | ||
| 3959 | } | ||
| 3960 | |||
| 3961 | /* TSO requires that SG is present as well. */ | ||
| 3962 | if ((features & NETIF_F_TSO) && !(features & NETIF_F_SG)) { | ||
| 3963 | if (name) | ||
| 3964 | printk(KERN_NOTICE "%s: Dropping NETIF_F_TSO since no " | ||
| 3965 | "SG feature.\n", name); | ||
| 3966 | features &= ~NETIF_F_TSO; | ||
| 3967 | } | ||
| 3968 | |||
| 3969 | if (features & NETIF_F_UFO) { | ||
| 3970 | if (!(features & NETIF_F_GEN_CSUM)) { | ||
| 3971 | if (name) | ||
| 3972 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO " | ||
| 3973 | "since no NETIF_F_HW_CSUM feature.\n", | ||
| 3974 | name); | ||
| 3975 | features &= ~NETIF_F_UFO; | ||
| 3976 | } | ||
| 3977 | |||
| 3978 | if (!(features & NETIF_F_SG)) { | ||
| 3979 | if (name) | ||
| 3980 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO " | ||
| 3981 | "since no NETIF_F_SG feature.\n", name); | ||
| 3982 | features &= ~NETIF_F_UFO; | ||
| 3983 | } | ||
| 3984 | } | ||
| 3985 | |||
| 3986 | return features; | ||
| 3987 | } | ||
| 3988 | EXPORT_SYMBOL(netdev_fix_features); | ||
| 3989 | |||
| 3950 | /** | 3990 | /** |
| 3951 | * register_netdevice - register a network device | 3991 | * register_netdevice - register a network device |
| 3952 | * @dev: device to register | 3992 | * @dev: device to register |
| @@ -4032,36 +4072,7 @@ int register_netdevice(struct net_device *dev) | |||
| 4032 | dev->features &= ~(NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM|NETIF_F_HW_CSUM); | 4072 | dev->features &= ~(NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM|NETIF_F_HW_CSUM); |
| 4033 | } | 4073 | } |
| 4034 | 4074 | ||
| 4035 | 4075 | dev->features = netdev_fix_features(dev->features, dev->name); | |
| 4036 | /* Fix illegal SG+CSUM combinations. */ | ||
| 4037 | if ((dev->features & NETIF_F_SG) && | ||
| 4038 | !(dev->features & NETIF_F_ALL_CSUM)) { | ||
| 4039 | printk(KERN_NOTICE "%s: Dropping NETIF_F_SG since no checksum feature.\n", | ||
| 4040 | dev->name); | ||
| 4041 | dev->features &= ~NETIF_F_SG; | ||
| 4042 | } | ||
| 4043 | |||
| 4044 | /* TSO requires that SG is present as well. */ | ||
| 4045 | if ((dev->features & NETIF_F_TSO) && | ||
| 4046 | !(dev->features & NETIF_F_SG)) { | ||
| 4047 | printk(KERN_NOTICE "%s: Dropping NETIF_F_TSO since no SG feature.\n", | ||
| 4048 | dev->name); | ||
| 4049 | dev->features &= ~NETIF_F_TSO; | ||
| 4050 | } | ||
| 4051 | if (dev->features & NETIF_F_UFO) { | ||
| 4052 | if (!(dev->features & NETIF_F_HW_CSUM)) { | ||
| 4053 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " | ||
| 4054 | "NETIF_F_HW_CSUM feature.\n", | ||
| 4055 | dev->name); | ||
| 4056 | dev->features &= ~NETIF_F_UFO; | ||
| 4057 | } | ||
| 4058 | if (!(dev->features & NETIF_F_SG)) { | ||
| 4059 | printk(KERN_ERR "%s: Dropping NETIF_F_UFO since no " | ||
| 4060 | "NETIF_F_SG feature.\n", | ||
| 4061 | dev->name); | ||
| 4062 | dev->features &= ~NETIF_F_UFO; | ||
| 4063 | } | ||
| 4064 | } | ||
| 4065 | 4076 | ||
| 4066 | /* Enable software GSO if SG is supported. */ | 4077 | /* Enable software GSO if SG is supported. */ |
| 4067 | if (dev->features & NETIF_F_SG) | 4078 | if (dev->features & NETIF_F_SG) |
| @@ -4700,49 +4711,45 @@ static int __init netdev_dma_register(void) { return -ENODEV; } | |||
| 4700 | #endif /* CONFIG_NET_DMA */ | 4711 | #endif /* CONFIG_NET_DMA */ |
| 4701 | 4712 | ||
| 4702 | /** | 4713 | /** |
| 4703 | * netdev_compute_feature - compute conjunction of two feature sets | 4714 | * netdev_increment_features - increment feature set by one |
| 4704 | * @all: first feature set | 4715 | * @all: current feature set |
| 4705 | * @one: second feature set | 4716 | * @one: new feature set |
| 4717 | * @mask: mask feature set | ||
| 4706 | * | 4718 | * |
| 4707 | * Computes a new feature set after adding a device with feature set | 4719 | * Computes a new feature set after adding a device with feature set |
| 4708 | * @one to the master device with current feature set @all. Returns | 4720 | * @one to the master device with current feature set @all. Will not |
| 4709 | * the new feature set. | 4721 | * enable anything that is off in @mask. Returns the new feature set. |
| 4710 | */ | 4722 | */ |
| 4711 | int netdev_compute_features(unsigned long all, unsigned long one) | 4723 | unsigned long netdev_increment_features(unsigned long all, unsigned long one, |
| 4712 | { | 4724 | unsigned long mask) |
| 4713 | /* if device needs checksumming, downgrade to hw checksumming */ | 4725 | { |
| 4714 | if (all & NETIF_F_NO_CSUM && !(one & NETIF_F_NO_CSUM)) | 4726 | /* If device needs checksumming, downgrade to it. */ |
| 4715 | all ^= NETIF_F_NO_CSUM | NETIF_F_HW_CSUM; | 4727 | if (all & NETIF_F_NO_CSUM && !(one & NETIF_F_NO_CSUM)) |
| 4716 | 4728 | all ^= NETIF_F_NO_CSUM | (one & NETIF_F_ALL_CSUM); | |
| 4717 | /* if device can't do all checksum, downgrade to ipv4/ipv6 */ | 4729 | else if (mask & NETIF_F_ALL_CSUM) { |
| 4718 | if (all & NETIF_F_HW_CSUM && !(one & NETIF_F_HW_CSUM)) | 4730 | /* If one device supports v4/v6 checksumming, set for all. */ |
| 4719 | all ^= NETIF_F_HW_CSUM | 4731 | if (one & (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM) && |
| 4720 | | NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM; | 4732 | !(all & NETIF_F_GEN_CSUM)) { |
| 4721 | 4733 | all &= ~NETIF_F_ALL_CSUM; | |
| 4722 | if (one & NETIF_F_GSO) | 4734 | all |= one & (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM); |
| 4723 | one |= NETIF_F_GSO_SOFTWARE; | 4735 | } |
| 4724 | one |= NETIF_F_GSO; | ||
| 4725 | |||
| 4726 | /* | ||
| 4727 | * If even one device supports a GSO protocol with software fallback, | ||
| 4728 | * enable it for all. | ||
| 4729 | */ | ||
| 4730 | all |= one & NETIF_F_GSO_SOFTWARE; | ||
| 4731 | 4736 | ||
| 4732 | /* If even one device supports robust GSO, enable it for all. */ | 4737 | /* If one device supports hw checksumming, set for all. */ |
| 4733 | if (one & NETIF_F_GSO_ROBUST) | 4738 | if (one & NETIF_F_GEN_CSUM && !(all & NETIF_F_GEN_CSUM)) { |
| 4734 | all |= NETIF_F_GSO_ROBUST; | 4739 | all &= ~NETIF_F_ALL_CSUM; |
| 4740 | all |= NETIF_F_HW_CSUM; | ||
| 4741 | } | ||
| 4742 | } | ||
| 4735 | 4743 | ||
| 4736 | all &= one | NETIF_F_LLTX; | 4744 | one |= NETIF_F_ALL_CSUM; |
| 4737 | 4745 | ||
| 4738 | if (!(all & NETIF_F_ALL_CSUM)) | 4746 | one |= all & NETIF_F_ONE_FOR_ALL; |
| 4739 | all &= ~NETIF_F_SG; | 4747 | all &= one | NETIF_F_LLTX | NETIF_F_GSO; |
| 4740 | if (!(all & NETIF_F_SG)) | 4748 | all |= one & mask & NETIF_F_ONE_FOR_ALL; |
| 4741 | all &= ~NETIF_F_GSO_MASK; | ||
| 4742 | 4749 | ||
| 4743 | return all; | 4750 | return all; |
| 4744 | } | 4751 | } |
| 4745 | EXPORT_SYMBOL(netdev_compute_features); | 4752 | EXPORT_SYMBOL(netdev_increment_features); |
| 4746 | 4753 | ||
| 4747 | static struct hlist_head *netdev_create_hash(void) | 4754 | static struct hlist_head *netdev_create_hash(void) |
| 4748 | { | 4755 | { |
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c index 990a58493235..e4c5ac9fe89b 100644 --- a/net/ipv4/tcp_output.c +++ b/net/ipv4/tcp_output.c | |||
| @@ -362,6 +362,17 @@ struct tcp_out_options { | |||
| 362 | __u32 tsval, tsecr; /* need to include OPTION_TS */ | 362 | __u32 tsval, tsecr; /* need to include OPTION_TS */ |
| 363 | }; | 363 | }; |
| 364 | 364 | ||
| 365 | /* Beware: Something in the Internet is very sensitive to the ordering of | ||
| 366 | * TCP options, we learned this through the hard way, so be careful here. | ||
| 367 | * Luckily we can at least blame others for their non-compliance but from | ||
| 368 | * inter-operatibility perspective it seems that we're somewhat stuck with | ||
| 369 | * the ordering which we have been using if we want to keep working with | ||
| 370 | * those broken things (not that it currently hurts anybody as there isn't | ||
| 371 | * particular reason why the ordering would need to be changed). | ||
| 372 | * | ||
| 373 | * At least SACK_PERM as the first option is known to lead to a disaster | ||
| 374 | * (but it may well be that other scenarios fail similarly). | ||
| 375 | */ | ||
| 365 | static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | 376 | static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, |
| 366 | const struct tcp_out_options *opts, | 377 | const struct tcp_out_options *opts, |
| 367 | __u8 **md5_hash) { | 378 | __u8 **md5_hash) { |
| @@ -376,6 +387,12 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
| 376 | *md5_hash = NULL; | 387 | *md5_hash = NULL; |
| 377 | } | 388 | } |
| 378 | 389 | ||
| 390 | if (unlikely(opts->mss)) { | ||
| 391 | *ptr++ = htonl((TCPOPT_MSS << 24) | | ||
| 392 | (TCPOLEN_MSS << 16) | | ||
| 393 | opts->mss); | ||
| 394 | } | ||
| 395 | |||
| 379 | if (likely(OPTION_TS & opts->options)) { | 396 | if (likely(OPTION_TS & opts->options)) { |
| 380 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options)) { | 397 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options)) { |
| 381 | *ptr++ = htonl((TCPOPT_SACK_PERM << 24) | | 398 | *ptr++ = htonl((TCPOPT_SACK_PERM << 24) | |
| @@ -392,12 +409,6 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
| 392 | *ptr++ = htonl(opts->tsecr); | 409 | *ptr++ = htonl(opts->tsecr); |
| 393 | } | 410 | } |
| 394 | 411 | ||
| 395 | if (unlikely(opts->mss)) { | ||
| 396 | *ptr++ = htonl((TCPOPT_MSS << 24) | | ||
| 397 | (TCPOLEN_MSS << 16) | | ||
| 398 | opts->mss); | ||
| 399 | } | ||
| 400 | |||
| 401 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options && | 412 | if (unlikely(OPTION_SACK_ADVERTISE & opts->options && |
| 402 | !(OPTION_TS & opts->options))) { | 413 | !(OPTION_TS & opts->options))) { |
| 403 | *ptr++ = htonl((TCPOPT_NOP << 24) | | 414 | *ptr++ = htonl((TCPOPT_NOP << 24) | |
| @@ -432,7 +443,7 @@ static void tcp_options_write(__be32 *ptr, struct tcp_sock *tp, | |||
| 432 | 443 | ||
| 433 | if (tp->rx_opt.dsack) { | 444 | if (tp->rx_opt.dsack) { |
| 434 | tp->rx_opt.dsack = 0; | 445 | tp->rx_opt.dsack = 0; |
| 435 | tp->rx_opt.eff_sacks--; | 446 | tp->rx_opt.eff_sacks = tp->rx_opt.num_sacks; |
| 436 | } | 447 | } |
| 437 | } | 448 | } |
| 438 | } | 449 | } |
diff --git a/net/sched/sch_cbq.c b/net/sched/sch_cbq.c index 8b06fa900482..03e389e8d945 100644 --- a/net/sched/sch_cbq.c +++ b/net/sched/sch_cbq.c | |||
| @@ -545,9 +545,10 @@ static void cbq_ovl_delay(struct cbq_class *cl) | |||
| 545 | expires = ktime_set(0, 0); | 545 | expires = ktime_set(0, 0); |
| 546 | expires = ktime_add_ns(expires, PSCHED_US2NS(sched)); | 546 | expires = ktime_add_ns(expires, PSCHED_US2NS(sched)); |
| 547 | if (hrtimer_try_to_cancel(&q->delay_timer) && | 547 | if (hrtimer_try_to_cancel(&q->delay_timer) && |
| 548 | ktime_to_ns(ktime_sub(q->delay_timer.expires, | 548 | ktime_to_ns(ktime_sub( |
| 549 | expires)) > 0) | 549 | hrtimer_get_expires(&q->delay_timer), |
| 550 | q->delay_timer.expires = expires; | 550 | expires)) > 0) |
| 551 | hrtimer_set_expires(&q->delay_timer, expires); | ||
| 551 | hrtimer_restart(&q->delay_timer); | 552 | hrtimer_restart(&q->delay_timer); |
| 552 | cl->delayed = 1; | 553 | cl->delayed = 1; |
| 553 | cl->xstats.overactions++; | 554 | cl->xstats.overactions++; |
diff --git a/net/sctp/input.c b/net/sctp/input.c index a49fa80b57b9..bf612d954d41 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c | |||
| @@ -369,7 +369,7 @@ static void sctp_add_backlog(struct sock *sk, struct sk_buff *skb) | |||
| 369 | void sctp_icmp_frag_needed(struct sock *sk, struct sctp_association *asoc, | 369 | void sctp_icmp_frag_needed(struct sock *sk, struct sctp_association *asoc, |
| 370 | struct sctp_transport *t, __u32 pmtu) | 370 | struct sctp_transport *t, __u32 pmtu) |
| 371 | { | 371 | { |
| 372 | if (!t || (t->pathmtu == pmtu)) | 372 | if (!t || (t->pathmtu <= pmtu)) |
| 373 | return; | 373 | return; |
| 374 | 374 | ||
| 375 | if (sock_owned_by_user(sk)) { | 375 | if (sock_owned_by_user(sk)) { |
diff --git a/net/sctp/sm_statefuns.c b/net/sctp/sm_statefuns.c index d4c3fbc4671e..a6a0ea71ae93 100644 --- a/net/sctp/sm_statefuns.c +++ b/net/sctp/sm_statefuns.c | |||
| @@ -2544,6 +2544,7 @@ sctp_disposition_t sctp_sf_do_9_2_shutdown(const struct sctp_endpoint *ep, | |||
| 2544 | sctp_shutdownhdr_t *sdh; | 2544 | sctp_shutdownhdr_t *sdh; |
| 2545 | sctp_disposition_t disposition; | 2545 | sctp_disposition_t disposition; |
| 2546 | struct sctp_ulpevent *ev; | 2546 | struct sctp_ulpevent *ev; |
| 2547 | __u32 ctsn; | ||
| 2547 | 2548 | ||
| 2548 | if (!sctp_vtag_verify(chunk, asoc)) | 2549 | if (!sctp_vtag_verify(chunk, asoc)) |
| 2549 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); | 2550 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); |
| @@ -2558,6 +2559,14 @@ sctp_disposition_t sctp_sf_do_9_2_shutdown(const struct sctp_endpoint *ep, | |||
| 2558 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; | 2559 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; |
| 2559 | skb_pull(chunk->skb, sizeof(sctp_shutdownhdr_t)); | 2560 | skb_pull(chunk->skb, sizeof(sctp_shutdownhdr_t)); |
| 2560 | chunk->subh.shutdown_hdr = sdh; | 2561 | chunk->subh.shutdown_hdr = sdh; |
| 2562 | ctsn = ntohl(sdh->cum_tsn_ack); | ||
| 2563 | |||
| 2564 | /* If Cumulative TSN Ack beyond the max tsn currently | ||
| 2565 | * send, terminating the association and respond to the | ||
| 2566 | * sender with an ABORT. | ||
| 2567 | */ | ||
| 2568 | if (!TSN_lt(ctsn, asoc->next_tsn)) | ||
| 2569 | return sctp_sf_violation_ctsn(ep, asoc, type, arg, commands); | ||
| 2561 | 2570 | ||
| 2562 | /* API 5.3.1.5 SCTP_SHUTDOWN_EVENT | 2571 | /* API 5.3.1.5 SCTP_SHUTDOWN_EVENT |
| 2563 | * When a peer sends a SHUTDOWN, SCTP delivers this notification to | 2572 | * When a peer sends a SHUTDOWN, SCTP delivers this notification to |
| @@ -2599,6 +2608,51 @@ out: | |||
| 2599 | return disposition; | 2608 | return disposition; |
| 2600 | } | 2609 | } |
| 2601 | 2610 | ||
| 2611 | /* | ||
| 2612 | * sctp_sf_do_9_2_shut_ctsn | ||
| 2613 | * | ||
| 2614 | * Once an endpoint has reached the SHUTDOWN-RECEIVED state, | ||
| 2615 | * it MUST NOT send a SHUTDOWN in response to a ULP request. | ||
| 2616 | * The Cumulative TSN Ack of the received SHUTDOWN chunk | ||
| 2617 | * MUST be processed. | ||
| 2618 | */ | ||
| 2619 | sctp_disposition_t sctp_sf_do_9_2_shut_ctsn(const struct sctp_endpoint *ep, | ||
| 2620 | const struct sctp_association *asoc, | ||
| 2621 | const sctp_subtype_t type, | ||
| 2622 | void *arg, | ||
| 2623 | sctp_cmd_seq_t *commands) | ||
| 2624 | { | ||
| 2625 | struct sctp_chunk *chunk = arg; | ||
| 2626 | sctp_shutdownhdr_t *sdh; | ||
| 2627 | |||
| 2628 | if (!sctp_vtag_verify(chunk, asoc)) | ||
| 2629 | return sctp_sf_pdiscard(ep, asoc, type, arg, commands); | ||
| 2630 | |||
| 2631 | /* Make sure that the SHUTDOWN chunk has a valid length. */ | ||
| 2632 | if (!sctp_chunk_length_valid(chunk, | ||
| 2633 | sizeof(struct sctp_shutdown_chunk_t))) | ||
| 2634 | return sctp_sf_violation_chunklen(ep, asoc, type, arg, | ||
| 2635 | commands); | ||
| 2636 | |||
| 2637 | sdh = (sctp_shutdownhdr_t *)chunk->skb->data; | ||
| 2638 | |||
| 2639 | /* If Cumulative TSN Ack beyond the max tsn currently | ||
| 2640 | * send, terminating the association and respond to the | ||
| 2641 | * sender with an ABORT. | ||
| 2642 | */ | ||
| 2643 | if (!TSN_lt(ntohl(sdh->cum_tsn_ack), asoc->next_tsn)) | ||
| 2644 | return sctp_sf_violation_ctsn(ep, asoc, type, arg, commands); | ||
| 2645 | |||
| 2646 | /* verify, by checking the Cumulative TSN Ack field of the | ||
| 2647 | * chunk, that all its outstanding DATA chunks have been | ||
| 2648 | * received by the SHUTDOWN sender. | ||
| 2649 | */ | ||
| 2650 | sctp_add_cmd_sf(commands, SCTP_CMD_PROCESS_CTSN, | ||
| 2651 | SCTP_BE32(sdh->cum_tsn_ack)); | ||
| 2652 | |||
| 2653 | return SCTP_DISPOSITION_CONSUME; | ||
| 2654 | } | ||
| 2655 | |||
| 2602 | /* RFC 2960 9.2 | 2656 | /* RFC 2960 9.2 |
| 2603 | * If an endpoint is in SHUTDOWN-ACK-SENT state and receives an INIT chunk | 2657 | * If an endpoint is in SHUTDOWN-ACK-SENT state and receives an INIT chunk |
| 2604 | * (e.g., if the SHUTDOWN COMPLETE was lost) with source and destination | 2658 | * (e.g., if the SHUTDOWN COMPLETE was lost) with source and destination |
diff --git a/net/sctp/sm_statetable.c b/net/sctp/sm_statetable.c index dd4ddc40c0ad..5c8186d88c61 100644 --- a/net/sctp/sm_statetable.c +++ b/net/sctp/sm_statetable.c | |||
| @@ -266,11 +266,11 @@ const sctp_sm_table_entry_t *sctp_sm_lookup_event(sctp_event_t event_type, | |||
| 266 | /* SCTP_STATE_ESTABLISHED */ \ | 266 | /* SCTP_STATE_ESTABLISHED */ \ |
| 267 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ | 267 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ |
| 268 | /* SCTP_STATE_SHUTDOWN_PENDING */ \ | 268 | /* SCTP_STATE_SHUTDOWN_PENDING */ \ |
| 269 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 269 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown), \ |
| 270 | /* SCTP_STATE_SHUTDOWN_SENT */ \ | 270 | /* SCTP_STATE_SHUTDOWN_SENT */ \ |
| 271 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown_ack), \ | 271 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shutdown_ack), \ |
| 272 | /* SCTP_STATE_SHUTDOWN_RECEIVED */ \ | 272 | /* SCTP_STATE_SHUTDOWN_RECEIVED */ \ |
| 273 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 273 | TYPE_SCTP_FUNC(sctp_sf_do_9_2_shut_ctsn), \ |
| 274 | /* SCTP_STATE_SHUTDOWN_ACK_SENT */ \ | 274 | /* SCTP_STATE_SHUTDOWN_ACK_SENT */ \ |
| 275 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ | 275 | TYPE_SCTP_FUNC(sctp_sf_discard_chunk), \ |
| 276 | } /* TYPE_SCTP_SHUTDOWN */ | 276 | } /* TYPE_SCTP_SHUTDOWN */ |
diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index f7e8e93ff30d..14ee68e991dd 100755 --- a/scripts/checkstack.pl +++ b/scripts/checkstack.pl | |||
| @@ -14,6 +14,7 @@ | |||
| 14 | # M68k port by Geert Uytterhoeven and Andreas Schwab | 14 | # M68k port by Geert Uytterhoeven and Andreas Schwab |
| 15 | # AVR32 port by Haavard Skinnemoen <hskinnemoen@atmel.com> | 15 | # AVR32 port by Haavard Skinnemoen <hskinnemoen@atmel.com> |
| 16 | # PARISC port by Kyle McMartin <kyle@parisc-linux.org> | 16 | # PARISC port by Kyle McMartin <kyle@parisc-linux.org> |
| 17 | # sparc port by Martin Habets <errandir_news@mph.eclipse.co.uk> | ||
| 17 | # | 18 | # |
| 18 | # Usage: | 19 | # Usage: |
| 19 | # objdump -d vmlinux | scripts/checkstack.pl [arch] | 20 | # objdump -d vmlinux | scripts/checkstack.pl [arch] |
| @@ -94,6 +95,9 @@ my (@stack, $re, $dre, $x, $xs); | |||
| 94 | } elsif ($arch =~ /^blackfin$/) { | 95 | } elsif ($arch =~ /^blackfin$/) { |
| 95 | # 0: 00 e8 38 01 LINK 0x4e0; | 96 | # 0: 00 e8 38 01 LINK 0x4e0; |
| 96 | $re = qr/.*[[:space:]]LINK[[:space:]]*(0x$x{1,8})/o; | 97 | $re = qr/.*[[:space:]]LINK[[:space:]]*(0x$x{1,8})/o; |
| 98 | } elsif ($arch eq 'sparc' || $arch eq 'sparc64') { | ||
| 99 | # f0019d10: 9d e3 bf 90 save %sp, -112, %sp | ||
| 100 | $re = qr/.*save.*%sp, -(([0-9]{2}|[3-9])[0-9]{2}), %sp/o; | ||
| 97 | } else { | 101 | } else { |
| 98 | print("wrong or unknown architecture \"$arch\"\n"); | 102 | print("wrong or unknown architecture \"$arch\"\n"); |
| 99 | exit | 103 | exit |
diff --git a/sound/aoa/soundbus/i2sbus/i2sbus-core.c b/sound/aoa/soundbus/i2sbus/i2sbus-core.c index e6beb92c6933..b4590df07466 100644 --- a/sound/aoa/soundbus/i2sbus/i2sbus-core.c +++ b/sound/aoa/soundbus/i2sbus/i2sbus-core.c | |||
| @@ -159,7 +159,7 @@ static int i2sbus_add_dev(struct macio_dev *macio, | |||
| 159 | struct i2sbus_dev *dev; | 159 | struct i2sbus_dev *dev; |
| 160 | struct device_node *child = NULL, *sound = NULL; | 160 | struct device_node *child = NULL, *sound = NULL; |
| 161 | struct resource *r; | 161 | struct resource *r; |
| 162 | int i, layout = 0, rlen; | 162 | int i, layout = 0, rlen, ok = force; |
| 163 | static const char *rnames[] = { "i2sbus: %s (control)", | 163 | static const char *rnames[] = { "i2sbus: %s (control)", |
| 164 | "i2sbus: %s (tx)", | 164 | "i2sbus: %s (tx)", |
| 165 | "i2sbus: %s (rx)" }; | 165 | "i2sbus: %s (rx)" }; |
| @@ -192,7 +192,7 @@ static int i2sbus_add_dev(struct macio_dev *macio, | |||
| 192 | layout = *layout_id; | 192 | layout = *layout_id; |
| 193 | snprintf(dev->sound.modalias, 32, | 193 | snprintf(dev->sound.modalias, 32, |
| 194 | "sound-layout-%d", layout); | 194 | "sound-layout-%d", layout); |
| 195 | force = 1; | 195 | ok = 1; |
| 196 | } | 196 | } |
| 197 | } | 197 | } |
| 198 | /* for the time being, until we can handle non-layout-id | 198 | /* for the time being, until we can handle non-layout-id |
| @@ -201,7 +201,7 @@ static int i2sbus_add_dev(struct macio_dev *macio, | |||
| 201 | * When there are two i2s busses and only one has a layout-id, | 201 | * When there are two i2s busses and only one has a layout-id, |
| 202 | * then this depends on the order, but that isn't important | 202 | * then this depends on the order, but that isn't important |
| 203 | * either as the second one in that case is just a modem. */ | 203 | * either as the second one in that case is just a modem. */ |
| 204 | if (!force) { | 204 | if (!ok) { |
| 205 | kfree(dev); | 205 | kfree(dev); |
| 206 | return -ENODEV; | 206 | return -ENODEV; |
| 207 | } | 207 | } |
diff --git a/sound/arm/pxa2xx-pcm-lib.c b/sound/arm/pxa2xx-pcm-lib.c index 1c93eb77cb99..75a0d746fb60 100644 --- a/sound/arm/pxa2xx-pcm-lib.c +++ b/sound/arm/pxa2xx-pcm-lib.c | |||
| @@ -194,7 +194,7 @@ int __pxa2xx_pcm_open(struct snd_pcm_substream *substream) | |||
| 194 | goto out; | 194 | goto out; |
| 195 | 195 | ||
| 196 | ret = -ENOMEM; | 196 | ret = -ENOMEM; |
| 197 | rtd = kmalloc(sizeof(*rtd), GFP_KERNEL); | 197 | rtd = kzalloc(sizeof(*rtd), GFP_KERNEL); |
| 198 | if (!rtd) | 198 | if (!rtd) |
| 199 | goto out; | 199 | goto out; |
| 200 | rtd->dma_desc_array = | 200 | rtd->dma_desc_array = |
diff --git a/sound/drivers/pcsp/pcsp_lib.c b/sound/drivers/pcsp/pcsp_lib.c index e341f3f83b6a..1f42e4063118 100644 --- a/sound/drivers/pcsp/pcsp_lib.c +++ b/sound/drivers/pcsp/pcsp_lib.c | |||
| @@ -34,7 +34,7 @@ enum hrtimer_restart pcsp_do_timer(struct hrtimer *handle) | |||
| 34 | chip->thalf = 0; | 34 | chip->thalf = 0; |
| 35 | if (!atomic_read(&chip->timer_active)) | 35 | if (!atomic_read(&chip->timer_active)) |
| 36 | return HRTIMER_NORESTART; | 36 | return HRTIMER_NORESTART; |
| 37 | hrtimer_forward(&chip->timer, chip->timer.expires, | 37 | hrtimer_forward(&chip->timer, hrtimer_get_expires(&chip->timer), |
| 38 | ktime_set(0, chip->ns_rem)); | 38 | ktime_set(0, chip->ns_rem)); |
| 39 | return HRTIMER_RESTART; | 39 | return HRTIMER_RESTART; |
| 40 | } | 40 | } |
| @@ -118,7 +118,8 @@ enum hrtimer_restart pcsp_do_timer(struct hrtimer *handle) | |||
| 118 | chip->ns_rem = PCSP_PERIOD_NS(); | 118 | chip->ns_rem = PCSP_PERIOD_NS(); |
| 119 | ns = (chip->thalf ? PCSP_CALC_NS(timer_cnt) : chip->ns_rem); | 119 | ns = (chip->thalf ? PCSP_CALC_NS(timer_cnt) : chip->ns_rem); |
| 120 | chip->ns_rem -= ns; | 120 | chip->ns_rem -= ns; |
| 121 | hrtimer_forward(&chip->timer, chip->timer.expires, ktime_set(0, ns)); | 121 | hrtimer_forward(&chip->timer, hrtimer_get_expires(&chip->timer), |
| 122 | ktime_set(0, ns)); | ||
| 122 | return HRTIMER_RESTART; | 123 | return HRTIMER_RESTART; |
| 123 | 124 | ||
| 124 | exit_nr_unlock2: | 125 | exit_nr_unlock2: |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index e72707cb60a3..ef4955c73c88 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
| @@ -4996,7 +4996,7 @@ static struct hda_verb alc260_test_init_verbs[] = { | |||
| 4996 | */ | 4996 | */ |
| 4997 | 4997 | ||
| 4998 | static int alc260_add_playback_controls(struct alc_spec *spec, hda_nid_t nid, | 4998 | static int alc260_add_playback_controls(struct alc_spec *spec, hda_nid_t nid, |
| 4999 | const char *pfx) | 4999 | const char *pfx, int *vol_bits) |
| 5000 | { | 5000 | { |
| 5001 | hda_nid_t nid_vol; | 5001 | hda_nid_t nid_vol; |
| 5002 | unsigned long vol_val, sw_val; | 5002 | unsigned long vol_val, sw_val; |
| @@ -5018,10 +5018,14 @@ static int alc260_add_playback_controls(struct alc_spec *spec, hda_nid_t nid, | |||
| 5018 | } else | 5018 | } else |
| 5019 | return 0; /* N/A */ | 5019 | return 0; /* N/A */ |
| 5020 | 5020 | ||
| 5021 | snprintf(name, sizeof(name), "%s Playback Volume", pfx); | 5021 | if (!(*vol_bits & (1 << nid_vol))) { |
| 5022 | err = add_control(spec, ALC_CTL_WIDGET_VOL, name, vol_val); | 5022 | /* first control for the volume widget */ |
| 5023 | if (err < 0) | 5023 | snprintf(name, sizeof(name), "%s Playback Volume", pfx); |
| 5024 | return err; | 5024 | err = add_control(spec, ALC_CTL_WIDGET_VOL, name, vol_val); |
| 5025 | if (err < 0) | ||
| 5026 | return err; | ||
| 5027 | *vol_bits |= (1 << nid_vol); | ||
| 5028 | } | ||
| 5025 | snprintf(name, sizeof(name), "%s Playback Switch", pfx); | 5029 | snprintf(name, sizeof(name), "%s Playback Switch", pfx); |
| 5026 | err = add_control(spec, ALC_CTL_WIDGET_MUTE, name, sw_val); | 5030 | err = add_control(spec, ALC_CTL_WIDGET_MUTE, name, sw_val); |
| 5027 | if (err < 0) | 5031 | if (err < 0) |
| @@ -5035,6 +5039,7 @@ static int alc260_auto_create_multi_out_ctls(struct alc_spec *spec, | |||
| 5035 | { | 5039 | { |
| 5036 | hda_nid_t nid; | 5040 | hda_nid_t nid; |
| 5037 | int err; | 5041 | int err; |
| 5042 | int vols = 0; | ||
| 5038 | 5043 | ||
| 5039 | spec->multiout.num_dacs = 1; | 5044 | spec->multiout.num_dacs = 1; |
| 5040 | spec->multiout.dac_nids = spec->private_dac_nids; | 5045 | spec->multiout.dac_nids = spec->private_dac_nids; |
| @@ -5042,21 +5047,22 @@ static int alc260_auto_create_multi_out_ctls(struct alc_spec *spec, | |||
| 5042 | 5047 | ||
| 5043 | nid = cfg->line_out_pins[0]; | 5048 | nid = cfg->line_out_pins[0]; |
| 5044 | if (nid) { | 5049 | if (nid) { |
| 5045 | err = alc260_add_playback_controls(spec, nid, "Front"); | 5050 | err = alc260_add_playback_controls(spec, nid, "Front", &vols); |
| 5046 | if (err < 0) | 5051 | if (err < 0) |
| 5047 | return err; | 5052 | return err; |
| 5048 | } | 5053 | } |
| 5049 | 5054 | ||
| 5050 | nid = cfg->speaker_pins[0]; | 5055 | nid = cfg->speaker_pins[0]; |
| 5051 | if (nid) { | 5056 | if (nid) { |
| 5052 | err = alc260_add_playback_controls(spec, nid, "Speaker"); | 5057 | err = alc260_add_playback_controls(spec, nid, "Speaker", &vols); |
| 5053 | if (err < 0) | 5058 | if (err < 0) |
| 5054 | return err; | 5059 | return err; |
| 5055 | } | 5060 | } |
| 5056 | 5061 | ||
| 5057 | nid = cfg->hp_pins[0]; | 5062 | nid = cfg->hp_pins[0]; |
| 5058 | if (nid) { | 5063 | if (nid) { |
| 5059 | err = alc260_add_playback_controls(spec, nid, "Headphone"); | 5064 | err = alc260_add_playback_controls(spec, nid, "Headphone", |
| 5065 | &vols); | ||
| 5060 | if (err < 0) | 5066 | if (err < 0) |
| 5061 | return err; | 5067 | return err; |
| 5062 | } | 5068 | } |
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c index a2ac7205d45d..788fdc6f3264 100644 --- a/sound/pci/hda/patch_sigmatel.c +++ b/sound/pci/hda/patch_sigmatel.c | |||
| @@ -1282,7 +1282,7 @@ static int stac92xx_build_controls(struct hda_codec *codec) | |||
| 1282 | return err; | 1282 | return err; |
| 1283 | spec->multiout.share_spdif = 1; | 1283 | spec->multiout.share_spdif = 1; |
| 1284 | } | 1284 | } |
| 1285 | if (spec->dig_in_nid && (!spec->gpio_dir & 0x01)) { | 1285 | if (spec->dig_in_nid && !(spec->gpio_dir & 0x01)) { |
| 1286 | err = snd_hda_create_spdif_in_ctls(codec, spec->dig_in_nid); | 1286 | err = snd_hda_create_spdif_in_ctls(codec, spec->dig_in_nid); |
| 1287 | if (err < 0) | 1287 | if (err < 0) |
| 1288 | return err; | 1288 | return err; |
diff --git a/sound/soc/codecs/tlv320aic3x.c b/sound/soc/codecs/tlv320aic3x.c index 05336ed7e493..cff276ee261e 100644 --- a/sound/soc/codecs/tlv320aic3x.c +++ b/sound/soc/codecs/tlv320aic3x.c | |||
| @@ -863,17 +863,21 @@ static int aic3x_set_dai_fmt(struct snd_soc_dai *codec_dai, | |||
| 863 | return -EINVAL; | 863 | return -EINVAL; |
| 864 | } | 864 | } |
| 865 | 865 | ||
| 866 | /* interface format */ | 866 | /* |
| 867 | switch (fmt & SND_SOC_DAIFMT_FORMAT_MASK) { | 867 | * match both interface format and signal polarities since they |
| 868 | case SND_SOC_DAIFMT_I2S: | 868 | * are fixed |
| 869 | */ | ||
| 870 | switch (fmt & (SND_SOC_DAIFMT_FORMAT_MASK | | ||
| 871 | SND_SOC_DAIFMT_INV_MASK)) { | ||
| 872 | case (SND_SOC_DAIFMT_I2S | SND_SOC_DAIFMT_NB_NF): | ||
| 869 | break; | 873 | break; |
| 870 | case SND_SOC_DAIFMT_DSP_A: | 874 | case (SND_SOC_DAIFMT_DSP_B | SND_SOC_DAIFMT_IB_NF): |
| 871 | iface_breg |= (0x01 << 6); | 875 | iface_breg |= (0x01 << 6); |
| 872 | break; | 876 | break; |
| 873 | case SND_SOC_DAIFMT_RIGHT_J: | 877 | case (SND_SOC_DAIFMT_RIGHT_J | SND_SOC_DAIFMT_NB_NF): |
| 874 | iface_breg |= (0x02 << 6); | 878 | iface_breg |= (0x02 << 6); |
| 875 | break; | 879 | break; |
| 876 | case SND_SOC_DAIFMT_LEFT_J: | 880 | case (SND_SOC_DAIFMT_LEFT_J | SND_SOC_DAIFMT_NB_NF): |
| 877 | iface_breg |= (0x03 << 6); | 881 | iface_breg |= (0x03 << 6); |
| 878 | break; | 882 | break; |
| 879 | default: | 883 | default: |
diff --git a/sound/soc/omap/omap-mcbsp.c b/sound/soc/omap/omap-mcbsp.c index 853b33ae3435..8485a8a9d0ff 100644 --- a/sound/soc/omap/omap-mcbsp.c +++ b/sound/soc/omap/omap-mcbsp.c | |||
| @@ -265,7 +265,7 @@ static int omap_mcbsp_dai_hw_params(struct snd_pcm_substream *substream, | |||
| 265 | break; | 265 | break; |
| 266 | case SND_SOC_DAIFMT_DSP_A: | 266 | case SND_SOC_DAIFMT_DSP_A: |
| 267 | regs->srgr2 |= FPER(wlen * 2 - 1); | 267 | regs->srgr2 |= FPER(wlen * 2 - 1); |
| 268 | regs->srgr1 |= FWID(0); | 268 | regs->srgr1 |= FWID(wlen * 2 - 2); |
| 269 | break; | 269 | break; |
| 270 | } | 270 | } |
| 271 | 271 | ||
| @@ -284,7 +284,6 @@ static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai, | |||
| 284 | { | 284 | { |
| 285 | struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); | 285 | struct omap_mcbsp_data *mcbsp_data = to_mcbsp(cpu_dai->private_data); |
| 286 | struct omap_mcbsp_reg_cfg *regs = &mcbsp_data->regs; | 286 | struct omap_mcbsp_reg_cfg *regs = &mcbsp_data->regs; |
| 287 | unsigned int temp_fmt = fmt; | ||
| 288 | 287 | ||
| 289 | if (mcbsp_data->configured) | 288 | if (mcbsp_data->configured) |
| 290 | return 0; | 289 | return 0; |
| @@ -307,8 +306,6 @@ static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai, | |||
| 307 | /* 0-bit data delay */ | 306 | /* 0-bit data delay */ |
| 308 | regs->rcr2 |= RDATDLY(0); | 307 | regs->rcr2 |= RDATDLY(0); |
| 309 | regs->xcr2 |= XDATDLY(0); | 308 | regs->xcr2 |= XDATDLY(0); |
| 310 | /* Invert bit clock and FS polarity configuration for DSP_A */ | ||
| 311 | temp_fmt ^= SND_SOC_DAIFMT_IB_IF; | ||
| 312 | break; | 309 | break; |
| 313 | default: | 310 | default: |
| 314 | /* Unsupported data format */ | 311 | /* Unsupported data format */ |
| @@ -332,7 +329,7 @@ static int omap_mcbsp_dai_set_dai_fmt(struct snd_soc_dai *cpu_dai, | |||
| 332 | } | 329 | } |
| 333 | 330 | ||
| 334 | /* Set bit clock (CLKX/CLKR) and FS polarities */ | 331 | /* Set bit clock (CLKX/CLKR) and FS polarities */ |
| 335 | switch (temp_fmt & SND_SOC_DAIFMT_INV_MASK) { | 332 | switch (fmt & SND_SOC_DAIFMT_INV_MASK) { |
| 336 | case SND_SOC_DAIFMT_NB_NF: | 333 | case SND_SOC_DAIFMT_NB_NF: |
| 337 | /* | 334 | /* |
| 338 | * Normal BCLK + FS. | 335 | * Normal BCLK + FS. |
