linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
@ 2007-06-03  8:00 Andrey Borzenkov
  2007-06-03  8:16 ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-03  8:00 UTC (permalink / raw)
  To: samuel; +Cc: linux-kernel, Michal Piotrowski, ambx1


[-- Attachment #1.1: Type: text/plain, Size: 2630 bytes --]

Under 2.6.22-rc I lost irda0 interface - smsc claims no device present. 
Nothing was changed in setup except kernel version.

2.6.21:

Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip, 
pre-configuring device.
Activated ALi 1533 ISA bridge port 0x02e8.
Activated ALi 1533 ISA bridge port 0x02f8.
found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): LPC47N227
smsc_superio_flat(): IrDA not enabled
smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, mode: 0x02
SMsC IrDA Controller found
 IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
No transceiver found. Defaulting to Fast pin select
IrDA: Registered device irda0


2.6.22-rc3:
Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip, 
pre-configuring device.
Activated ALi 1533 ISA bridge port 0x02e8.
Activated ALi 1533 ISA bridge port 0x02f8.
pnp: Device 00:0a activated.
smsc_ircc_present(), addr 0x02e8 - no device found!
pnp: Device 00:0a disabled.

I Cc Adam because of pnp messages in this case - they were not present in 
2.6.21 so something is being done differently now.

Some more info:

{pts/1}% cat /sys/bus/pnp/devices/00:0a/id
SMCf010
{pts/1}% lspci -nn
00:00.0 Host bridge [0600]: ALi Corporation M1644/M1644T Northbridge+Trident 
[10b9:1644] (rev 01)
00:01.0 PCI bridge [0604]: ALi Corporation PCI to AGP Controller [10b9:5247]
00:02.0 USB Controller [0c03]: ALi Corporation USB 1.1 Controller [10b9:5237] 
(rev 03)
00:04.0 IDE interface [0101]: ALi Corporation M5229 IDE [10b9:5229] (rev c3)
00:06.0 Multimedia audio controller [0401]: ALi Corporation M5451 PCI AC-Link 
Controller Audio Device [10b9:5451] (rev 01)
00:07.0 ISA bridge [0601]: ALi Corporation M1533/M1535 PCI to ISA Bridge 
[Aladdin IV/V/V+] [10b9:1533]
00:08.0 Bridge [0680]: ALi Corporation M7101 Power Management Controller [PMU] 
[10b9:7101]
00:0a.0 Ethernet controller [0200]: Intel Corporation 82557/8/9 [Ethernet Pro 
100] [8086:1229] (rev 08)
00:10.0 CardBus bridge [0607]: Texas Instruments PCI1410 PC card Cardbus 
Controller [104c:ac50] (rev 01)
00:11.0 CardBus bridge [0607]: Toshiba America Info Systems ToPIC100 PCI to 
Cardbus Bridge with ZV Support [1179:0617] (rev 32)
00:11.1 CardBus bridge [0607]: Toshiba America Info Systems ToPIC100 PCI to 
Cardbus Bridge with ZV Support [1179:0617] (rev 32)
00:12.0 System peripheral [0880]: Toshiba America Info Systems SD TypA 
Controller [1179:0805] (rev 03)
01:00.0 VGA compatible controller [0300]: Trident Microsystems CyberBlade 
XPAi1 [1023:8820] (rev 82)

config from 2.6.22-rc3 attached.

-andrey

[-- Attachment #1.2: .config --]
[-- Type: text/plain, Size: 50460 bytes --]

#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.22-rc3
# Sun Jun  3 00:02:29 2007
#
CONFIG_X86_32=y
CONFIG_GENERIC_TIME=y
CONFIG_CLOCKSOURCE_WATCHDOG=y
CONFIG_GENERIC_CLOCKEVENTS=y
CONFIG_GENERIC_CLOCKEVENTS_BROADCAST=y
CONFIG_LOCKDEP_SUPPORT=y
CONFIG_STACKTRACE_SUPPORT=y
CONFIG_SEMAPHORE_SLEEPERS=y
CONFIG_X86=y
CONFIG_MMU=y
CONFIG_ZONE_DMA=y
CONFIG_QUICKLIST=y
CONFIG_GENERIC_ISA_DMA=y
CONFIG_GENERIC_IOMAP=y
CONFIG_GENERIC_BUG=y
CONFIG_GENERIC_HWEIGHT=y
CONFIG_ARCH_MAY_HAVE_PC_FDC=y
CONFIG_DMI=y
CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"

#
# Code maturity level options
#
CONFIG_EXPERIMENTAL=y
CONFIG_BROKEN_ON_SMP=y
CONFIG_INIT_ENV_ARG_LIMIT=32

#
# General setup
#
CONFIG_LOCALVERSION=""
# CONFIG_LOCALVERSION_AUTO is not set
CONFIG_SWAP=y
CONFIG_SYSVIPC=y
# CONFIG_IPC_NS is not set
CONFIG_SYSVIPC_SYSCTL=y
CONFIG_POSIX_MQUEUE=y
CONFIG_BSD_PROCESS_ACCT=y
CONFIG_BSD_PROCESS_ACCT_V3=y
# CONFIG_TASKSTATS is not set
# CONFIG_UTS_NS is not set
CONFIG_AUDIT=y
CONFIG_AUDITSYSCALL=y
# CONFIG_IKCONFIG is not set
CONFIG_LOG_BUF_SHIFT=17
# CONFIG_SYSFS_DEPRECATED is not set
CONFIG_RELAY=y
CONFIG_BLK_DEV_INITRD=y
CONFIG_INITRAMFS_SOURCE=""
# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
CONFIG_UID16=y
# CONFIG_SYSCTL_SYSCALL is not set
CONFIG_KALLSYMS=y
CONFIG_KALLSYMS_ALL=y
CONFIG_KALLSYMS_EXTRA_PASS=y
CONFIG_HOTPLUG=y
CONFIG_PRINTK=y
CONFIG_BUG=y
CONFIG_ELF_CORE=y
CONFIG_BASE_FULL=y
CONFIG_FUTEX=y
CONFIG_ANON_INODES=y
CONFIG_EPOLL=y
CONFIG_SIGNALFD=y
CONFIG_TIMERFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_VM_EVENT_COUNTERS=y
CONFIG_SLAB=y
# CONFIG_SLUB is not set
# CONFIG_SLOB is not set
CONFIG_RT_MUTEXES=y
# CONFIG_TINY_SHMEM is not set
CONFIG_BASE_SMALL=0

#
# Loadable module support
#
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
CONFIG_MODULE_FORCE_UNLOAD=y
CONFIG_MODVERSIONS=y
# CONFIG_MODULE_SRCVERSION_ALL is not set
CONFIG_KMOD=y

#
# Block layer
#
CONFIG_BLOCK=y
# CONFIG_LBD is not set
# CONFIG_BLK_DEV_IO_TRACE is not set
# CONFIG_LSF is not set

#
# IO Schedulers
#
CONFIG_IOSCHED_NOOP=y
CONFIG_IOSCHED_AS=y
CONFIG_IOSCHED_DEADLINE=y
CONFIG_IOSCHED_CFQ=y
# CONFIG_DEFAULT_AS is not set
# CONFIG_DEFAULT_DEADLINE is not set
CONFIG_DEFAULT_CFQ=y
# CONFIG_DEFAULT_NOOP is not set
CONFIG_DEFAULT_IOSCHED="cfq"

#
# Processor type and features
#
CONFIG_TICK_ONESHOT=y
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
# CONFIG_SMP is not set
CONFIG_X86_PC=y
# CONFIG_X86_ELAN is not set
# CONFIG_X86_VOYAGER is not set
# CONFIG_X86_NUMAQ is not set
# CONFIG_X86_SUMMIT is not set
# CONFIG_X86_BIGSMP is not set
# CONFIG_X86_VISWS is not set
# CONFIG_X86_GENERICARCH is not set
# CONFIG_X86_ES7000 is not set
# CONFIG_PARAVIRT is not set
# CONFIG_M386 is not set
# CONFIG_M486 is not set
# CONFIG_M586 is not set
# CONFIG_M586TSC is not set
# CONFIG_M586MMX is not set
# CONFIG_M686 is not set
# CONFIG_MPENTIUMII is not set
CONFIG_MPENTIUMIII=y
# CONFIG_MPENTIUMM is not set
# CONFIG_MCORE2 is not set
# CONFIG_MPENTIUM4 is not set
# CONFIG_MK6 is not set
# CONFIG_MK7 is not set
# CONFIG_MK8 is not set
# CONFIG_MCRUSOE is not set
# CONFIG_MEFFICEON is not set
# CONFIG_MWINCHIPC6 is not set
# CONFIG_MWINCHIP2 is not set
# CONFIG_MWINCHIP3D is not set
# CONFIG_MGEODEGX1 is not set
# CONFIG_MGEODE_LX is not set
# CONFIG_MCYRIXIII is not set
# CONFIG_MVIAC3_2 is not set
# CONFIG_MVIAC7 is not set
# CONFIG_X86_GENERIC is not set
CONFIG_X86_CMPXCHG=y
CONFIG_X86_L1_CACHE_SHIFT=5
CONFIG_X86_XADD=y
CONFIG_RWSEM_XCHGADD_ALGORITHM=y
# CONFIG_ARCH_HAS_ILOG2_U32 is not set
# CONFIG_ARCH_HAS_ILOG2_U64 is not set
CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_X86_WP_WORKS_OK=y
CONFIG_X86_INVLPG=y
CONFIG_X86_BSWAP=y
CONFIG_X86_POPAD_OK=y
CONFIG_X86_CMPXCHG64=y
CONFIG_X86_GOOD_APIC=y
CONFIG_X86_INTEL_USERCOPY=y
CONFIG_X86_USE_PPRO_CHECKSUM=y
CONFIG_X86_TSC=y
CONFIG_X86_CMOV=y
CONFIG_X86_MINIMUM_CPU_MODEL=4
CONFIG_HPET_TIMER=y
CONFIG_HPET_EMULATE_RTC=y
# CONFIG_PREEMPT_NONE is not set
CONFIG_PREEMPT_VOLUNTARY=y
# CONFIG_PREEMPT is not set
CONFIG_X86_UP_APIC=y
CONFIG_X86_UP_IOAPIC=y
CONFIG_X86_LOCAL_APIC=y
CONFIG_X86_IO_APIC=y
CONFIG_X86_MCE=y
# CONFIG_X86_MCE_NONFATAL is not set
# CONFIG_X86_MCE_P4THERMAL is not set
CONFIG_VM86=y
CONFIG_TOSHIBA=m
# CONFIG_I8K is not set
CONFIG_X86_REBOOTFIXUPS=y
CONFIG_MICROCODE=m
CONFIG_MICROCODE_OLD_INTERFACE=y
CONFIG_X86_MSR=m
CONFIG_X86_CPUID=m

#
# Firmware Drivers
#
CONFIG_EDD=y
# CONFIG_DELL_RBU is not set
# CONFIG_DCDBAS is not set
CONFIG_NOHIGHMEM=y
# CONFIG_HIGHMEM4G is not set
# CONFIG_HIGHMEM64G is not set
CONFIG_VMSPLIT_3G=y
# CONFIG_VMSPLIT_3G_OPT is not set
# CONFIG_VMSPLIT_2G is not set
# CONFIG_VMSPLIT_2G_OPT is not set
# CONFIG_VMSPLIT_1G is not set
CONFIG_PAGE_OFFSET=0xC0000000
CONFIG_ARCH_FLATMEM_ENABLE=y
CONFIG_ARCH_SPARSEMEM_ENABLE=y
CONFIG_ARCH_SELECT_MEMORY_MODEL=y
CONFIG_ARCH_POPULATES_NODE_MAP=y
CONFIG_SELECT_MEMORY_MODEL=y
CONFIG_FLATMEM_MANUAL=y
# CONFIG_DISCONTIGMEM_MANUAL is not set
# CONFIG_SPARSEMEM_MANUAL is not set
CONFIG_FLATMEM=y
CONFIG_FLAT_NODE_MEM_MAP=y
CONFIG_SPARSEMEM_STATIC=y
CONFIG_SPLIT_PTLOCK_CPUS=4
# CONFIG_RESOURCES_64BIT is not set
CONFIG_ZONE_DMA_FLAG=1
CONFIG_NR_QUICK=1
# CONFIG_MATH_EMULATION is not set
CONFIG_MTRR=y
# CONFIG_EFI is not set
CONFIG_SECCOMP=y
# CONFIG_HZ_100 is not set
# CONFIG_HZ_250 is not set
CONFIG_HZ_300=y
# CONFIG_HZ_1000 is not set
CONFIG_HZ=300
# CONFIG_KEXEC is not set
CONFIG_PHYSICAL_START=0x100000
# CONFIG_RELOCATABLE is not set
CONFIG_PHYSICAL_ALIGN=0x100000
# CONFIG_COMPAT_VDSO is not set

#
# Power management options (ACPI, APM)
#
CONFIG_PM=y
# CONFIG_PM_LEGACY is not set
# CONFIG_PM_DEBUG is not set
# CONFIG_PM_SYSFS_DEPRECATED is not set
CONFIG_SOFTWARE_SUSPEND=y
CONFIG_PM_STD_PARTITION=""

#
# ACPI (Advanced Configuration and Power Interface) Support
#
CONFIG_ACPI=y
CONFIG_ACPI_SLEEP=y
CONFIG_ACPI_SLEEP_PROC_FS=y
# CONFIG_ACPI_SLEEP_PROC_SLEEP is not set
# CONFIG_ACPI_PROCFS is not set
CONFIG_ACPI_AC=m
CONFIG_ACPI_BATTERY=m
CONFIG_ACPI_BUTTON=m
CONFIG_ACPI_VIDEO=m
CONFIG_ACPI_FAN=m
# CONFIG_ACPI_DOCK is not set
CONFIG_ACPI_PROCESSOR=m
CONFIG_ACPI_THERMAL=m
# CONFIG_ACPI_ASUS is not set
CONFIG_ACPI_TOSHIBA=m
# CONFIG_ACPI_CUSTOM_DSDT is not set
CONFIG_ACPI_BLACKLIST_YEAR=0
# CONFIG_ACPI_DEBUG is not set
CONFIG_ACPI_EC=y
CONFIG_ACPI_POWER=y
CONFIG_ACPI_SYSTEM=y
CONFIG_X86_PM_TIMER=y
CONFIG_ACPI_CONTAINER=m
CONFIG_ACPI_SBS=m
# CONFIG_APM is not set

#
# CPU Frequency scaling
#
CONFIG_CPU_FREQ=y
CONFIG_CPU_FREQ_TABLE=y
# CONFIG_CPU_FREQ_DEBUG is not set
CONFIG_CPU_FREQ_STAT=y
CONFIG_CPU_FREQ_STAT_DETAILS=y
# CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE is not set
CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y
CONFIG_CPU_FREQ_GOV_PERFORMANCE=m
CONFIG_CPU_FREQ_GOV_POWERSAVE=m
CONFIG_CPU_FREQ_GOV_USERSPACE=y
CONFIG_CPU_FREQ_GOV_ONDEMAND=m
CONFIG_CPU_FREQ_GOV_CONSERVATIVE=m

#
# CPUFreq processor drivers
#
CONFIG_X86_ACPI_CPUFREQ=m
# CONFIG_X86_POWERNOW_K6 is not set
# CONFIG_X86_POWERNOW_K7 is not set
# CONFIG_X86_POWERNOW_K8 is not set
# CONFIG_X86_GX_SUSPMOD is not set
# CONFIG_X86_SPEEDSTEP_CENTRINO is not set
# CONFIG_X86_SPEEDSTEP_ICH is not set
# CONFIG_X86_SPEEDSTEP_SMI is not set
# CONFIG_X86_P4_CLOCKMOD is not set
# CONFIG_X86_CPUFREQ_NFORCE2 is not set
# CONFIG_X86_LONGRUN is not set
# CONFIG_X86_LONGHAUL is not set
# CONFIG_X86_E_POWERSAVER is not set

#
# shared options
#
# CONFIG_X86_ACPI_CPUFREQ_PROC_INTF is not set
# CONFIG_X86_SPEEDSTEP_LIB is not set

#
# Bus options (PCI, PCMCIA, EISA, MCA, ISA)
#
CONFIG_PCI=y
# CONFIG_PCI_GOBIOS is not set
# CONFIG_PCI_GOMMCONFIG is not set
# CONFIG_PCI_GODIRECT is not set
CONFIG_PCI_GOANY=y
CONFIG_PCI_BIOS=y
CONFIG_PCI_DIRECT=y
CONFIG_PCI_MMCONFIG=y
# CONFIG_PCIEPORTBUS is not set
CONFIG_ARCH_SUPPORTS_MSI=y
# CONFIG_PCI_MSI is not set
# CONFIG_PCI_DEBUG is not set
CONFIG_HT_IRQ=y
CONFIG_ISA_DMA_API=y
# CONFIG_ISA is not set
# CONFIG_MCA is not set
# CONFIG_SCx200 is not set

#
# PCCARD (PCMCIA/CardBus) support
#
CONFIG_PCCARD=m
# CONFIG_PCMCIA_DEBUG is not set
CONFIG_PCMCIA=m
CONFIG_PCMCIA_LOAD_CIS=y
CONFIG_PCMCIA_IOCTL=y
CONFIG_CARDBUS=y

#
# PC-card bridges
#
CONFIG_YENTA=m
CONFIG_YENTA_O2=y
CONFIG_YENTA_RICOH=y
CONFIG_YENTA_TI=y
CONFIG_YENTA_ENE_TUNE=y
CONFIG_YENTA_TOSHIBA=y
# CONFIG_PD6729 is not set
# CONFIG_I82092 is not set
CONFIG_PCCARD_NONSTATIC=m
# CONFIG_HOTPLUG_PCI is not set

#
# Executable file formats
#
CONFIG_BINFMT_ELF=y
CONFIG_BINFMT_AOUT=m
CONFIG_BINFMT_MISC=m

#
# Networking
#
CONFIG_NET=y

#
# Networking options
#
CONFIG_PACKET=m
CONFIG_PACKET_MMAP=y
CONFIG_UNIX=y
CONFIG_XFRM=y
CONFIG_XFRM_USER=m
# CONFIG_XFRM_SUB_POLICY is not set
# CONFIG_XFRM_MIGRATE is not set
CONFIG_NET_KEY=m
# CONFIG_NET_KEY_MIGRATE is not set
CONFIG_INET=y
CONFIG_IP_MULTICAST=y
CONFIG_IP_ADVANCED_ROUTER=y
CONFIG_ASK_IP_FIB_HASH=y
# CONFIG_IP_FIB_TRIE is not set
CONFIG_IP_FIB_HASH=y
CONFIG_IP_MULTIPLE_TABLES=y
CONFIG_IP_ROUTE_MULTIPATH=y
CONFIG_IP_ROUTE_MULTIPATH_CACHED=y
CONFIG_IP_ROUTE_MULTIPATH_RR=m
CONFIG_IP_ROUTE_MULTIPATH_RANDOM=m
CONFIG_IP_ROUTE_MULTIPATH_WRANDOM=m
CONFIG_IP_ROUTE_MULTIPATH_DRR=m
CONFIG_IP_ROUTE_VERBOSE=y
# CONFIG_IP_PNP is not set
CONFIG_NET_IPIP=m
CONFIG_NET_IPGRE=m
CONFIG_NET_IPGRE_BROADCAST=y
CONFIG_IP_MROUTE=y
CONFIG_IP_PIMSM_V1=y
CONFIG_IP_PIMSM_V2=y
# CONFIG_ARPD is not set
CONFIG_SYN_COOKIES=y
CONFIG_INET_AH=m
CONFIG_INET_ESP=m
CONFIG_INET_IPCOMP=m
CONFIG_INET_XFRM_TUNNEL=m
CONFIG_INET_TUNNEL=m
CONFIG_INET_XFRM_MODE_TRANSPORT=m
CONFIG_INET_XFRM_MODE_TUNNEL=m
CONFIG_INET_XFRM_MODE_BEET=m
CONFIG_INET_DIAG=y
CONFIG_INET_TCP_DIAG=y
CONFIG_TCP_CONG_ADVANCED=y
CONFIG_TCP_CONG_BIC=m
CONFIG_TCP_CONG_CUBIC=m
CONFIG_TCP_CONG_WESTWOOD=m
CONFIG_TCP_CONG_HTCP=m
CONFIG_TCP_CONG_HSTCP=m
CONFIG_TCP_CONG_HYBLA=m
CONFIG_TCP_CONG_VEGAS=m
CONFIG_TCP_CONG_SCALABLE=m
CONFIG_TCP_CONG_LP=m
CONFIG_TCP_CONG_VENO=m
# CONFIG_TCP_CONG_YEAH is not set
# CONFIG_TCP_CONG_ILLINOIS is not set
# CONFIG_DEFAULT_BIC is not set
# CONFIG_DEFAULT_CUBIC is not set
# CONFIG_DEFAULT_HTCP is not set
# CONFIG_DEFAULT_VEGAS is not set
# CONFIG_DEFAULT_WESTWOOD is not set
CONFIG_DEFAULT_RENO=y
CONFIG_DEFAULT_TCP_CONG="reno"
# CONFIG_TCP_MD5SIG is not set
# CONFIG_IP_VS is not set
# CONFIG_IPV6 is not set
# CONFIG_INET6_XFRM_TUNNEL is not set
# CONFIG_INET6_TUNNEL is not set
# CONFIG_NETWORK_SECMARK is not set
CONFIG_NETFILTER=y
# CONFIG_NETFILTER_DEBUG is not set
CONFIG_BRIDGE_NETFILTER=y

#
# Core Netfilter Configuration
#
CONFIG_NETFILTER_NETLINK=m
CONFIG_NETFILTER_NETLINK_QUEUE=m
CONFIG_NETFILTER_NETLINK_LOG=m
CONFIG_NF_CONNTRACK_ENABLED=m
CONFIG_NF_CONNTRACK=m
# CONFIG_NF_CT_ACCT is not set
CONFIG_NF_CONNTRACK_MARK=y
# CONFIG_NF_CONNTRACK_EVENTS is not set
CONFIG_NF_CT_PROTO_GRE=m
# CONFIG_NF_CT_PROTO_SCTP is not set
# CONFIG_NF_CONNTRACK_AMANDA is not set
CONFIG_NF_CONNTRACK_FTP=m
CONFIG_NF_CONNTRACK_H323=m
CONFIG_NF_CONNTRACK_IRC=m
CONFIG_NF_CONNTRACK_NETBIOS_NS=m
CONFIG_NF_CONNTRACK_PPTP=m
# CONFIG_NF_CONNTRACK_SANE is not set
CONFIG_NF_CONNTRACK_SIP=m
CONFIG_NF_CONNTRACK_TFTP=m
CONFIG_NF_CT_NETLINK=m
CONFIG_NETFILTER_XTABLES=m
CONFIG_NETFILTER_XT_TARGET_CLASSIFY=m
CONFIG_NETFILTER_XT_TARGET_CONNMARK=m
# CONFIG_NETFILTER_XT_TARGET_DSCP is not set
CONFIG_NETFILTER_XT_TARGET_MARK=m
CONFIG_NETFILTER_XT_TARGET_NFQUEUE=m
CONFIG_NETFILTER_XT_TARGET_NFLOG=m
CONFIG_NETFILTER_XT_TARGET_NOTRACK=m
# CONFIG_NETFILTER_XT_TARGET_TCPMSS is not set
CONFIG_NETFILTER_XT_MATCH_COMMENT=m
# CONFIG_NETFILTER_XT_MATCH_CONNBYTES is not set
CONFIG_NETFILTER_XT_MATCH_CONNMARK=m
CONFIG_NETFILTER_XT_MATCH_CONNTRACK=m
CONFIG_NETFILTER_XT_MATCH_DCCP=m
# CONFIG_NETFILTER_XT_MATCH_DSCP is not set
# CONFIG_NETFILTER_XT_MATCH_ESP is not set
CONFIG_NETFILTER_XT_MATCH_HELPER=m
CONFIG_NETFILTER_XT_MATCH_LENGTH=m
CONFIG_NETFILTER_XT_MATCH_LIMIT=m
CONFIG_NETFILTER_XT_MATCH_MAC=m
CONFIG_NETFILTER_XT_MATCH_MARK=m
# CONFIG_NETFILTER_XT_MATCH_POLICY is not set
# CONFIG_NETFILTER_XT_MATCH_MULTIPORT is not set
CONFIG_NETFILTER_XT_MATCH_PHYSDEV=m
CONFIG_NETFILTER_XT_MATCH_PKTTYPE=m
# CONFIG_NETFILTER_XT_MATCH_QUOTA is not set
CONFIG_NETFILTER_XT_MATCH_REALM=m
CONFIG_NETFILTER_XT_MATCH_SCTP=m
CONFIG_NETFILTER_XT_MATCH_STATE=m
# CONFIG_NETFILTER_XT_MATCH_STATISTIC is not set
CONFIG_NETFILTER_XT_MATCH_STRING=m
CONFIG_NETFILTER_XT_MATCH_TCPMSS=m
CONFIG_NETFILTER_XT_MATCH_HASHLIMIT=m

#
# IP: Netfilter Configuration
#
CONFIG_NF_CONNTRACK_IPV4=m
CONFIG_NF_CONNTRACK_PROC_COMPAT=y
# CONFIG_IP_NF_QUEUE is not set
CONFIG_IP_NF_IPTABLES=m
CONFIG_IP_NF_MATCH_IPRANGE=m
CONFIG_IP_NF_MATCH_TOS=m
CONFIG_IP_NF_MATCH_RECENT=m
CONFIG_IP_NF_MATCH_ECN=m
# CONFIG_IP_NF_MATCH_AH is not set
CONFIG_IP_NF_MATCH_TTL=m
CONFIG_IP_NF_MATCH_OWNER=m
CONFIG_IP_NF_MATCH_ADDRTYPE=m
CONFIG_IP_NF_FILTER=m
CONFIG_IP_NF_TARGET_REJECT=m
CONFIG_IP_NF_TARGET_LOG=m
CONFIG_IP_NF_TARGET_ULOG=m
CONFIG_NF_NAT=m
CONFIG_NF_NAT_NEEDED=y
CONFIG_IP_NF_TARGET_MASQUERADE=m
CONFIG_IP_NF_TARGET_REDIRECT=m
CONFIG_IP_NF_TARGET_NETMAP=m
CONFIG_IP_NF_TARGET_SAME=m
CONFIG_NF_NAT_SNMP_BASIC=m
CONFIG_NF_NAT_PROTO_GRE=m
CONFIG_NF_NAT_FTP=m
CONFIG_NF_NAT_IRC=m
CONFIG_NF_NAT_TFTP=m
# CONFIG_NF_NAT_AMANDA is not set
CONFIG_NF_NAT_PPTP=m
CONFIG_NF_NAT_H323=m
CONFIG_NF_NAT_SIP=m
CONFIG_IP_NF_MANGLE=m
CONFIG_IP_NF_TARGET_TOS=m
CONFIG_IP_NF_TARGET_ECN=m
CONFIG_IP_NF_TARGET_TTL=m
# CONFIG_IP_NF_TARGET_CLUSTERIP is not set
CONFIG_IP_NF_RAW=m
CONFIG_IP_NF_ARPTABLES=m
CONFIG_IP_NF_ARPFILTER=m
CONFIG_IP_NF_ARP_MANGLE=m

#
# Bridge: Netfilter Configuration
#
CONFIG_BRIDGE_NF_EBTABLES=m
CONFIG_BRIDGE_EBT_BROUTE=m
CONFIG_BRIDGE_EBT_T_FILTER=m
CONFIG_BRIDGE_EBT_T_NAT=m
CONFIG_BRIDGE_EBT_802_3=m
CONFIG_BRIDGE_EBT_AMONG=m
CONFIG_BRIDGE_EBT_ARP=m
CONFIG_BRIDGE_EBT_IP=m
CONFIG_BRIDGE_EBT_LIMIT=m
CONFIG_BRIDGE_EBT_MARK=m
CONFIG_BRIDGE_EBT_PKTTYPE=m
CONFIG_BRIDGE_EBT_STP=m
CONFIG_BRIDGE_EBT_VLAN=m
CONFIG_BRIDGE_EBT_ARPREPLY=m
CONFIG_BRIDGE_EBT_DNAT=m
CONFIG_BRIDGE_EBT_MARK_T=m
CONFIG_BRIDGE_EBT_REDIRECT=m
CONFIG_BRIDGE_EBT_SNAT=m
CONFIG_BRIDGE_EBT_LOG=m
CONFIG_BRIDGE_EBT_ULOG=m
# CONFIG_IP_DCCP is not set
# CONFIG_IP_SCTP is not set
# CONFIG_TIPC is not set
# CONFIG_ATM is not set
CONFIG_BRIDGE=m
CONFIG_VLAN_8021Q=m
# CONFIG_DECNET is not set
CONFIG_LLC=m
# CONFIG_LLC2 is not set
# CONFIG_IPX is not set
# CONFIG_ATALK is not set
# CONFIG_X25 is not set
# CONFIG_LAPB is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set

#
# QoS and/or fair queueing
#
CONFIG_NET_SCHED=y
CONFIG_NET_SCH_FIFO=y

#
# Queueing/Scheduling
#
CONFIG_NET_SCH_CBQ=m
CONFIG_NET_SCH_HTB=m
CONFIG_NET_SCH_HFSC=m
CONFIG_NET_SCH_PRIO=m
CONFIG_NET_SCH_RED=m
CONFIG_NET_SCH_SFQ=m
CONFIG_NET_SCH_TEQL=m
CONFIG_NET_SCH_TBF=m
CONFIG_NET_SCH_GRED=m
CONFIG_NET_SCH_DSMARK=m
CONFIG_NET_SCH_NETEM=m
CONFIG_NET_SCH_INGRESS=m

#
# Classification
#
CONFIG_NET_CLS=y
CONFIG_NET_CLS_BASIC=m
CONFIG_NET_CLS_TCINDEX=m
CONFIG_NET_CLS_ROUTE4=m
CONFIG_NET_CLS_ROUTE=y
CONFIG_NET_CLS_FW=m
CONFIG_NET_CLS_U32=m
CONFIG_CLS_U32_PERF=y
CONFIG_CLS_U32_MARK=y
CONFIG_NET_CLS_RSVP=m
CONFIG_NET_CLS_RSVP6=m
CONFIG_NET_EMATCH=y
CONFIG_NET_EMATCH_STACK=32
CONFIG_NET_EMATCH_CMP=m
CONFIG_NET_EMATCH_NBYTE=m
CONFIG_NET_EMATCH_U32=m
CONFIG_NET_EMATCH_META=m
CONFIG_NET_EMATCH_TEXT=m
CONFIG_NET_CLS_ACT=y
CONFIG_NET_ACT_POLICE=m
CONFIG_NET_ACT_GACT=m
CONFIG_GACT_PROB=y
CONFIG_NET_ACT_MIRRED=m
CONFIG_NET_ACT_IPT=m
CONFIG_NET_ACT_PEDIT=m
CONFIG_NET_ACT_SIMP=m
CONFIG_NET_CLS_IND=y
CONFIG_NET_ESTIMATOR=y

#
# Network testing
#
CONFIG_NET_PKTGEN=m
# CONFIG_NET_TCPPROBE is not set
# CONFIG_HAMRADIO is not set
CONFIG_IRDA=m

#
# IrDA protocols
#
CONFIG_IRLAN=m
CONFIG_IRNET=m
CONFIG_IRCOMM=m
CONFIG_IRDA_ULTRA=y

#
# IrDA options
#
CONFIG_IRDA_CACHE_LAST_LSAP=y
CONFIG_IRDA_FAST_RR=y
# CONFIG_IRDA_DEBUG is not set

#
# Infrared-port device drivers
#

#
# SIR device drivers
#
CONFIG_IRTTY_SIR=m

#
# Dongle support
#
# CONFIG_DONGLE is not set
# CONFIG_KINGSUN_DONGLE is not set

#
# Old SIR device drivers
#
CONFIG_IRPORT_SIR=m

#
# Old Serial dongle support
#
# CONFIG_DONGLE_OLD is not set

#
# FIR device drivers
#
# CONFIG_USB_IRDA is not set
# CONFIG_SIGMATEL_FIR is not set
# CONFIG_NSC_FIR is not set
# CONFIG_WINBOND_FIR is not set
CONFIG_TOSHIBA_FIR=m
CONFIG_SMC_IRCC_FIR=m
CONFIG_ALI_FIR=m
# CONFIG_VLSI_FIR is not set
# CONFIG_VIA_FIR is not set
# CONFIG_MCS_FIR is not set
CONFIG_BT=m
CONFIG_BT_L2CAP=m
# CONFIG_BT_SCO is not set
CONFIG_BT_RFCOMM=m
CONFIG_BT_RFCOMM_TTY=y
CONFIG_BT_BNEP=m
# CONFIG_BT_BNEP_MC_FILTER is not set
# CONFIG_BT_BNEP_PROTO_FILTER is not set
# CONFIG_BT_HIDP is not set

#
# Bluetooth device drivers
#
CONFIG_BT_HCIUSB=m
# CONFIG_BT_HCIUSB_SCO is not set
# CONFIG_BT_HCIUART is not set
# CONFIG_BT_HCIBCM203X is not set
# CONFIG_BT_HCIBPA10X is not set
# CONFIG_BT_HCIBFUSB is not set
# CONFIG_BT_HCIDTL1 is not set
# CONFIG_BT_HCIBT3C is not set
# CONFIG_BT_HCIBLUECARD is not set
# CONFIG_BT_HCIBTUART is not set
# CONFIG_BT_HCIVHCI is not set
# CONFIG_AF_RXRPC is not set
CONFIG_FIB_RULES=y

#
# Wireless
#
CONFIG_CFG80211=m
CONFIG_WIRELESS_EXT=y
CONFIG_MAC80211=m
# CONFIG_MAC80211_DEBUG is not set
CONFIG_IEEE80211=m
# CONFIG_IEEE80211_DEBUG is not set
CONFIG_IEEE80211_CRYPT_WEP=m
CONFIG_IEEE80211_CRYPT_CCMP=m
CONFIG_IEEE80211_CRYPT_TKIP=m
# CONFIG_IEEE80211_SOFTMAC is not set
# CONFIG_RFKILL is not set

#
# Device Drivers
#

#
# Generic Driver Options
#
# CONFIG_STANDALONE is not set
CONFIG_PREVENT_FIRMWARE_BUILD=y
CONFIG_FW_LOADER=m
# CONFIG_DEBUG_DRIVER is not set
# CONFIG_DEBUG_DEVRES is not set
# CONFIG_SYS_HYPERVISOR is not set

#
# Connector - unified userspace <-> kernelspace linker
#
CONFIG_CONNECTOR=m
# CONFIG_MTD is not set

#
# Parallel port support
#
# CONFIG_PARPORT is not set

#
# Plug and Play support
#
CONFIG_PNP=y
# CONFIG_PNP_DEBUG is not set

#
# Protocols
#
CONFIG_PNPACPI=y

#
# Block devices
#
# CONFIG_BLK_DEV_FD is not set
# CONFIG_BLK_CPQ_DA is not set
# CONFIG_BLK_CPQ_CISS_DA is not set
# CONFIG_BLK_DEV_DAC960 is not set
# CONFIG_BLK_DEV_UMEM is not set
# CONFIG_BLK_DEV_COW_COMMON is not set
CONFIG_BLK_DEV_LOOP=m
CONFIG_BLK_DEV_CRYPTOLOOP=m
CONFIG_BLK_DEV_NBD=m
# CONFIG_BLK_DEV_SX8 is not set
# CONFIG_BLK_DEV_UB is not set
CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_COUNT=16
CONFIG_BLK_DEV_RAM_SIZE=32000
CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024
CONFIG_CDROM_PKTCDVD=y
CONFIG_CDROM_PKTCDVD_BUFFERS=8
# CONFIG_CDROM_PKTCDVD_WCACHE is not set
# CONFIG_ATA_OVER_ETH is not set

#
# Misc devices
#
# CONFIG_IBM_ASM is not set
# CONFIG_PHANTOM is not set
# CONFIG_SGI_IOC4 is not set
# CONFIG_TIFM_CORE is not set
# CONFIG_MSI_LAPTOP is not set
# CONFIG_SONY_LAPTOP is not set
# CONFIG_THINKPAD_ACPI is not set
# CONFIG_BLINK is not set
# CONFIG_IDE is not set

#
# SCSI device support
#
# CONFIG_RAID_ATTRS is not set
CONFIG_SCSI=m
CONFIG_SCSI_TGT=m
# CONFIG_SCSI_NETLINK is not set
CONFIG_SCSI_PROC_FS=y

#
# SCSI support type (disk, tape, CD-ROM)
#
CONFIG_BLK_DEV_SD=m
# CONFIG_CHR_DEV_ST is not set
# CONFIG_CHR_DEV_OSST is not set
CONFIG_BLK_DEV_SR=m
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=m
# CONFIG_CHR_DEV_SCH is not set

#
# Some SCSI devices (e.g. CD jukebox) support multiple LUNs
#
CONFIG_SCSI_MULTI_LUN=y
CONFIG_SCSI_CONSTANTS=y
CONFIG_SCSI_LOGGING=y
# CONFIG_SCSI_SCAN_ASYNC is not set
CONFIG_SCSI_WAIT_SCAN=m

#
# SCSI Transports
#
CONFIG_SCSI_SPI_ATTRS=m
# CONFIG_SCSI_FC_ATTRS is not set
CONFIG_SCSI_ISCSI_ATTRS=m
# CONFIG_SCSI_SAS_ATTRS is not set
# CONFIG_SCSI_SAS_LIBSAS is not set

#
# SCSI low-level drivers
#
# CONFIG_ISCSI_TCP is not set
# CONFIG_BLK_DEV_3W_XXXX_RAID is not set
# CONFIG_SCSI_3W_9XXX is not set
# CONFIG_SCSI_ACARD is not set
# CONFIG_SCSI_AACRAID is not set
# CONFIG_SCSI_AIC7XXX is not set
# CONFIG_SCSI_AIC7XXX_OLD is not set
# CONFIG_SCSI_AIC79XX is not set
# CONFIG_SCSI_AIC94XX is not set
# CONFIG_SCSI_DPT_I2O is not set
# CONFIG_SCSI_ADVANSYS is not set
# CONFIG_SCSI_ARCMSR is not set
# CONFIG_MEGARAID_NEWGEN is not set
# CONFIG_MEGARAID_LEGACY is not set
# CONFIG_MEGARAID_SAS is not set
# CONFIG_SCSI_HPTIOP is not set
# CONFIG_SCSI_BUSLOGIC is not set
# CONFIG_SCSI_DMX3191D is not set
# CONFIG_SCSI_EATA is not set
# CONFIG_SCSI_FUTURE_DOMAIN is not set
# CONFIG_SCSI_GDTH is not set
# CONFIG_SCSI_IPS is not set
# CONFIG_SCSI_INITIO is not set
# CONFIG_SCSI_INIA100 is not set
# CONFIG_SCSI_STEX is not set
# CONFIG_SCSI_SYM53C8XX_2 is not set
# CONFIG_SCSI_IPR is not set
# CONFIG_SCSI_QLOGIC_1280 is not set
# CONFIG_SCSI_QLA_FC is not set
# CONFIG_SCSI_QLA_ISCSI is not set
# CONFIG_SCSI_LPFC is not set
# CONFIG_SCSI_DC395x is not set
# CONFIG_SCSI_DC390T is not set
# CONFIG_SCSI_NSP32 is not set
# CONFIG_SCSI_DEBUG is not set
# CONFIG_SCSI_ESP_CORE is not set
# CONFIG_SCSI_SRP is not set

#
# PCMCIA SCSI adapter support
#
# CONFIG_PCMCIA_AHA152X is not set
# CONFIG_PCMCIA_FDOMAIN is not set
# CONFIG_PCMCIA_NINJA_SCSI is not set
# CONFIG_PCMCIA_QLOGIC is not set
# CONFIG_PCMCIA_SYM53C500 is not set
CONFIG_ATA=m
# CONFIG_ATA_NONSTANDARD is not set
CONFIG_ATA_ACPI=y
# CONFIG_SATA_AHCI is not set
# CONFIG_SATA_SVW is not set
# CONFIG_ATA_PIIX is not set
# CONFIG_SATA_MV is not set
# CONFIG_SATA_NV is not set
# CONFIG_PDC_ADMA is not set
# CONFIG_SATA_QSTOR is not set
# CONFIG_SATA_PROMISE is not set
# CONFIG_SATA_SX4 is not set
# CONFIG_SATA_SIL is not set
# CONFIG_SATA_SIL24 is not set
# CONFIG_SATA_SIS is not set
# CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set
# CONFIG_SATA_VITESSE is not set
# CONFIG_SATA_INIC162X is not set
CONFIG_PATA_ALI=m
# CONFIG_PATA_AMD is not set
# CONFIG_PATA_ARTOP is not set
# CONFIG_PATA_ATIIXP is not set
# CONFIG_PATA_CMD640_PCI is not set
# CONFIG_PATA_CMD64X is not set
# CONFIG_PATA_CS5520 is not set
# CONFIG_PATA_CS5530 is not set
# CONFIG_PATA_CS5535 is not set
# CONFIG_PATA_CYPRESS is not set
# CONFIG_PATA_EFAR is not set
CONFIG_ATA_GENERIC=m
# CONFIG_PATA_HPT366 is not set
# CONFIG_PATA_HPT37X is not set
# CONFIG_PATA_HPT3X2N is not set
# CONFIG_PATA_HPT3X3 is not set
# CONFIG_PATA_IT821X is not set
# CONFIG_PATA_IT8213 is not set
# CONFIG_PATA_JMICRON is not set
# CONFIG_PATA_TRIFLEX is not set
# CONFIG_PATA_MARVELL is not set
# CONFIG_PATA_MPIIX is not set
# CONFIG_PATA_OLDPIIX is not set
# CONFIG_PATA_NETCELL is not set
# CONFIG_PATA_NS87410 is not set
# CONFIG_PATA_OPTI is not set
# CONFIG_PATA_OPTIDMA is not set
# CONFIG_PATA_PCMCIA is not set
# CONFIG_PATA_PDC_OLD is not set
# CONFIG_PATA_RADISYS is not set
# CONFIG_PATA_RZ1000 is not set
# CONFIG_PATA_SC1200 is not set
# CONFIG_PATA_SERVERWORKS is not set
# CONFIG_PATA_PDC2027X is not set
# CONFIG_PATA_SIL680 is not set
# CONFIG_PATA_SIS is not set
# CONFIG_PATA_VIA is not set
# CONFIG_PATA_WINBOND is not set
CONFIG_PATA_PLATFORM=m

#
# Multi-device support (RAID and LVM)
#
CONFIG_MD=y
CONFIG_BLK_DEV_MD=m
CONFIG_MD_LINEAR=m
CONFIG_MD_RAID0=m
CONFIG_MD_RAID1=m
CONFIG_MD_RAID10=m
CONFIG_MD_RAID456=m
CONFIG_MD_RAID5_RESHAPE=y
CONFIG_MD_MULTIPATH=m
CONFIG_MD_FAULTY=m
CONFIG_BLK_DEV_DM=m
# CONFIG_DM_DEBUG is not set
CONFIG_DM_CRYPT=m
CONFIG_DM_SNAPSHOT=m
CONFIG_DM_MIRROR=m
CONFIG_DM_ZERO=m
CONFIG_DM_MULTIPATH=m
CONFIG_DM_MULTIPATH_EMC=m
# CONFIG_DM_DELAY is not set

#
# Fusion MPT device support
#
# CONFIG_FUSION is not set
# CONFIG_FUSION_SPI is not set
# CONFIG_FUSION_FC is not set
# CONFIG_FUSION_SAS is not set

#
# IEEE 1394 (FireWire) support
#
# CONFIG_FIREWIRE is not set
# CONFIG_IEEE1394 is not set

#
# I2O device support
#
# CONFIG_I2O is not set
# CONFIG_MACINTOSH_DRIVERS is not set

#
# Network device support
#
CONFIG_NETDEVICES=y
# CONFIG_IFB is not set
CONFIG_DUMMY=m
CONFIG_BONDING=m
# CONFIG_EQUALIZER is not set
CONFIG_TUN=m
# CONFIG_NET_SB1000 is not set
# CONFIG_ARCNET is not set
# CONFIG_PHYLIB is not set

#
# Ethernet (10 or 100Mbit)
#
CONFIG_NET_ETHERNET=y
CONFIG_MII=m
# CONFIG_HAPPYMEAL is not set
# CONFIG_SUNGEM is not set
# CONFIG_CASSINI is not set
# CONFIG_NET_VENDOR_3COM is not set

#
# Tulip family network device support
#
# CONFIG_NET_TULIP is not set
# CONFIG_HP100 is not set
CONFIG_NET_PCI=y
# CONFIG_PCNET32 is not set
# CONFIG_AMD8111_ETH is not set
# CONFIG_ADAPTEC_STARFIRE is not set
# CONFIG_B44 is not set
# CONFIG_FORCEDETH is not set
# CONFIG_DGRS is not set
# CONFIG_EEPRO100 is not set
CONFIG_E100=m
# CONFIG_FEALNX is not set
# CONFIG_NATSEMI is not set
# CONFIG_NE2K_PCI is not set
# CONFIG_8139CP is not set
# CONFIG_8139TOO is not set
# CONFIG_SIS900 is not set
# CONFIG_EPIC100 is not set
# CONFIG_SUNDANCE is not set
# CONFIG_TLAN is not set
# CONFIG_VIA_RHINE is not set
# CONFIG_SC92031 is not set
# CONFIG_NETDEV_1000 is not set
# CONFIG_NETDEV_10000 is not set
# CONFIG_TR is not set

#
# Wireless LAN
#
# CONFIG_WLAN_PRE80211 is not set
CONFIG_WLAN_80211=y
# CONFIG_PCMCIA_RAYCS is not set
# CONFIG_IPW2100 is not set
# CONFIG_IPW2200 is not set
# CONFIG_LIBERTAS_USB is not set
# CONFIG_AIRO is not set
# CONFIG_HERMES is not set
# CONFIG_ATMEL is not set
# CONFIG_AIRO_CS is not set
# CONFIG_PCMCIA_WL3501 is not set
# CONFIG_PRISM54 is not set
# CONFIG_USB_ZD1201 is not set
# CONFIG_HOSTAP is not set

#
# USB Network Adapters
#
# CONFIG_USB_CATC is not set
# CONFIG_USB_KAWETH is not set
# CONFIG_USB_PEGASUS is not set
# CONFIG_USB_RTL8150 is not set
# CONFIG_USB_USBNET_MII is not set
# CONFIG_USB_USBNET is not set
# CONFIG_NET_PCMCIA is not set
# CONFIG_WAN is not set
# CONFIG_FDDI is not set
# CONFIG_HIPPI is not set
CONFIG_PPP=m
CONFIG_PPP_MULTILINK=y
CONFIG_PPP_FILTER=y
CONFIG_PPP_ASYNC=m
CONFIG_PPP_SYNC_TTY=m
CONFIG_PPP_DEFLATE=m
CONFIG_PPP_BSDCOMP=m
CONFIG_PPP_MPPE=m
CONFIG_PPPOE=m
# CONFIG_SLIP is not set
CONFIG_SLHC=m
# CONFIG_NET_FC is not set
CONFIG_SHAPER=m
CONFIG_NETCONSOLE=m
CONFIG_NETPOLL=y
# CONFIG_NETPOLL_TRAP is not set
CONFIG_NET_POLL_CONTROLLER=y

#
# ISDN subsystem
#
# CONFIG_ISDN is not set

#
# Telephony Support
#
# CONFIG_PHONE is not set

#
# Input device support
#
CONFIG_INPUT=y
# CONFIG_INPUT_FF_MEMLESS is not set

#
# Userland interfaces
#
CONFIG_INPUT_MOUSEDEV=y
CONFIG_INPUT_MOUSEDEV_PSAUX=y
CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024
CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768
CONFIG_INPUT_JOYDEV=m
CONFIG_INPUT_TSDEV=m
CONFIG_INPUT_TSDEV_SCREEN_X=240
CONFIG_INPUT_TSDEV_SCREEN_Y=320
CONFIG_INPUT_EVDEV=m
# CONFIG_INPUT_EVBUG is not set

#
# Input Device Drivers
#
CONFIG_INPUT_KEYBOARD=y
CONFIG_KEYBOARD_ATKBD=y
# CONFIG_KEYBOARD_SUNKBD is not set
# CONFIG_KEYBOARD_LKKBD is not set
# CONFIG_KEYBOARD_XTKBD is not set
# CONFIG_KEYBOARD_NEWTON is not set
# CONFIG_KEYBOARD_STOWAWAY is not set
CONFIG_INPUT_MOUSE=y
CONFIG_MOUSE_PS2=m
# CONFIG_MOUSE_PS2_ALPS is not set
# CONFIG_MOUSE_PS2_LOGIPS2PP is not set
# CONFIG_MOUSE_PS2_SYNAPTICS is not set
# CONFIG_MOUSE_PS2_LIFEBOOK is not set
# CONFIG_MOUSE_PS2_TRACKPOINT is not set
# CONFIG_MOUSE_PS2_TOUCHKIT is not set
# CONFIG_MOUSE_SERIAL is not set
# CONFIG_MOUSE_APPLETOUCH is not set
# CONFIG_MOUSE_VSXXXAA is not set
# CONFIG_INPUT_JOYSTICK is not set
# CONFIG_INPUT_TABLET is not set
# CONFIG_INPUT_TOUCHSCREEN is not set
CONFIG_INPUT_MISC=y
CONFIG_INPUT_PCSPKR=m
# CONFIG_INPUT_WISTRON_BTNS is not set
# CONFIG_INPUT_ATLAS_BTNS is not set
# CONFIG_INPUT_ATI_REMOTE is not set
# CONFIG_INPUT_ATI_REMOTE2 is not set
# CONFIG_INPUT_KEYSPAN_REMOTE is not set
# CONFIG_INPUT_POWERMATE is not set
# CONFIG_INPUT_YEALINK is not set
CONFIG_INPUT_UINPUT=m
# CONFIG_INPUT_POLLDEV is not set

#
# Hardware I/O ports
#
CONFIG_SERIO=y
CONFIG_SERIO_I8042=y
CONFIG_SERIO_SERPORT=y
# CONFIG_SERIO_CT82C710 is not set
# CONFIG_SERIO_PCIPS2 is not set
CONFIG_SERIO_LIBPS2=y
CONFIG_SERIO_RAW=m
# CONFIG_GAMEPORT is not set

#
# Character devices
#
CONFIG_VT=y
CONFIG_VT_CONSOLE=y
CONFIG_HW_CONSOLE=y
CONFIG_VT_HW_CONSOLE_BINDING=y
# CONFIG_SERIAL_NONSTANDARD is not set

#
# Serial drivers
#
CONFIG_SERIAL_8250=m
# CONFIG_SERIAL_8250_PCI is not set
CONFIG_SERIAL_8250_PNP=m
CONFIG_SERIAL_8250_CS=m
CONFIG_SERIAL_8250_NR_UARTS=4
CONFIG_SERIAL_8250_RUNTIME_UARTS=4
CONFIG_SERIAL_8250_EXTENDED=y
# CONFIG_SERIAL_8250_MANY_PORTS is not set
CONFIG_SERIAL_8250_SHARE_IRQ=y
# CONFIG_SERIAL_8250_DETECT_IRQ is not set
# CONFIG_SERIAL_8250_RSA is not set

#
# Non-8250 serial port support
#
CONFIG_SERIAL_CORE=m
# CONFIG_SERIAL_JSM is not set
CONFIG_UNIX98_PTYS=y
CONFIG_LEGACY_PTYS=y
CONFIG_LEGACY_PTY_COUNT=256

#
# IPMI
#
# CONFIG_IPMI_HANDLER is not set
CONFIG_WATCHDOG=y
# CONFIG_WATCHDOG_NOWAYOUT is not set

#
# Watchdog Device Drivers
#
CONFIG_SOFT_WATCHDOG=m
# CONFIG_ACQUIRE_WDT is not set
# CONFIG_ADVANTECH_WDT is not set
CONFIG_ALIM1535_WDT=m
# CONFIG_ALIM7101_WDT is not set
# CONFIG_SC520_WDT is not set
# CONFIG_EUROTECH_WDT is not set
# CONFIG_IB700_WDT is not set
# CONFIG_IBMASR is not set
# CONFIG_WAFER_WDT is not set
# CONFIG_I6300ESB_WDT is not set
# CONFIG_ITCO_WDT is not set
# CONFIG_SC1200_WDT is not set
# CONFIG_PC87413_WDT is not set
# CONFIG_60XX_WDT is not set
# CONFIG_SBC8360_WDT is not set
# CONFIG_CPU5_WDT is not set
# CONFIG_SMSC37B787_WDT is not set
# CONFIG_W83627HF_WDT is not set
# CONFIG_W83697HF_WDT is not set
# CONFIG_W83877F_WDT is not set
# CONFIG_W83977F_WDT is not set
# CONFIG_MACHZ_WDT is not set
# CONFIG_SBC_EPX_C3_WATCHDOG is not set

#
# PCI-based Watchdog Cards
#
# CONFIG_PCIPCWATCHDOG is not set
# CONFIG_WDTPCI is not set

#
# USB-based Watchdog Cards
#
# CONFIG_USBPCWATCHDOG is not set
CONFIG_HW_RANDOM=y
CONFIG_HW_RANDOM_INTEL=m
# CONFIG_HW_RANDOM_AMD is not set
# CONFIG_HW_RANDOM_GEODE is not set
# CONFIG_HW_RANDOM_VIA is not set
CONFIG_NVRAM=m
CONFIG_RTC=y
# CONFIG_R3964 is not set
# CONFIG_APPLICOM is not set
# CONFIG_SONYPI is not set
CONFIG_AGP=m
CONFIG_AGP_ALI=m
# CONFIG_AGP_ATI is not set
# CONFIG_AGP_AMD is not set
# CONFIG_AGP_AMD64 is not set
# CONFIG_AGP_INTEL is not set
# CONFIG_AGP_NVIDIA is not set
# CONFIG_AGP_SIS is not set
# CONFIG_AGP_SWORKS is not set
# CONFIG_AGP_VIA is not set
# CONFIG_AGP_EFFICEON is not set
# CONFIG_DRM is not set

#
# PCMCIA character devices
#
# CONFIG_SYNCLINK_CS is not set
# CONFIG_CARDMAN_4000 is not set
# CONFIG_CARDMAN_4040 is not set
# CONFIG_MWAVE is not set
# CONFIG_PC8736x_GPIO is not set
# CONFIG_NSC_GPIO is not set
# CONFIG_CS5535_GPIO is not set
CONFIG_RAW_DRIVER=m
CONFIG_MAX_RAW_DEVS=256
CONFIG_HPET=y
# CONFIG_HPET_RTC_IRQ is not set
CONFIG_HPET_MMAP=y
CONFIG_HANGCHECK_TIMER=m

#
# TPM devices
#
# CONFIG_TCG_TPM is not set
# CONFIG_TELCLOCK is not set
CONFIG_DEVPORT=y
CONFIG_I2C=m
CONFIG_I2C_BOARDINFO=y
CONFIG_I2C_CHARDEV=m

#
# I2C Algorithms
#
CONFIG_I2C_ALGOBIT=m
CONFIG_I2C_ALGOPCF=m
CONFIG_I2C_ALGOPCA=m

#
# I2C Hardware Bus support
#
CONFIG_I2C_ALI1535=m
# CONFIG_I2C_ALI1563 is not set
# CONFIG_I2C_ALI15X3 is not set
# CONFIG_I2C_AMD756 is not set
# CONFIG_I2C_AMD8111 is not set
# CONFIG_I2C_I801 is not set
# CONFIG_I2C_I810 is not set
# CONFIG_I2C_PIIX4 is not set
# CONFIG_I2C_NFORCE2 is not set
# CONFIG_I2C_OCORES is not set
# CONFIG_I2C_PARPORT_LIGHT is not set
# CONFIG_I2C_PROSAVAGE is not set
# CONFIG_I2C_SAVAGE4 is not set
# CONFIG_I2C_SIMTEC is not set
# CONFIG_SCx200_ACB is not set
# CONFIG_I2C_SIS5595 is not set
# CONFIG_I2C_SIS630 is not set
# CONFIG_I2C_SIS96X is not set
CONFIG_I2C_STUB=m
# CONFIG_I2C_TINY_USB is not set
# CONFIG_I2C_VIA is not set
# CONFIG_I2C_VIAPRO is not set
# CONFIG_I2C_VOODOO3 is not set

#
# Miscellaneous I2C Chip support
#
# CONFIG_SENSORS_DS1337 is not set
# CONFIG_SENSORS_DS1374 is not set
CONFIG_SENSORS_EEPROM=m
# CONFIG_SENSORS_PCF8574 is not set
# CONFIG_SENSORS_PCA9539 is not set
# CONFIG_SENSORS_PCF8591 is not set
# CONFIG_SENSORS_MAX6875 is not set
# CONFIG_I2C_DEBUG_CORE is not set
# CONFIG_I2C_DEBUG_ALGO is not set
# CONFIG_I2C_DEBUG_BUS is not set
# CONFIG_I2C_DEBUG_CHIP is not set

#
# SPI support
#
# CONFIG_SPI is not set
# CONFIG_SPI_MASTER is not set

#
# Dallas's 1-wire bus
#
# CONFIG_W1 is not set
CONFIG_HWMON=m
# CONFIG_HWMON_VID is not set
# CONFIG_SENSORS_ABITUGURU is not set
# CONFIG_SENSORS_AD7418 is not set
# CONFIG_SENSORS_ADM1021 is not set
# CONFIG_SENSORS_ADM1025 is not set
# CONFIG_SENSORS_ADM1026 is not set
# CONFIG_SENSORS_ADM1029 is not set
# CONFIG_SENSORS_ADM1031 is not set
# CONFIG_SENSORS_ADM9240 is not set
# CONFIG_SENSORS_K8TEMP is not set
# CONFIG_SENSORS_ASB100 is not set
# CONFIG_SENSORS_ATXP1 is not set
# CONFIG_SENSORS_DS1621 is not set
# CONFIG_SENSORS_F71805F is not set
# CONFIG_SENSORS_FSCHER is not set
# CONFIG_SENSORS_FSCPOS is not set
# CONFIG_SENSORS_GL518SM is not set
# CONFIG_SENSORS_GL520SM is not set
# CONFIG_SENSORS_CORETEMP is not set
# CONFIG_SENSORS_IT87 is not set
# CONFIG_SENSORS_LM63 is not set
# CONFIG_SENSORS_LM75 is not set
# CONFIG_SENSORS_LM77 is not set
# CONFIG_SENSORS_LM78 is not set
# CONFIG_SENSORS_LM80 is not set
# CONFIG_SENSORS_LM83 is not set
# CONFIG_SENSORS_LM85 is not set
# CONFIG_SENSORS_LM87 is not set
CONFIG_SENSORS_LM90=m
# CONFIG_SENSORS_LM92 is not set
# CONFIG_SENSORS_MAX1619 is not set
# CONFIG_SENSORS_MAX6650 is not set
# CONFIG_SENSORS_PC87360 is not set
# CONFIG_SENSORS_PC87427 is not set
# CONFIG_SENSORS_SIS5595 is not set
# CONFIG_SENSORS_SMSC47M1 is not set
# CONFIG_SENSORS_SMSC47M192 is not set
# CONFIG_SENSORS_SMSC47B397 is not set
# CONFIG_SENSORS_VIA686A is not set
# CONFIG_SENSORS_VT1211 is not set
# CONFIG_SENSORS_VT8231 is not set
# CONFIG_SENSORS_W83781D is not set
# CONFIG_SENSORS_W83791D is not set
# CONFIG_SENSORS_W83792D is not set
# CONFIG_SENSORS_W83793 is not set
# CONFIG_SENSORS_W83L785TS is not set
# CONFIG_SENSORS_W83627HF is not set
# CONFIG_SENSORS_W83627EHF is not set
# CONFIG_SENSORS_HDAPS is not set
# CONFIG_SENSORS_APPLESMC is not set
# CONFIG_HWMON_DEBUG_CHIP is not set

#
# Multifunction device drivers
#
# CONFIG_MFD_SM501 is not set

#
# Multimedia devices
#
# CONFIG_VIDEO_DEV is not set
# CONFIG_DVB_CORE is not set
# CONFIG_DAB is not set

#
# Graphics support
#
CONFIG_BACKLIGHT_LCD_SUPPORT=y
CONFIG_BACKLIGHT_CLASS_DEVICE=m
CONFIG_LCD_CLASS_DEVICE=m
# CONFIG_BACKLIGHT_PROGEAR is not set

#
# Display device support
#
# CONFIG_DISPLAY_SUPPORT is not set
# CONFIG_VGASTATE is not set
CONFIG_FB=y
CONFIG_FIRMWARE_EDID=y
# CONFIG_FB_DDC is not set
CONFIG_FB_CFB_FILLRECT=y
CONFIG_FB_CFB_COPYAREA=y
CONFIG_FB_CFB_IMAGEBLIT=y
# CONFIG_FB_SYS_FILLRECT is not set
# CONFIG_FB_SYS_COPYAREA is not set
# CONFIG_FB_SYS_IMAGEBLIT is not set
# CONFIG_FB_SYS_FOPS is not set
CONFIG_FB_DEFERRED_IO=y
# CONFIG_FB_SVGALIB is not set
# CONFIG_FB_MACMODES is not set
# CONFIG_FB_BACKLIGHT is not set
CONFIG_FB_MODE_HELPERS=y
CONFIG_FB_TILEBLITTING=y

#
# Frame buffer hardware drivers
#
# CONFIG_FB_CIRRUS is not set
# CONFIG_FB_PM2 is not set
# CONFIG_FB_CYBER2000 is not set
# CONFIG_FB_ARC is not set
# CONFIG_FB_ASILIANT is not set
# CONFIG_FB_IMSTT is not set
# CONFIG_FB_VGA16 is not set
CONFIG_FB_VESA=y
# CONFIG_FB_HECUBA is not set
# CONFIG_FB_HGA is not set
# CONFIG_FB_S1D13XXX is not set
# CONFIG_FB_NVIDIA is not set
# CONFIG_FB_RIVA is not set
# CONFIG_FB_I810 is not set
# CONFIG_FB_LE80578 is not set
# CONFIG_FB_INTEL is not set
# CONFIG_FB_MATROX is not set
# CONFIG_FB_RADEON is not set
# CONFIG_FB_ATY128 is not set
# CONFIG_FB_ATY is not set
# CONFIG_FB_S3 is not set
# CONFIG_FB_SAVAGE is not set
# CONFIG_FB_SIS is not set
# CONFIG_FB_NEOMAGIC is not set
# CONFIG_FB_KYRO is not set
# CONFIG_FB_3DFX is not set
# CONFIG_FB_VOODOO1 is not set
# CONFIG_FB_VT8623 is not set
# CONFIG_FB_CYBLA is not set
# CONFIG_FB_TRIDENT is not set
# CONFIG_FB_ARK is not set
# CONFIG_FB_PM3 is not set
# CONFIG_FB_GEODE is not set
# CONFIG_FB_VIRTUAL is not set

#
# Console display driver support
#
CONFIG_VGA_CONSOLE=y
# CONFIG_VGACON_SOFT_SCROLLBACK is not set
CONFIG_VIDEO_SELECT=y
CONFIG_DUMMY_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE=y
# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set
CONFIG_FONTS=y
CONFIG_FONT_8x8=y
CONFIG_FONT_8x16=y
# CONFIG_FONT_6x11 is not set
# CONFIG_FONT_7x14 is not set
# CONFIG_FONT_PEARL_8x8 is not set
# CONFIG_FONT_ACORN_8x8 is not set
# CONFIG_FONT_MINI_4x6 is not set
# CONFIG_FONT_SUN8x16 is not set
# CONFIG_FONT_SUN12x22 is not set
# CONFIG_FONT_10x18 is not set
CONFIG_LOGO=y
CONFIG_LOGO_LINUX_MONO=y
CONFIG_LOGO_LINUX_VGA16=y
CONFIG_LOGO_LINUX_CLUT224=y

#
# Sound
#
CONFIG_SOUND=m

#
# Advanced Linux Sound Architecture
#
CONFIG_SND=m
CONFIG_SND_TIMER=m
CONFIG_SND_PCM=m
CONFIG_SND_RAWMIDI=m
CONFIG_SND_SEQUENCER=m
CONFIG_SND_SEQ_DUMMY=m
CONFIG_SND_OSSEMUL=y
CONFIG_SND_MIXER_OSS=m
CONFIG_SND_PCM_OSS=m
CONFIG_SND_PCM_OSS_PLUGINS=y
CONFIG_SND_SEQUENCER_OSS=y
CONFIG_SND_RTCTIMER=m
CONFIG_SND_SEQ_RTCTIMER_DEFAULT=y
# CONFIG_SND_DYNAMIC_MINORS is not set
CONFIG_SND_SUPPORT_OLD_API=y
CONFIG_SND_VERBOSE_PROCFS=y
# CONFIG_SND_VERBOSE_PRINTK is not set
# CONFIG_SND_DEBUG is not set

#
# Generic devices
#
CONFIG_SND_MPU401_UART=m
CONFIG_SND_AC97_CODEC=m
CONFIG_SND_DUMMY=m
CONFIG_SND_VIRMIDI=m
CONFIG_SND_MTPAV=m
CONFIG_SND_SERIAL_U16550=m
CONFIG_SND_MPU401=m

#
# PCI devices
#
# CONFIG_SND_AD1889 is not set
# CONFIG_SND_ALS300 is not set
# CONFIG_SND_ALS4000 is not set
CONFIG_SND_ALI5451=m
# CONFIG_SND_ATIIXP is not set
# CONFIG_SND_ATIIXP_MODEM is not set
# CONFIG_SND_AU8810 is not set
# CONFIG_SND_AU8820 is not set
# CONFIG_SND_AU8830 is not set
# CONFIG_SND_AZT3328 is not set
# CONFIG_SND_BT87X is not set
# CONFIG_SND_CA0106 is not set
# CONFIG_SND_CMIPCI is not set
# CONFIG_SND_CS4281 is not set
# CONFIG_SND_CS46XX is not set
# CONFIG_SND_CS5535AUDIO is not set
# CONFIG_SND_DARLA20 is not set
# CONFIG_SND_GINA20 is not set
# CONFIG_SND_LAYLA20 is not set
# CONFIG_SND_DARLA24 is not set
# CONFIG_SND_GINA24 is not set
# CONFIG_SND_LAYLA24 is not set
# CONFIG_SND_MONA is not set
# CONFIG_SND_MIA is not set
# CONFIG_SND_ECHO3G is not set
# CONFIG_SND_INDIGO is not set
# CONFIG_SND_INDIGOIO is not set
# CONFIG_SND_INDIGODJ is not set
# CONFIG_SND_EMU10K1 is not set
# CONFIG_SND_EMU10K1X is not set
# CONFIG_SND_ENS1370 is not set
# CONFIG_SND_ENS1371 is not set
# CONFIG_SND_ES1938 is not set
# CONFIG_SND_ES1968 is not set
# CONFIG_SND_FM801 is not set
# CONFIG_SND_HDA_INTEL is not set
# CONFIG_SND_HDSP is not set
# CONFIG_SND_HDSPM is not set
# CONFIG_SND_ICE1712 is not set
# CONFIG_SND_ICE1724 is not set
# CONFIG_SND_INTEL8X0 is not set
# CONFIG_SND_INTEL8X0M is not set
# CONFIG_SND_KORG1212 is not set
# CONFIG_SND_MAESTRO3 is not set
# CONFIG_SND_MIXART is not set
# CONFIG_SND_NM256 is not set
# CONFIG_SND_PCXHR is not set
# CONFIG_SND_RIPTIDE is not set
# CONFIG_SND_RME32 is not set
# CONFIG_SND_RME96 is not set
# CONFIG_SND_RME9652 is not set
# CONFIG_SND_SONICVIBES is not set
# CONFIG_SND_TRIDENT is not set
# CONFIG_SND_VIA82XX is not set
# CONFIG_SND_VIA82XX_MODEM is not set
# CONFIG_SND_VX222 is not set
# CONFIG_SND_YMFPCI is not set
CONFIG_SND_AC97_POWER_SAVE=y

#
# USB devices
#
# CONFIG_SND_USB_AUDIO is not set
# CONFIG_SND_USB_USX2Y is not set
# CONFIG_SND_USB_CAIAQ is not set

#
# PCMCIA devices
#
# CONFIG_SND_VXPOCKET is not set
# CONFIG_SND_PDAUDIOCF is not set

#
# System on Chip audio support
#
# CONFIG_SND_SOC is not set

#
# Open Sound System
#
# CONFIG_SOUND_PRIME is not set
CONFIG_AC97_BUS=m

#
# HID Devices
#
CONFIG_HID=m
# CONFIG_HID_DEBUG is not set

#
# USB Input Devices
#
CONFIG_USB_HID=m
# CONFIG_USB_HIDINPUT_POWERBOOK is not set
# CONFIG_HID_FF is not set
# CONFIG_USB_HIDDEV is not set

#
# USB HID Boot Protocol drivers
#
CONFIG_USB_KBD=m
CONFIG_USB_MOUSE=m

#
# USB support
#
CONFIG_USB_ARCH_HAS_HCD=y
CONFIG_USB_ARCH_HAS_OHCI=y
CONFIG_USB_ARCH_HAS_EHCI=y
CONFIG_USB=m
# CONFIG_USB_DEBUG is not set

#
# Miscellaneous USB options
#
CONFIG_USB_DEVICEFS=y
# CONFIG_USB_DEVICE_CLASS is not set
CONFIG_USB_DYNAMIC_MINORS=y
CONFIG_USB_SUSPEND=y
# CONFIG_USB_OTG is not set

#
# USB Host Controller Drivers
#
# CONFIG_USB_EHCI_HCD is not set
# CONFIG_USB_ISP116X_HCD is not set
CONFIG_USB_OHCI_HCD=m
# CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set
# CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set
CONFIG_USB_OHCI_LITTLE_ENDIAN=y
# CONFIG_USB_UHCI_HCD is not set
# CONFIG_USB_SL811_HCD is not set

#
# USB Device Class drivers
#
CONFIG_USB_ACM=m
CONFIG_USB_PRINTER=m

#
# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support'
#

#
# may also be needed; see USB_STORAGE Help for more information
#
CONFIG_USB_STORAGE=m
# CONFIG_USB_STORAGE_DEBUG is not set
CONFIG_USB_STORAGE_DATAFAB=y
CONFIG_USB_STORAGE_FREECOM=y
CONFIG_USB_STORAGE_DPCM=y
CONFIG_USB_STORAGE_USBAT=y
CONFIG_USB_STORAGE_SDDR09=y
CONFIG_USB_STORAGE_SDDR55=y
CONFIG_USB_STORAGE_JUMPSHOT=y
CONFIG_USB_STORAGE_ALAUDA=y
CONFIG_USB_STORAGE_KARMA=y
# CONFIG_USB_LIBUSUAL is not set

#
# USB Imaging devices
#
# CONFIG_USB_MDC800 is not set
# CONFIG_USB_MICROTEK is not set
# CONFIG_USB_MON is not set

#
# USB port drivers
#

#
# USB Serial Converter support
#
CONFIG_USB_SERIAL=m
CONFIG_USB_SERIAL_GENERIC=y
# CONFIG_USB_SERIAL_AIRCABLE is not set
# CONFIG_USB_SERIAL_AIRPRIME is not set
# CONFIG_USB_SERIAL_ARK3116 is not set
# CONFIG_USB_SERIAL_BELKIN is not set
# CONFIG_USB_SERIAL_WHITEHEAT is not set
# CONFIG_USB_SERIAL_DIGI_ACCELEPORT is not set
# CONFIG_USB_SERIAL_CP2101 is not set
# CONFIG_USB_SERIAL_CYPRESS_M8 is not set
# CONFIG_USB_SERIAL_EMPEG is not set
# CONFIG_USB_SERIAL_FTDI_SIO is not set
# CONFIG_USB_SERIAL_FUNSOFT is not set
# CONFIG_USB_SERIAL_VISOR is not set
# CONFIG_USB_SERIAL_IPAQ is not set
# CONFIG_USB_SERIAL_IR is not set
# CONFIG_USB_SERIAL_EDGEPORT is not set
# CONFIG_USB_SERIAL_EDGEPORT_TI is not set
# CONFIG_USB_SERIAL_GARMIN is not set
# CONFIG_USB_SERIAL_IPW is not set
# CONFIG_USB_SERIAL_KEYSPAN_PDA is not set
# CONFIG_USB_SERIAL_KEYSPAN is not set
# CONFIG_USB_SERIAL_KLSI is not set
# CONFIG_USB_SERIAL_KOBIL_SCT is not set
# CONFIG_USB_SERIAL_MCT_U232 is not set
# CONFIG_USB_SERIAL_MOS7720 is not set
# CONFIG_USB_SERIAL_MOS7840 is not set
# CONFIG_USB_SERIAL_NAVMAN is not set
CONFIG_USB_SERIAL_PL2303=m
# CONFIG_USB_SERIAL_HP4X is not set
# CONFIG_USB_SERIAL_SAFE is not set
# CONFIG_USB_SERIAL_SIERRAWIRELESS is not set
# CONFIG_USB_SERIAL_TI is not set
# CONFIG_USB_SERIAL_CYBERJACK is not set
# CONFIG_USB_SERIAL_XIRCOM is not set
# CONFIG_USB_SERIAL_OPTION is not set
# CONFIG_USB_SERIAL_OMNINET is not set
# CONFIG_USB_SERIAL_DEBUG is not set

#
# USB Miscellaneous drivers
#
# CONFIG_USB_EMI62 is not set
# CONFIG_USB_EMI26 is not set
# CONFIG_USB_ADUTUX is not set
# CONFIG_USB_AUERSWALD is not set
# CONFIG_USB_RIO500 is not set
# CONFIG_USB_LEGOTOWER is not set
# CONFIG_USB_LCD is not set
# CONFIG_USB_BERRY_CHARGE is not set
# CONFIG_USB_LED is not set
# CONFIG_USB_CYPRESS_CY7C63 is not set
# CONFIG_USB_CYTHERM is not set
# CONFIG_USB_PHIDGET is not set
# CONFIG_USB_IDMOUSE is not set
# CONFIG_USB_FTDI_ELAN is not set
# CONFIG_USB_APPLEDISPLAY is not set
# CONFIG_USB_LD is not set
# CONFIG_USB_TRANCEVIBRATOR is not set
# CONFIG_USB_IOWARRIOR is not set
# CONFIG_USB_TEST is not set

#
# USB DSL modem support
#

#
# USB Gadget Support
#
# CONFIG_USB_GADGET is not set
# CONFIG_MMC is not set

#
# LED devices
#
# CONFIG_NEW_LEDS is not set

#
# LED drivers
#

#
# LED Triggers
#

#
# InfiniBand support
#
# CONFIG_INFINIBAND is not set

#
# EDAC - error detection and reporting (RAS) (EXPERIMENTAL)
#
# CONFIG_EDAC is not set

#
# Real Time Clock
#
# CONFIG_RTC_CLASS is not set

#
# DMA Engine support
#
# CONFIG_DMA_ENGINE is not set

#
# DMA Clients
#

#
# DMA Devices
#

#
# Virtualization
#
# CONFIG_KVM is not set

#
# File systems
#
CONFIG_EXT2_FS=m
CONFIG_EXT2_FS_XATTR=y
CONFIG_EXT2_FS_POSIX_ACL=y
CONFIG_EXT2_FS_SECURITY=y
# CONFIG_EXT2_FS_XIP is not set
CONFIG_EXT3_FS=m
CONFIG_EXT3_FS_XATTR=y
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
# CONFIG_EXT4DEV_FS is not set
CONFIG_JBD=m
# CONFIG_JBD_DEBUG is not set
CONFIG_FS_MBCACHE=m
CONFIG_REISERFS_FS=m
# CONFIG_REISERFS_CHECK is not set
CONFIG_REISERFS_PROC_INFO=y
CONFIG_REISERFS_FS_XATTR=y
CONFIG_REISERFS_FS_POSIX_ACL=y
CONFIG_REISERFS_FS_SECURITY=y
# CONFIG_JFS_FS is not set
CONFIG_FS_POSIX_ACL=y
# CONFIG_XFS_FS is not set
# CONFIG_GFS2_FS is not set
# CONFIG_OCFS2_FS is not set
# CONFIG_MINIX_FS is not set
# CONFIG_ROMFS_FS is not set
CONFIG_INOTIFY=y
CONFIG_INOTIFY_USER=y
# CONFIG_QUOTA is not set
CONFIG_DNOTIFY=y
# CONFIG_AUTOFS_FS is not set
CONFIG_AUTOFS4_FS=m
CONFIG_FUSE_FS=m
CONFIG_GENERIC_ACL=y

#
# CD-ROM/DVD Filesystems
#
CONFIG_ISO9660_FS=m
CONFIG_JOLIET=y
CONFIG_ZISOFS=y
CONFIG_UDF_FS=m
CONFIG_UDF_NLS=y

#
# DOS/FAT/NT Filesystems
#
CONFIG_FAT_FS=m
CONFIG_MSDOS_FS=m
CONFIG_VFAT_FS=m
CONFIG_FAT_DEFAULT_CODEPAGE=866
CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1"
CONFIG_NTFS_FS=m
# CONFIG_NTFS_DEBUG is not set
# CONFIG_NTFS_RW is not set

#
# Pseudo filesystems
#
CONFIG_PROC_FS=y
CONFIG_PROC_KCORE=y
CONFIG_PROC_SYSCTL=y
CONFIG_SYSFS=y
CONFIG_TMPFS=y
CONFIG_TMPFS_POSIX_ACL=y
# CONFIG_HUGETLBFS is not set
# CONFIG_HUGETLB_PAGE is not set
CONFIG_RAMFS=y
CONFIG_CONFIGFS_FS=m

#
# Miscellaneous filesystems
#
# CONFIG_ADFS_FS is not set
# CONFIG_AFFS_FS is not set
# CONFIG_ECRYPT_FS is not set
# CONFIG_HFS_FS is not set
# CONFIG_HFSPLUS_FS is not set
# CONFIG_BEFS_FS is not set
# CONFIG_BFS_FS is not set
# CONFIG_EFS_FS is not set
# CONFIG_CRAMFS is not set
CONFIG_SQUASHFS=m
# CONFIG_SQUASHFS_EMBEDDED is not set
CONFIG_SQUASHFS_FRAGMENT_CACHE_SIZE=3
# CONFIG_SQUASHFS_VMALLOC is not set
# CONFIG_VXFS_FS is not set
# CONFIG_HPFS_FS is not set
# CONFIG_QNX4FS_FS is not set
# CONFIG_SYSV_FS is not set
# CONFIG_UFS_FS is not set

#
# Network File Systems
#
CONFIG_NFS_FS=m
CONFIG_NFS_V3=y
CONFIG_NFS_V3_ACL=y
CONFIG_NFS_V4=y
CONFIG_NFS_DIRECTIO=y
CONFIG_NFSD=m
CONFIG_NFSD_V2_ACL=y
CONFIG_NFSD_V3=y
CONFIG_NFSD_V3_ACL=y
CONFIG_NFSD_V4=y
CONFIG_NFSD_TCP=y
CONFIG_LOCKD=m
CONFIG_LOCKD_V4=y
CONFIG_EXPORTFS=m
CONFIG_NFS_ACL_SUPPORT=m
CONFIG_NFS_COMMON=y
CONFIG_SUNRPC=m
CONFIG_SUNRPC_GSS=m
# CONFIG_SUNRPC_BIND34 is not set
CONFIG_RPCSEC_GSS_KRB5=m
# CONFIG_RPCSEC_GSS_SPKM3 is not set
# CONFIG_SMB_FS is not set
CONFIG_CIFS=m
CONFIG_CIFS_STATS=y
CONFIG_CIFS_STATS2=y
# CONFIG_CIFS_WEAK_PW_HASH is not set
# CONFIG_CIFS_XATTR is not set
# CONFIG_CIFS_DEBUG2 is not set
# CONFIG_CIFS_EXPERIMENTAL is not set
# CONFIG_NCP_FS is not set
CONFIG_CODA_FS=m
# CONFIG_CODA_FS_OLD_API is not set
# CONFIG_AFS_FS is not set
# CONFIG_9P_FS is not set

#
# Partition Types
#
CONFIG_PARTITION_ADVANCED=y
# CONFIG_ACORN_PARTITION is not set
# CONFIG_OSF_PARTITION is not set
# CONFIG_AMIGA_PARTITION is not set
# CONFIG_ATARI_PARTITION is not set
# CONFIG_MAC_PARTITION is not set
CONFIG_MSDOS_PARTITION=y
CONFIG_BSD_DISKLABEL=y
# CONFIG_MINIX_SUBPARTITION is not set
CONFIG_SOLARIS_X86_PARTITION=y
CONFIG_UNIXWARE_DISKLABEL=y
CONFIG_LDM_PARTITION=y
# CONFIG_LDM_DEBUG is not set
# CONFIG_SGI_PARTITION is not set
# CONFIG_ULTRIX_PARTITION is not set
# CONFIG_SUN_PARTITION is not set
# CONFIG_KARMA_PARTITION is not set
# CONFIG_EFI_PARTITION is not set
# CONFIG_SYSV68_PARTITION is not set

#
# Native Language Support
#
CONFIG_NLS=y
CONFIG_NLS_DEFAULT="utf8"
CONFIG_NLS_CODEPAGE_437=m
CONFIG_NLS_CODEPAGE_737=m
CONFIG_NLS_CODEPAGE_775=m
CONFIG_NLS_CODEPAGE_850=m
CONFIG_NLS_CODEPAGE_852=m
CONFIG_NLS_CODEPAGE_855=m
CONFIG_NLS_CODEPAGE_857=m
CONFIG_NLS_CODEPAGE_860=m
CONFIG_NLS_CODEPAGE_861=m
CONFIG_NLS_CODEPAGE_862=m
CONFIG_NLS_CODEPAGE_863=m
CONFIG_NLS_CODEPAGE_864=m
CONFIG_NLS_CODEPAGE_865=m
CONFIG_NLS_CODEPAGE_866=m
CONFIG_NLS_CODEPAGE_869=m
CONFIG_NLS_CODEPAGE_936=m
CONFIG_NLS_CODEPAGE_950=m
CONFIG_NLS_CODEPAGE_932=m
CONFIG_NLS_CODEPAGE_949=m
CONFIG_NLS_CODEPAGE_874=m
CONFIG_NLS_ISO8859_8=m
CONFIG_NLS_CODEPAGE_1250=m
CONFIG_NLS_CODEPAGE_1251=m
CONFIG_NLS_ASCII=m
CONFIG_NLS_ISO8859_1=m
CONFIG_NLS_ISO8859_2=m
CONFIG_NLS_ISO8859_3=m
CONFIG_NLS_ISO8859_4=m
CONFIG_NLS_ISO8859_5=m
CONFIG_NLS_ISO8859_6=m
CONFIG_NLS_ISO8859_7=m
CONFIG_NLS_ISO8859_9=m
CONFIG_NLS_ISO8859_13=m
CONFIG_NLS_ISO8859_14=m
CONFIG_NLS_ISO8859_15=m
CONFIG_NLS_KOI8_R=m
CONFIG_NLS_KOI8_U=m
CONFIG_NLS_UTF8=m

#
# Distributed Lock Manager
#
# CONFIG_DLM is not set

#
# Instrumentation Support
#
CONFIG_PROFILING=y
CONFIG_OPROFILE=m
CONFIG_KPROBES=y

#
# Kernel hacking
#
CONFIG_TRACE_IRQFLAGS_SUPPORT=y
# CONFIG_PRINTK_TIME is not set
CONFIG_ENABLE_MUST_CHECK=y
CONFIG_MAGIC_SYSRQ=y
# CONFIG_UNUSED_SYMBOLS is not set
# CONFIG_DEBUG_FS is not set
# CONFIG_HEADERS_CHECK is not set
CONFIG_DEBUG_KERNEL=y
CONFIG_DEBUG_SHIRQ=y
CONFIG_DETECT_SOFTLOCKUP=y
CONFIG_SCHEDSTATS=y
CONFIG_TIMER_STATS=y
# CONFIG_DEBUG_SLAB is not set
# CONFIG_DEBUG_RT_MUTEXES is not set
# CONFIG_RT_MUTEX_TESTER is not set
CONFIG_DEBUG_SPINLOCK=y
CONFIG_DEBUG_MUTEXES=y
CONFIG_DEBUG_LOCK_ALLOC=y
CONFIG_PROVE_LOCKING=y
CONFIG_LOCKDEP=y
# CONFIG_DEBUG_LOCKDEP is not set
CONFIG_TRACE_IRQFLAGS=y
CONFIG_DEBUG_SPINLOCK_SLEEP=y
CONFIG_DEBUG_LOCKING_API_SELFTESTS=y
CONFIG_STACKTRACE=y
# CONFIG_DEBUG_KOBJECT is not set
CONFIG_DEBUG_BUGVERBOSE=y
# CONFIG_DEBUG_INFO is not set
# CONFIG_DEBUG_VM is not set
# CONFIG_DEBUG_LIST is not set
CONFIG_FRAME_POINTER=y
CONFIG_FORCED_INLINING=y
CONFIG_RCU_TORTURE_TEST=m
CONFIG_LKDTM=m
# CONFIG_FAULT_INJECTION is not set
# CONFIG_EARLY_PRINTK is not set
CONFIG_DEBUG_STACKOVERFLOW=y
# CONFIG_DEBUG_STACK_USAGE is not set

#
# Page alloc debug is incompatible with Software Suspend on i386
#
CONFIG_DEBUG_RODATA=y
# CONFIG_4KSTACKS is not set
CONFIG_X86_FIND_SMP_CONFIG=y
CONFIG_X86_MPPARSE=y
CONFIG_DOUBLEFAULT=y

#
# Security options
#
CONFIG_KEYS=y
CONFIG_KEYS_DEBUG_PROC_KEYS=y
# CONFIG_SECURITY is not set

#
# Cryptographic options
#
CONFIG_CRYPTO=y
CONFIG_CRYPTO_ALGAPI=y
CONFIG_CRYPTO_BLKCIPHER=m
CONFIG_CRYPTO_HASH=y
CONFIG_CRYPTO_MANAGER=y
CONFIG_CRYPTO_HMAC=y
CONFIG_CRYPTO_XCBC=m
CONFIG_CRYPTO_NULL=m
CONFIG_CRYPTO_MD4=m
CONFIG_CRYPTO_MD5=y
CONFIG_CRYPTO_SHA1=m
CONFIG_CRYPTO_SHA256=m
CONFIG_CRYPTO_SHA512=m
CONFIG_CRYPTO_WP512=m
CONFIG_CRYPTO_TGR192=m
CONFIG_CRYPTO_GF128MUL=m
CONFIG_CRYPTO_ECB=m
CONFIG_CRYPTO_CBC=m
CONFIG_CRYPTO_PCBC=m
CONFIG_CRYPTO_LRW=m
# CONFIG_CRYPTO_CRYPTD is not set
CONFIG_CRYPTO_DES=m
CONFIG_CRYPTO_FCRYPT=m
CONFIG_CRYPTO_BLOWFISH=m
CONFIG_CRYPTO_TWOFISH=m
CONFIG_CRYPTO_TWOFISH_COMMON=m
CONFIG_CRYPTO_TWOFISH_586=m
CONFIG_CRYPTO_SERPENT=m
CONFIG_CRYPTO_AES=m
CONFIG_CRYPTO_AES_586=m
CONFIG_CRYPTO_CAST5=m
CONFIG_CRYPTO_CAST6=m
CONFIG_CRYPTO_TEA=m
CONFIG_CRYPTO_ARC4=m
CONFIG_CRYPTO_KHAZAD=m
CONFIG_CRYPTO_ANUBIS=m
CONFIG_CRYPTO_DEFLATE=m
CONFIG_CRYPTO_MICHAEL_MIC=m
CONFIG_CRYPTO_CRC32C=m
CONFIG_CRYPTO_CAMELLIA=m
CONFIG_CRYPTO_TEST=m

#
# Hardware crypto devices
#
# CONFIG_CRYPTO_DEV_PADLOCK is not set
# CONFIG_CRYPTO_DEV_GEODE is not set

#
# Library routines
#
CONFIG_BITREVERSE=y
CONFIG_CRC_CCITT=m
CONFIG_CRC16=m
# CONFIG_CRC_ITU_T is not set
CONFIG_CRC32=y
CONFIG_LIBCRC32C=m
CONFIG_AUDIT_GENERIC=y
CONFIG_ZLIB_INFLATE=m
CONFIG_ZLIB_DEFLATE=m
CONFIG_TEXTSEARCH=y
CONFIG_TEXTSEARCH_KMP=m
CONFIG_TEXTSEARCH_BM=m
CONFIG_TEXTSEARCH_FSM=m
CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_GENERIC_IRQ_PROBE=y
CONFIG_X86_BIOS_REBOOT=y
CONFIG_KTIME_SCALAR=y

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-03  8:00 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip Andrey Borzenkov
@ 2007-06-03  8:16 ` Andrey Borzenkov
  2007-06-03 23:10   ` Samuel Ortiz
  2007-06-04 16:34   ` Bjorn Helgaas
  0 siblings, 2 replies; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-03  8:16 UTC (permalink / raw)
  To: samuel; +Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

[-- Attachment #1: Type: text/plain, Size: 3100 bytes --]

On Sunday 03 June 2007, Andrey Borzenkov wrote:
> Under 2.6.22-rc I lost irda0 interface - smsc claims no device present.
> Nothing was changed in setup except kernel version.
>
> 2.6.21:
>
> Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
> pre-configuring device.
> Activated ALi 1533 ISA bridge port 0x02e8.
> Activated ALi 1533 ISA bridge port 0x02f8.
> found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): LPC47N227
> smsc_superio_flat(): IrDA not enabled
> smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, mode: 0x02
> SMsC IrDA Controller found
>  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
> No transceiver found. Defaulting to Fast pin select
> IrDA: Registered device irda0
>
>
> 2.6.22-rc3:
> Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
> pre-configuring device.
> Activated ALi 1533 ISA bridge port 0x02e8.
> Activated ALi 1533 ISA bridge port 0x02f8.
> pnp: Device 00:0a activated.
> smsc_ircc_present(), addr 0x02e8 - no device found!
> pnp: Device 00:0a disabled.
>
> I Cc Adam because of pnp messages in this case - they were not present in
> 2.6.21 so something is being done differently now.
>
> Some more info:
>
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/id
> SMCf010
> {pts/1}% lspci -nn
> 00:00.0 Host bridge [0600]: ALi Corporation M1644/M1644T
> Northbridge+Trident [10b9:1644] (rev 01)
> 00:01.0 PCI bridge [0604]: ALi Corporation PCI to AGP Controller
> [10b9:5247] 00:02.0 USB Controller [0c03]: ALi Corporation USB 1.1
> Controller [10b9:5237] (rev 03)
> 00:04.0 IDE interface [0101]: ALi Corporation M5229 IDE [10b9:5229] (rev
> c3) 00:06.0 Multimedia audio controller [0401]: ALi Corporation M5451 PCI
> AC-Link Controller Audio Device [10b9:5451] (rev 01)
> 00:07.0 ISA bridge [0601]: ALi Corporation M1533/M1535 PCI to ISA Bridge
> [Aladdin IV/V/V+] [10b9:1533]
> 00:08.0 Bridge [0680]: ALi Corporation M7101 Power Management Controller
> [PMU] [10b9:7101]
> 00:0a.0 Ethernet controller [0200]: Intel Corporation 82557/8/9 [Ethernet
> Pro 100] [8086:1229] (rev 08)
> 00:10.0 CardBus bridge [0607]: Texas Instruments PCI1410 PC card Cardbus
> Controller [104c:ac50] (rev 01)
> 00:11.0 CardBus bridge [0607]: Toshiba America Info Systems ToPIC100 PCI to
> Cardbus Bridge with ZV Support [1179:0617] (rev 32)
> 00:11.1 CardBus bridge [0607]: Toshiba America Info Systems ToPIC100 PCI to
> Cardbus Bridge with ZV Support [1179:0617] (rev 32)
> 00:12.0 System peripheral [0880]: Toshiba America Info Systems SD TypA
> Controller [1179:0805] (rev 03)
> 01:00.0 VGA compatible controller [0300]: Trident Microsystems CyberBlade
> XPAi1 [1023:8820] (rev 82)
>
> config from 2.6.22-rc3 attached.
>

Adding "nopnp" parameters finds device just fine so it is apparently result of 
this commit:

commit d0d4f69bb65a8c1c1430c577a583632709b874c6
Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
Date:   Tue May 8 00:36:05 2007 -0700

    smsc-ircc2: add PNP support

What information is needed to debug it further?

-andrey

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-03  8:16 ` Andrey Borzenkov
@ 2007-06-03 23:10   ` Samuel Ortiz
  2007-06-04  2:33     ` Andrey Borzenkov
  2007-06-04 16:34   ` Bjorn Helgaas
  1 sibling, 1 reply; 48+ messages in thread
From: Samuel Ortiz @ 2007-06-03 23:10 UTC (permalink / raw)
  To: Andrey Borzenkov; +Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

Hi Andrey,

On Sun, Jun 03, 2007 at 12:16:05PM +0400, Andrey Borzenkov wrote:
> 
> Adding "nopnp" parameters finds device just fine so it is apparently result of 
> this commit:
> 
> commit d0d4f69bb65a8c1c1430c577a583632709b874c6
> Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
> Date:   Tue May 8 00:36:05 2007 -0700
> 
>     smsc-ircc2: add PNP support
> 
> What information is needed to debug it further?
It seems that PnP tells us that the FIR port is at 0x2e8 while we're
expecting it at 0x2f8.
Could you apply this patch and then send me a dmesg dump of the
smsc-ircc initialisation ?

Cheers,
Samuel.


diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
index 9043bf4..d1d46a6 100644
--- a/drivers/net/irda/smsc-ircc2.c
+++ b/drivers/net/irda/smsc-ircc2.c
@@ -391,6 +391,9 @@ static int __init smsc_ircc_pnp_probe(struct pnp_dev *dev,
 	dma = pnp_dma(dev, 0);
 	irq = pnp_irq(dev, 0);
 
+	printk("%s(): fir 0x%x sir 0x%x dma %d irq %d\n",
+	       __FUNCTION__, firbase, sirbase, dma, irq);
+
 	if (smsc_ircc_open(firbase, sirbase, dma, irq))
 		return -ENODEV;
 
@@ -655,6 +658,7 @@ static int smsc_ircc_present(unsigned int fir_base, unsigned int sir_base)
 	irq     = (config & IRCC_INTERFACE_IRQ_MASK) >> 4;
 
 	if (high != 0x10 || low != 0xb8 || (chip != 0xf1 && chip != 0xf2)) {
+		printk("High: 0x%x, Chip 0x%x\n", high, chip);
 		IRDA_WARNING("%s(), addr 0x%04x - no device found!\n",
 			     __FUNCTION__, fir_base);
 		goto out3;




^ permalink raw reply related	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-03 23:10   ` Samuel Ortiz
@ 2007-06-04  2:33     ` Andrey Borzenkov
  2007-06-04 20:44       ` Samuel Ortiz
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-04  2:33 UTC (permalink / raw)
  To: Samuel Ortiz; +Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

[-- Attachment #1: Type: text/plain, Size: 2927 bytes --]

On Monday 04 June 2007, Samuel Ortiz wrote:
> Hi Andrey,
>
> On Sun, Jun 03, 2007 at 12:16:05PM +0400, Andrey Borzenkov wrote:
> > Adding "nopnp" parameters finds device just fine so it is apparently
> > result of this commit:
> >
> > commit d0d4f69bb65a8c1c1430c577a583632709b874c6
> > Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
> > Date:   Tue May 8 00:36:05 2007 -0700
> >
> >     smsc-ircc2: add PNP support
> >
> > What information is needed to debug it further?
>
> It seems that PnP tells us that the FIR port is at 0x2e8 while we're
> expecting it at 0x2f8.
> Could you apply this patch and then send me a dmesg dump of the
> smsc-ircc initialisation ?
>

here is dmesg:

Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip, 
pre-configuring device.
Activated ALi 1533 ISA bridge port 0x02e8.
Activated ALi 1533 ISA bridge port 0x02f8.
pnp: Device 00:0a activated.
smsc_ircc_pnp_probe(): fir 0x2e8 sir 0x100 dma 1 irq 5
High: 0xef, Chip 0x1
smsc_ircc_present(), addr 0x02e8 - no device found!
pnp: Device 00:0a disabled.

And here is what PnP tells us:
{pts/1}% cat /sys/bus/pnp/devices/00:0a/options
port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding
irq 3,4,5,6,7,10,11 High-Edge
dma 1,2,3 16-bit compatible
Dependent: 01 - Priority acceptable
   port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
Dependent: 02 - Priority acceptable
   port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
Dependent: 03 - Priority acceptable
   port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
Dependent: 04 - Priority acceptable
   port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding
{pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
state = disabled
{pts/1}% sudo sh -c 'echo activate > /sys/bus/pnp/devices/00:0a/resources'
{pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
state = active
io 0x100-0x107
io 0x2e8-0x2ef
irq 5
dma 1

-andrey

> Cheers,
> Samuel.
>
>
> diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
> index 9043bf4..d1d46a6 100644
> --- a/drivers/net/irda/smsc-ircc2.c
> +++ b/drivers/net/irda/smsc-ircc2.c
> @@ -391,6 +391,9 @@ static int __init smsc_ircc_pnp_probe(struct pnp_dev
> *dev, dma = pnp_dma(dev, 0);
>  	irq = pnp_irq(dev, 0);
>
> +	printk("%s(): fir 0x%x sir 0x%x dma %d irq %d\n",
> +	       __FUNCTION__, firbase, sirbase, dma, irq);
> +
>  	if (smsc_ircc_open(firbase, sirbase, dma, irq))
>  		return -ENODEV;
>
> @@ -655,6 +658,7 @@ static int smsc_ircc_present(unsigned int fir_base,
> unsigned int sir_base) irq     = (config & IRCC_INTERFACE_IRQ_MASK) >> 4;
>
>  	if (high != 0x10 || low != 0xb8 || (chip != 0xf1 && chip != 0xf2)) {
> +		printk("High: 0x%x, Chip 0x%x\n", high, chip);
>  		IRDA_WARNING("%s(), addr 0x%04x - no device found!\n",
>  			     __FUNCTION__, fir_base);
>  		goto out3;



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-03  8:16 ` Andrey Borzenkov
  2007-06-03 23:10   ` Samuel Ortiz
@ 2007-06-04 16:34   ` Bjorn Helgaas
  2007-06-05  3:08     ` Andrey Borzenkov
  1 sibling, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-04 16:34 UTC (permalink / raw)
  To: Andrey Borzenkov; +Cc: samuel, linux-kernel, Michal Piotrowski, ambx1

On Sunday 03 June 2007 02:16:05 am Andrey Borzenkov wrote:
> On Sunday 03 June 2007, Andrey Borzenkov wrote:
> > Under 2.6.22-rc I lost irda0 interface - smsc claims no device present.
> > Nothing was changed in setup except kernel version.
> >
> > 2.6.21:
> >
> > Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
> > pre-configuring device.
> > Activated ALi 1533 ISA bridge port 0x02e8.
> > Activated ALi 1533 ISA bridge port 0x02f8.
> > found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): LPC47N227
> > smsc_superio_flat(): IrDA not enabled

The "IrDA not enabled" makes me think that even in the working case,
the BIOS left the IR port disabled.  Are there any BIOS setup switches
that affect this port?

> > smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, mode: 0x02
> > SMsC IrDA Controller found
> >  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7

It seems strange that both FIR and SIR would use legacy COM ports
(0x2f8 == COM2, 0x2e8 == COM4).  My HP nw8240 has SIR at 0x3e8 (COM3)
and FIR at 0x100.

Do you know if both the FIR and SIR interfaces work?  I'm wondering if
your irda0 only uses SIR at 0x2e8, and FIR has always been broken.

> > No transceiver found. Defaulting to Fast pin select
> > IrDA: Registered device irda0
> >
> >
> > 2.6.22-rc3:
> > Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
> > pre-configuring device.
> > Activated ALi 1533 ISA bridge port 0x02e8.
> > Activated ALi 1533 ISA bridge port 0x02f8.
> > pnp: Device 00:0a activated.
> > smsc_ircc_present(), addr 0x02e8 - no device found!
> > pnp: Device 00:0a disabled.

> {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> state = active
> io 0x100-0x107
> io 0x2e8-0x2ef
> irq 5
> dma 1

The PNP probe I added expects SIR at the first range and FIR at the
second.  I would think the 0x2e8 range would be SIR, since it's compatible
with a COM port.  Is it possible the BIOS just reports these in the
opposite order, with FIR first and SIR second?  Can you try the patch
below?

Index: linux-2.6/drivers/net/irda/smsc-ircc2.c
===================================================================
--- linux-2.6.orig/drivers/net/irda/smsc-ircc2.c	2007-06-04 10:21:46.000000000 -0600
+++ linux-2.6/drivers/net/irda/smsc-ircc2.c	2007-06-04 10:21:57.000000000 -0600
@@ -386,8 +386,8 @@
 	      pnp_dma_valid(dev, 0) && pnp_irq_valid(dev, 0)))
 		return -EINVAL;
 
-	sirbase = pnp_port_start(dev, 0);
-	firbase = pnp_port_start(dev, 1);
+	firbase = pnp_port_start(dev, 0);
+	sirbase = pnp_port_start(dev, 1);
 	dma = pnp_dma(dev, 0);
 	irq = pnp_irq(dev, 0);
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-04  2:33     ` Andrey Borzenkov
@ 2007-06-04 20:44       ` Samuel Ortiz
  2007-06-05  3:10         ` Andrey Borzenkov
  2007-06-05 12:06         ` Linus Walleij (LD/EAB)
  0 siblings, 2 replies; 48+ messages in thread
From: Samuel Ortiz @ 2007-06-04 20:44 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas, Linus Walleij

(Adding Linus Walleij, who wrote part of the smsc driver, to Cc:)

On Mon, Jun 04, 2007 at 06:33:56AM +0400, Andrey Borzenkov wrote:
> On Monday 04 June 2007, Samuel Ortiz wrote:
> > It seems that PnP tells us that the FIR port is at 0x2e8 while we're
> > expecting it at 0x2f8.
> > Could you apply this patch and then send me a dmesg dump of the
> > smsc-ircc initialisation ?
> >
> 
> here is dmesg:
> 
> Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip, 
> pre-configuring device.
> Activated ALi 1533 ISA bridge port 0x02e8.
> Activated ALi 1533 ISA bridge port 0x02f8.
> pnp: Device 00:0a activated.
> smsc_ircc_pnp_probe(): fir 0x2e8 sir 0x100 dma 1 irq 5
Ok, FIR and SIR are definitey mixed up. So, now could you please try Bjorn's
patch ? I wonder if the curent code (without PnP) enables 0x2f8 as the SIR
port through the preconfiguration code...

Cheers,
Samuel.


> High: 0xef, Chip 0x1
> smsc_ircc_present(), addr 0x02e8 - no device found!
> pnp: Device 00:0a disabled.
> 
> And here is what PnP tells us:
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/options
> port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding
> irq 3,4,5,6,7,10,11 High-Edge
> dma 1,2,3 16-bit compatible
> Dependent: 01 - Priority acceptable
>    port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 02 - Priority acceptable
>    port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 03 - Priority acceptable
>    port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 04 - Priority acceptable
>    port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> state = disabled
> {pts/1}% sudo sh -c 'echo activate > /sys/bus/pnp/devices/00:0a/resources'
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> state = active
> io 0x100-0x107
> io 0x2e8-0x2ef
> irq 5
> dma 1
> 
> -andrey
> 
> > Cheers,
> > Samuel.
> >
> >
> > diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
> > index 9043bf4..d1d46a6 100644
> > --- a/drivers/net/irda/smsc-ircc2.c
> > +++ b/drivers/net/irda/smsc-ircc2.c
> > @@ -391,6 +391,9 @@ static int __init smsc_ircc_pnp_probe(struct pnp_dev
> > *dev, dma = pnp_dma(dev, 0);
> >  	irq = pnp_irq(dev, 0);
> >
> > +	printk("%s(): fir 0x%x sir 0x%x dma %d irq %d\n",
> > +	       __FUNCTION__, firbase, sirbase, dma, irq);
> > +
> >  	if (smsc_ircc_open(firbase, sirbase, dma, irq))
> >  		return -ENODEV;
> >
> > @@ -655,6 +658,7 @@ static int smsc_ircc_present(unsigned int fir_base,
> > unsigned int sir_base) irq     = (config & IRCC_INTERFACE_IRQ_MASK) >> 4;
> >
> >  	if (high != 0x10 || low != 0xb8 || (chip != 0xf1 && chip != 0xf2)) {
> > +		printk("High: 0x%x, Chip 0x%x\n", high, chip);
> >  		IRDA_WARNING("%s(), addr 0x%04x - no device found!\n",
> >  			     __FUNCTION__, fir_base);
> >  		goto out3;
> 
> 



^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-04 16:34   ` Bjorn Helgaas
@ 2007-06-05  3:08     ` Andrey Borzenkov
  0 siblings, 0 replies; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-05  3:08 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: samuel, linux-kernel, Michal Piotrowski, ambx1, Linus Walleij

[-- Attachment #1: Type: text/plain, Size: 3619 bytes --]

On Monday 04 June 2007, Bjorn Helgaas wrote:
> On Sunday 03 June 2007 02:16:05 am Andrey Borzenkov wrote:
> > On Sunday 03 June 2007, Andrey Borzenkov wrote:
> > > Under 2.6.22-rc I lost irda0 interface - smsc claims no device present.
> > > Nothing was changed in setup except kernel version.
> > >
> > > 2.6.21:
> > >
> > > Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA
> > > chip, pre-configuring device.
> > > Activated ALi 1533 ISA bridge port 0x02e8.
> > > Activated ALi 1533 ISA bridge port 0x02f8.
> > > found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): LPC47N227
> > > smsc_superio_flat(): IrDA not enabled
>
> The "IrDA not enabled" makes me think that even in the working case,
> the BIOS left the IR port disabled.  Are there any BIOS setup switches
> that affect this port?
>

No (at least in BIOS setup screens). The closest is COM port setting 
(IRQ/DMA). This looks funny as I do not have COM interface anyway but may be 
docking station has.

> > > smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, mode:
> > > 0x02 SMsC IrDA Controller found
> > >  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
>
> It seems strange that both FIR and SIR would use legacy COM ports
> (0x2f8 == COM2, 0x2e8 == COM4).  My HP nw8240 has SIR at 0x3e8 (COM3)
> and FIR at 0x100.
>

Well, this is how code was written. There was no autodetection anyway, it used 
hardcoded builtin (unless overridden).

> Do you know if both the FIR and SIR interfaces work?  I'm wondering if
> your irda0 only uses SIR at 0x2e8, and FIR has always been broken.
>

How can I check it? 

> > > No transceiver found. Defaulting to Fast pin select
> > > IrDA: Registered device irda0
> > >
> > >
> > > 2.6.22-rc3:
> > > Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA
> > > chip, pre-configuring device.
> > > Activated ALi 1533 ISA bridge port 0x02e8.
> > > Activated ALi 1533 ISA bridge port 0x02f8.
> > > pnp: Device 00:0a activated.
> > > smsc_ircc_present(), addr 0x02e8 - no device found!
> > > pnp: Device 00:0a disabled.
> >
> > {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> > state = active
> > io 0x100-0x107
> > io 0x2e8-0x2ef
> > irq 5
> > dma 1
>
> The PNP probe I added expects SIR at the first range and FIR at the
> second.  I would think the 0x2e8 range would be SIR, since it's compatible
> with a COM port.  Is it possible the BIOS just reports these in the
> opposite order, with FIR first and SIR second?  Can you try the patch
> below?
>

It does not work unfortunately:

Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip, 
pre-configuring device.
Activated ALi 1533 ISA bridge port 0x02e8.
Activated ALi 1533 ISA bridge port 0x02f8.
pnp: Device 00:0a activated.
smsc_ircc_pnp_probe(): fir 0x100 sir 0x2e8 dma 1 irq 5
High: 0x11, Chip 0x0
smsc_ircc_present(), addr 0x0100 - no device found!
pnp: Device 00:0a disabled.


> Index: linux-2.6/drivers/net/irda/smsc-ircc2.c
> ===================================================================
> --- linux-2.6.orig/drivers/net/irda/smsc-ircc2.c	2007-06-04
> 10:21:46.000000000 -0600 +++
> linux-2.6/drivers/net/irda/smsc-ircc2.c	2007-06-04 10:21:57.000000000 -0600
> @@ -386,8 +386,8 @@
>  	      pnp_dma_valid(dev, 0) && pnp_irq_valid(dev, 0)))
>  		return -EINVAL;
>
> -	sirbase = pnp_port_start(dev, 0);
> -	firbase = pnp_port_start(dev, 1);
> +	firbase = pnp_port_start(dev, 0);
> +	sirbase = pnp_port_start(dev, 1);
>  	dma = pnp_dma(dev, 0);
>  	irq = pnp_irq(dev, 0);



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-04 20:44       ` Samuel Ortiz
@ 2007-06-05  3:10         ` Andrey Borzenkov
  2007-06-05  7:18           ` Linus Walleij (LD/EAB)
  2007-06-05 12:06         ` Linus Walleij (LD/EAB)
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-05  3:10 UTC (permalink / raw)
  To: Samuel Ortiz
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas, Linus Walleij

[-- Attachment #1: Type: text/plain, Size: 3209 bytes --]

On Tuesday 05 June 2007, Samuel Ortiz wrote:
> (Adding Linus Walleij, who wrote part of the smsc driver, to Cc:)
>
> On Mon, Jun 04, 2007 at 06:33:56AM +0400, Andrey Borzenkov wrote:
> > On Monday 04 June 2007, Samuel Ortiz wrote:
> > > It seems that PnP tells us that the FIR port is at 0x2e8 while we're
> > > expecting it at 0x2f8.
> > > Could you apply this patch and then send me a dmesg dump of the
> > > smsc-ircc initialisation ?
> >
> > here is dmesg:
> >
> > Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
> > pre-configuring device.
> > Activated ALi 1533 ISA bridge port 0x02e8.
> > Activated ALi 1533 ISA bridge port 0x02f8.
> > pnp: Device 00:0a activated.
> > smsc_ircc_pnp_probe(): fir 0x2e8 sir 0x100 dma 1 irq 5
>
> Ok, FIR and SIR are definitey mixed up. So, now could you please try
> Bjorn's patch ?

does not work.

> I wonder if the curent code (without PnP) enables 0x2f8 as 
> the SIR port through the preconfiguration code...
>
> Cheers,
> Samuel.
>
> > High: 0xef, Chip 0x1
> > smsc_ircc_present(), addr 0x02e8 - no device found!
> > pnp: Device 00:0a disabled.
> >
> > And here is what PnP tells us:
> > {pts/1}% cat /sys/bus/pnp/devices/00:0a/options
> > port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding
> > irq 3,4,5,6,7,10,11 High-Edge
> > dma 1,2,3 16-bit compatible
> > Dependent: 01 - Priority acceptable
> >    port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
> > Dependent: 02 - Priority acceptable
> >    port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
> > Dependent: 03 - Priority acceptable
> >    port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
> > Dependent: 04 - Priority acceptable
> >    port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding
> > {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> > state = disabled
> > {pts/1}% sudo sh -c 'echo activate >
> > /sys/bus/pnp/devices/00:0a/resources' {pts/1}% cat
> > /sys/bus/pnp/devices/00:0a/resources
> > state = active
> > io 0x100-0x107
> > io 0x2e8-0x2ef
> > irq 5
> > dma 1
> >
> > -andrey
> >
> > > Cheers,
> > > Samuel.
> > >
> > >
> > > diff --git a/drivers/net/irda/smsc-ircc2.c
> > > b/drivers/net/irda/smsc-ircc2.c index 9043bf4..d1d46a6 100644
> > > --- a/drivers/net/irda/smsc-ircc2.c
> > > +++ b/drivers/net/irda/smsc-ircc2.c
> > > @@ -391,6 +391,9 @@ static int __init smsc_ircc_pnp_probe(struct
> > > pnp_dev *dev, dma = pnp_dma(dev, 0);
> > >  	irq = pnp_irq(dev, 0);
> > >
> > > +	printk("%s(): fir 0x%x sir 0x%x dma %d irq %d\n",
> > > +	       __FUNCTION__, firbase, sirbase, dma, irq);
> > > +
> > >  	if (smsc_ircc_open(firbase, sirbase, dma, irq))
> > >  		return -ENODEV;
> > >
> > > @@ -655,6 +658,7 @@ static int smsc_ircc_present(unsigned int fir_base,
> > > unsigned int sir_base) irq     = (config & IRCC_INTERFACE_IRQ_MASK) >>
> > > 4;
> > >
> > >  	if (high != 0x10 || low != 0xb8 || (chip != 0xf1 && chip != 0xf2)) {
> > > +		printk("High: 0x%x, Chip 0x%x\n", high, chip);
> > >  		IRDA_WARNING("%s(), addr 0x%04x - no device found!\n",
> > >  			     __FUNCTION__, fir_base);
> > >  		goto out3;



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05  3:10         ` Andrey Borzenkov
@ 2007-06-05  7:18           ` Linus Walleij (LD/EAB)
  2007-06-05  7:57             ` Samuel Ortiz
  0 siblings, 1 reply; 48+ messages in thread
From: Linus Walleij (LD/EAB) @ 2007-06-05  7:18 UTC (permalink / raw)
  To: Andrey Borzenkov, Samuel Ortiz
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

> > Ok, FIR and SIR are definitey mixed up. So, now could you  please
try 
> > Bjorn's patch ?
> 
> does not work.

It looks like the purpose of the patch is to provide more printouts
not to fix the problem, please mail your dmesg post-patch.

Linus

^ permalink raw reply	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05  7:18           ` Linus Walleij (LD/EAB)
@ 2007-06-05  7:57             ` Samuel Ortiz
  2007-06-05 11:57               ` Linus Walleij (LD/EAB)
  0 siblings, 1 reply; 48+ messages in thread
From: Samuel Ortiz @ 2007-06-05  7:57 UTC (permalink / raw)
  To: linus.walleij, arvidjaar
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas


Hi Linus,

On 6/5/2007, "Linus Walleij (LD/EAB)" <linus.walleij@ericsson.com>
wrote:

>> > Ok, FIR and SIR are definitey mixed up. So, now could you  please
>try 
>> > Bjorn's patch ?
>> 
>> does not work.
>
>It looks like the purpose of the patch is to provide more printouts
>not to fix the problem, please mail your dmesg post-patch.

Here it is (from an answer from Andrey to Bjorn, you were not included
yet):

Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC IrDA chip,
pre-configuring device.
Activated ALi 1533 ISA bridge port 0x02e8.
Activated ALi 1533 ISA bridge port 0x02f8.
pnp: Device 00:0a activated.
smsc_ircc_pnp_probe(): fir 0x100 sir 0x2e8 dma 1 irq 5
High: 0x11, Chip 0x0
smsc_ircc_present(), addr 0x0100 - no device found!
pnp: Device 00:0a disabled.

Andrey, in addition to Bjorn's patch, could you also apply this one and
try again:

diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
index 31c6233..800562a 100644
--- a/drivers/net/irda/smsc-ircc2.c
+++ b/drivers/net/irda/smsc-ircc2.c
@@ -2463,7 +2463,7 @@ static struct smsc_ircc_subsystem_configuration
subsystem_
                .subvendor = 0x1179,
                .subdevice = 0xffff, /* 0xffff is "any" */
                .sir_io = 0x02e8,
-               .fir_io = 0x02f8,
+               .fir_io = 0x100,
                .fir_irq = 0x07,
                .fir_dma = 0x03,
                .cfg_base = 0x002e,

^ permalink raw reply related	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05  7:57             ` Samuel Ortiz
@ 2007-06-05 11:57               ` Linus Walleij (LD/EAB)
  2007-06-05 13:04                 ` Samuel Ortiz
  2007-06-05 23:23                 ` Bjorn Helgaas
  0 siblings, 2 replies; 48+ messages in thread
From: Linus Walleij (LD/EAB) @ 2007-06-05 11:57 UTC (permalink / raw)
  To: Samuel Ortiz, arvidjaar
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

Sam wrote:

> Andrey, in addition to Bjorn's patch, could you also apply 
> this one and try again:
> 
> diff --git a/drivers/net/irda/smsc-ircc2.c 
> b/drivers/net/irda/smsc-ircc2.c index 31c6233..800562a 100644
> --- a/drivers/net/irda/smsc-ircc2.c
> +++ b/drivers/net/irda/smsc-ircc2.c
> @@ -2463,7 +2463,7 @@ static struct 
> smsc_ircc_subsystem_configuration subsystem_
>                 .subvendor = 0x1179,
>                 .subdevice = 0xffff, /* 0xffff is "any" */
>                 .sir_io = 0x02e8,
> -               .fir_io = 0x02f8,
> +               .fir_io = 0x100,

You don't need to alter the defaults for the Toshiba ALi, the 
preconfigure will respect the settings from the commandline,
e.g. modprobe smsc-ircc2 ircc_fir=0x100,ircc_sir=0x02e8.

BUT this value just won't work: we don't know how to tell the ALi 1533
to use any other ports than 0x130,0x178,0x03f8,0x02f8 or 0x02e8.
The code in preconfigure_ali_port() is from the smscinit tool
and I have no idea of how that was initially developed (reverse
engineering likely). Since 0x0130 and 0x170 seem to be the same setting,
0x100 could be equal to one of the others as well so I would
try feeding some different ircc_fir=x settings and see what happens.

The problem is we don't have any documentation for this
bridge and even though I've requested a datasheet from ALi they
refuse to provide one. I even tried buying one in the grey market
and failed, if someone has it, please forward.

Linus Walleij

^ permalink raw reply	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-04 20:44       ` Samuel Ortiz
  2007-06-05  3:10         ` Andrey Borzenkov
@ 2007-06-05 12:06         ` Linus Walleij (LD/EAB)
  1 sibling, 0 replies; 48+ messages in thread
From: Linus Walleij (LD/EAB) @ 2007-06-05 12:06 UTC (permalink / raw)
  To: Samuel Ortiz, Andrey Borzenkov
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas

Andrey wrote:

> And here is what PnP tells us:
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/options
> port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding irq 
> 3,4,5,6,7,10,11 High-Edge dma 1,2,3 16-bit compatible
> Dependent: 01 - Priority acceptable
>    port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 02 - Priority acceptable
>    port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 03 - Priority acceptable
>    port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
> Dependent: 04 - Priority acceptable
>    port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding 
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> state = disabled
> {pts/1}% sudo sh -c 'echo activate > 
/sys/bus/pnp/devices/00:0a/resources'
> {pts/1}% cat /sys/bus/pnp/devices/00:0a/resources
> state = active
> io 0x100-0x107
> io 0x2e8-0x2ef
> irq 5
> dma 1

These values *could* be correct (not all PnP BIOS:es can be trusted,
apparently). What we need to do really, is to get PnP working
properly with smsc-ircc2 and the pass these PnP settings through
as if they were parameters to the module, in the call to 
smsc_ircc_preconfigure_subsystems() in the smsc_ircc_init() call.
Then it will (probably) preconfigure the bridge for the
correct ports all the time.

The static table I've put in there just happens to be factory
defaults on a few machines, subject to change whenever some HW
is added/removed I believe.

Linus

^ permalink raw reply	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05 11:57               ` Linus Walleij (LD/EAB)
@ 2007-06-05 13:04                 ` Samuel Ortiz
  2007-06-05 23:23                 ` Bjorn Helgaas
  1 sibling, 0 replies; 48+ messages in thread
From: Samuel Ortiz @ 2007-06-05 13:04 UTC (permalink / raw)
  To: linus.walleij, arvidjaar
  Cc: linux-kernel, Michal Piotrowski, ambx1, bjorn.helgaas


On 6/5/2007, "Linus Walleij (LD/EAB)" <linus.walleij@ericsson.com>
wrote:

>Sam wrote:
>
>> Andrey, in addition to Bjorn's patch, could you also apply 
>> this one and try again:
>> 
>> diff --git a/drivers/net/irda/smsc-ircc2.c 
>> b/drivers/net/irda/smsc-ircc2.c index 31c6233..800562a 100644
>> --- a/drivers/net/irda/smsc-ircc2.c
>> +++ b/drivers/net/irda/smsc-ircc2.c
>> @@ -2463,7 +2463,7 @@ static struct 
>> smsc_ircc_subsystem_configuration subsystem_
>>                 .subvendor = 0x1179,
>>                 .subdevice = 0xffff, /* 0xffff is "any" */
>>                 .sir_io = 0x02e8,
>> -               .fir_io = 0x02f8,
>> +               .fir_io = 0x100,
>
>You don't need to alter the defaults for the Toshiba ALi, the 
>preconfigure will respect the settings from the commandline,
>e.g. modprobe smsc-ircc2 ircc_fir=0x100,ircc_sir=0x02e8.
True, that's faster.


>BUT this value just won't work: we don't know how to tell the ALi 1533
>to use any other ports than 0x130,0x178,0x03f8,0x02f8 or 0x02e8.
Oh, that's right. I didn't look carefully enough at
preconfigure_ali_port()...


>The code in preconfigure_ali_port() is from the smscinit tool
>and I have no idea of how that was initially developed (reverse
>engineering likely). Since 0x0130 and 0x170 seem to be the same setting,
>0x100 could be equal to one of the others as well so I would
>try feeding some different ircc_fir=x settings and see what happens.
>From the PnP output that Andrey sent, it seems that 0x130 might work.
If not, I guess it's worth trying at 0x100 while assuming it's the same
register setting as 0x130 or 0x178, so basically applying this patch on
top of Bjorn's one:

diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
index 31c6233..0657228 100644
--- a/drivers/net/irda/smsc-ircc2.c
+++ b/drivers/net/irda/smsc-ircc2.c
@@ -2742,6 +2742,7 @@ static void __init preconfigure_ali_port(struct
pci_dev *d
        unsigned char tmpbyte;

        switch(port) {
+       case 0x0100:
        case 0x0130:
        case 0x0178:
                reg = 0xb0;

and then a modprobe smsc-ircc2 ircc_fir=0x100,ircc_sir=0x02e8

Cheers,
Samuel.

^ permalink raw reply related	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05 11:57               ` Linus Walleij (LD/EAB)
  2007-06-05 13:04                 ` Samuel Ortiz
@ 2007-06-05 23:23                 ` Bjorn Helgaas
  2007-06-06  3:29                   ` Andrey Borzenkov
  2007-06-07 12:23                   ` Linus Walleij (LD/EAB)
  1 sibling, 2 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-05 23:23 UTC (permalink / raw)
  To: Linus Walleij (LD/EAB)
  Cc: Samuel Ortiz, arvidjaar, linux-kernel, Michal Piotrowski, ambx1

On Tuesday 05 June 2007 05:57:30 am Linus Walleij (LD/EAB) wrote:
> You don't need to alter the defaults for the Toshiba ALi, the 
> preconfigure will respect the settings from the commandline,
> e.g. modprobe smsc-ircc2 ircc_fir=0x100,ircc_sir=0x02e8.
> 
> BUT this value just won't work: we don't know how to tell the ALi 1533
> to use any other ports than 0x130,0x178,0x03f8,0x02f8 or 0x02e8.

Something's wrong with this strategy.  The BIOS is telling us that an
SMCf010 device is present, active, and responds at io ports 0x100-0x107
and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
an ISA or LPC bridge should be immaterial to the OS driver.

If an ACPI BIOS says the device is active, I don't think the OS should
have to preconfigure anything to make it work.  I don't know whether
this is just a broken BIOS on this machine, or whether we don't know
how to use it correctly yet.  The fact that we *do* have to preconfigure
so much stuff in smsc-ircc2.c makes me think that Linux is missing
something important in the way we deal with ISA and LPC bridges.

Andrey, can you collect your ACPI DSDT and "lspnp -vv" [1] output?
Maybe there will be a clue there.

[1] ftp://ftp.kernel.org/pub/linux/kernel/people/helgaas/pnputils-0.1.tar.bz2

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05 23:23                 ` Bjorn Helgaas
@ 2007-06-06  3:29                   ` Andrey Borzenkov
  2007-06-06 19:09                     ` Bjorn Helgaas
  2007-06-07 12:23                   ` Linus Walleij (LD/EAB)
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-06  3:29 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1


[-- Attachment #1.1: Type: text/plain, Size: 4927 bytes --]

On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> On Tuesday 05 June 2007 05:57:30 am Linus Walleij (LD/EAB) wrote:
> > You don't need to alter the defaults for the Toshiba ALi, the
> > preconfigure will respect the settings from the commandline,
> > e.g. modprobe smsc-ircc2 ircc_fir=0x100,ircc_sir=0x02e8.
> >
> > BUT this value just won't work: we don't know how to tell the ALi 1533
> > to use any other ports than 0x130,0x178,0x03f8,0x02f8 or 0x02e8.
>
> Something's wrong with this strategy.  The BIOS is telling us that an
> SMCf010 device is present, active, and responds at io ports 0x100-0x107
> and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
> an ISA or LPC bridge should be immaterial to the OS driver.
>

I thought this as well.

> If an ACPI BIOS says the device is active, I don't think the OS should
> have to preconfigure anything to make it work.  I don't know whether
> this is just a broken BIOS on this machine, or whether we don't know
> how to use it correctly yet.  The fact that we *do* have to preconfigure
> so much stuff in smsc-ircc2.c makes me think that Linux is missing
> something important in the way we deal with ISA and LPC bridges.
>
> Andrey, can you collect your ACPI DSDT and "lspnp -vv" [1] output?
> Maybe there will be a clue there.
>

dsdt binary and decoded attached. lspnp:

{pts/1}% lspnp -vv
00:00 PNP0c01 System board
    state = active
    allocated resources:
        mem 0x0-0x9ffff
        mem 0xe0000-0xeffff
        mem 0xf0000-0xfffff
        mem 0x100000-0x1ef5ffff

00:01 PNP0a03 PCI bus
    state = active
    allocated resources:
        io 0xcf8-0xcff

00:02 PNP0200 AT DMA controller
    state = active
    allocated resources:
        io 0x0-0xf
        io 0x81-0x83
        io 0x87-0x87
        io 0x89-0x8b
        io 0x8f-0x8f
        io 0xc0-0xdf
        dma 4

00:03 PNP0800 AT speaker
    state = active
    allocated resources:
        io 0x61-0x61

00:04 PNP0c04 Math coprocessor
    state = active
    allocated resources:
        io 0xf0-0xff
        irq 13

00:05 PNP0303 IBM enhanced keyboard (101/102-key, PS/2 mouse support)
    state = active
    allocated resources:
        io 0x60-0x60
        io 0x64-0x64
        irq 1

00:06 PNP0f13 PS/2 port for PS/2-style mice
    state = active
    allocated resources:
        irq 12

00:07 PNP0b00 AT real-time clock
    state = active
    allocated resources:
        io 0x70-0x71
        irq 8

00:08 PNP0c02 Motherboard resources
    state = active
    allocated resources:
        io 0x2e-0x2f
        io 0x62-0x62
        io 0x66-0x66
        io 0x80-0x80
        io 0x84-0x86
        io 0x88-0x88
        io 0x8c-0x8e
        io 0x92-0x92

00:09 PNP0501 16550A-compatible serial port
    state = active
    allocated resources:
        io 0x3f8-0x3ff
        irq 4
    possible resources:
        irq 3,4,5,6,7,10,11 High-Edge
        Dependent: 01 - Priority acceptable
           port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 02 - Priority acceptable
           port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 03 - Priority acceptable
           port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 04 - Priority acceptable
           port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding

00:0a SMCf010 SMC Fast Infrared Port
    state = disabled
    possible resources:
        port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding
        irq 3,4,5,6,7,10,11 High-Edge
        dma 1,2,3 16-bit compatible
        Dependent: 01 - Priority acceptable
           port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 02 - Priority acceptable
           port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 03 - Priority acceptable
           port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 04 - Priority acceptable
           port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding

00:0b PNP0401 ECP printer port
    state = active
    allocated resources:
        io 0x378-0x37a
        io 0x778-0x77a
        irq 7
        dma 3
    possible resources:
        dma 1,2,3 8-bit compatible
        Dependent: 01 - Priority acceptable
           port 0x378-0x378, align 0x0, size 0x3, 16-bit address decoding
           port 0x778-0x778, align 0x0, size 0x3, 16-bit address decoding
           irq 7 High-Edge
        Dependent: 02 - Priority acceptable
           port 0x278-0x278, align 0x0, size 0x3, 16-bit address decoding
           port 0x678-0x678, align 0x0, size 0x3, 16-bit address decoding
           irq 5 High-Edge
        Dependent: 03 - Priority acceptable
           port 0x3bc-0x3bc, align 0x0, size 0x3, 16-bit address decoding
           port 0x7bc-0x7bc, align 0x0, size 0x3, 16-bit address decoding
           irq 7 High-Edge

{pts/1}%

[-- Attachment #1.2: dsdt --]
[-- Type: application/octet-stream, Size: 26842 bytes --]

[-- Attachment #1.3: dsdt.dsl --]
[-- Type: text/x-dsl, Size: 185785 bytes --]

/*
 * Intel ACPI Component Architecture
 * AML Disassembler version 20051216
 *
 * Disassembly of dsdt, Mon Mar  6 22:51:55 2006
 *
 * Original Table Header:
 *     Signature        "DSDT"
 *     Length           0x000068DA (26842)
 *     Revision         0x01
 *     OEM ID           "TOSHIB"
 *     OEM Table ID     "4000    "
 *     OEM Revision     0x20020417 (537003031)
 *     Creator ID       "MSFT"
 *     Creator Revision 0x0100000A (16777226)
 */
DefinitionBlock ("DSDT.aml", "DSDT", 1, "TOSHIB", "4000    ", 0x20020417)
{
    Name (\_S0, Package (0x04)
    {
        0x00, 
        0x00, 
        0x00, 
        0x00
    })
    Name (\_S3, Package (0x04)
    {
        0x07, 
        0x00, 
        0x00, 
        0x00
    })
    Name (\_S4, Package (0x04)
    {
        0x07, 
        0x00, 
        0x00, 
        0x00
    })
    Name (\_S5, Package (0x04)
    {
        0x07, 
        0x00, 
        0x00, 
        0x00
    })
    Scope (\_PR)
    {
        Processor (CPU0, 0x01, 0x0000EE10, 0x06)
        {
            Name (_PCT, Package (0x02)
            {
                ResourceTemplate ()
                {
                    Register (SystemIO, 
                        0x08,               // Register Bit Width
                        0x00,               // Register Bit Offset
                        0x00000000000000B1, // Register Address
                        )
                }, 

                ResourceTemplate ()
                {
                    Register (SystemIO, 
                        0x10,               // Register Bit Width
                        0x00,               // Register Bit Offset
                        0x000000000000EF40, // Register Address
                        )
                }
            })
            Method (_PSS, 0, NotSerialized)
            {
                If (\_SB.MEM.PSS1)
                {
                    Name (PSSD, Package (0x02)
                    {
                        Package (0x00) {}, 
                        Package (0x00) {}
                    })
                    Name (PSD0, Package (0x06)
                    {
                        0x03E8, 
                        0x55F0, 
                        0xFA, 
                        0xFA, 
                        0x90, 
                        0x00
                    })
                    Name (PSD1, Package (0x06)
                    {
                        0x02BC, 
                        0x2648, 
                        0xFA, 
                        0xFA, 
                        0x91, 
                        0x01
                    })
                    Store (\_SB.MEM.PSS0, Index (PSD0, 0x00))
                    Store (\_SB.MEM.PSS1, Index (PSD1, 0x00))
                    Store (PSD0, Index (PSSD, 0x00))
                    Store (PSD1, Index (PSSD, 0x01))
                    Return (PSSD)
                }
                Else
                {
                    Name (PSSC, Package (0x01)
                    {
                        Package (0x00) {}
                    })
                    Name (PSC0, Package (0x06)
                    {
                        0x03E8, 
                        0x55F0, 
                        0xFA, 
                        0xFA, 
                        0x90, 
                        0x00
                    })
                    Store (\_SB.MEM.PSS0, Index (PSC0, 0x00))
                    Store (PSC0, Index (PSSC, 0x00))
                    Return (PSSC)
                }
            }

            Method (_PPC, 0, NotSerialized)
            {
                SMBR (0xFC00, 0x3D, 0x00, 0x00, 0xB2)
                And (\_SB.MEM.OECX, 0x03, Local0)
                If (LEqual (Local0, 0x00))
                {
                    If (\_SB.MEM.HPSU)
                    {
                        If (\_SB.MEM.ACST)
                        {
                            Return (\_SB.MEM.PULA)
                        }
                        Else
                        {
                            Return (\_SB.MEM.PULD)
                        }
                    }
                    Else
                    {
                        Return (0x00)
                    }
                }
                Else
                {
                    If (LEqual (Local0, 0x01))
                    {
                        Return (0x00)
                    }
                    Else
                    {
                        Return (0x01)
                    }
                }
            }
        }
    }

    Scope (\_SB)
    {
        Device (MEM)
        {
            Name (_HID, EisaId ("PNP0C01"))
            Name (_STA, 0x0F)
            Method (_CRS, 0, NotSerialized)
            {
                Return (CRS (0x01))
            }

            OperationRegion (SRAM, SystemMemory, 0x000EE800, 0x1800)
            Field (SRAM, AnyAcc, NoLock, Preserve)
            {
                PAR1,   16, 
                PAR2,   16, 
                PAR3,   16, 
                PAR4,   16, 
                PAR5,   16, 
                PAR6,   16
            }

            Field (SRAM, AnyAcc, NoLock, Preserve)
            {
                Offset (0x02), 
                RDID,   32, 
                RDSN,   32, 
                CAPB,   16
            }

            Field (SRAM, AnyAcc, NoLock, Preserve)
            {
                IEAX,   32, 
                IEBX,   32, 
                IECX,   32, 
                IEDX,   32, 
                IESI,   32, 
                IEDI,   32, 
                IEBP,   32, 
                Offset (0x20), 
                OEAX,   32, 
                OEBX,   32, 
                OECX,   32, 
                OEDX,   32, 
                OESI,   32, 
                OEDI,   32, 
                OEBP,   32, 
                Offset (0xFF), 
                ACST,   1, 
                BES1,   1, 
                BES2,   1, 
                Offset (0x100), 
                BMN1,   104, 
                BSN1,   88, 
                BTP1,   72, 
                BPU1,   32, 
                BDC1,   32, 
                BLF1,   32, 
                BTC1,   32, 
                BDV1,   32, 
                BST1,   32, 
                BPR1,   32, 
                BRC1,   32, 
                BPV1,   32, 
                Offset (0x149), 
                BCW1,   32, 
                BCL1,   32, 
                BG11,   32, 
                BG21,   32, 
                BOI1,   8, 
                BRF1,   1, 
                Offset (0x200), 
                BMN2,   104, 
                BSN2,   88, 
                BTP2,   72, 
                BPU2,   32, 
                BDC2,   32, 
                BLF2,   32, 
                BTC2,   32, 
                BDV2,   32, 
                BST2,   32, 
                BPR2,   32, 
                BRC2,   32, 
                BPV2,   32, 
                Offset (0x249), 
                BCW2,   32, 
                BCL2,   32, 
                BG12,   32, 
                BG22,   32, 
                BOI2,   32, 
                Offset (0x300), 
                AC01,   16, 
                AC11,   16, 
                PSV1,   16, 
                CRT1,   16, 
                TMP1,   16, 
                AST1,   16, 
                AC21,   16, 
                AC31,   16, 
                AC02,   16, 
                AC12,   16, 
                PSV2,   16, 
                CRT2,   16, 
                TMP2,   16, 
                AST2,   16, 
                AC22,   16, 
                AC32,   16, 
                AC03,   16, 
                AC13,   16, 
                PSV3,   16, 
                CRT3,   16, 
                TMP3,   16, 
                AST3,   16, 
                AC23,   16, 
                AC33,   16, 
                Offset (0x340), 
                TMPF,   16, 
                Offset (0x3F0), 
                FANH,   1, 
                FANL,   7, 
                TF11,   1, 
                TF21,   1, 
                TF31,   1, 
                    ,   1, 
                TF10,   1, 
                TF20,   1, 
                TF30,   1, 
                Offset (0x3F2), 
                TP11,   1, 
                TP21,   1, 
                TP31,   1, 
                Offset (0x400), 
                GP50,   1, 
                GP51,   1, 
                GP52,   1, 
                GP53,   1, 
                GP54,   1, 
                Offset (0x401), 
                GP60,   1, 
                GP61,   1, 
                GP62,   1, 
                GP63,   1, 
                GP64,   1, 
                GP65,   1, 
                GP66,   1, 
                Offset (0x402), 
                GP70,   1, 
                GP71,   1, 
                GP72,   1, 
                GP73,   1, 
                GP74,   1, 
                GP75,   1, 
                GP76,   1, 
                GP77,   1, 
                WED0,   1, 
                WED1,   1, 
                WED2,   1, 
                WED3,   1, 
                WED4,   1, 
                Offset (0x404), 
                SBL0,   1, 
                SBL1,   1, 
                SBL2,   1, 
                SBL3,   1, 
                Offset (0x405), 
                LIDS,   1, 
                VALF,   1, 
                DCST,   1, 
                DOS2,   1, 
                DCKI,   1, 
                DCKF,   1, 
                BT1F,   1, 
                BT2F,   1, 
                NXLA,   1, 
                NXCA,   1, 
                NXTA,   1, 
                NXDA,   1, 
                CTLA,   1, 
                CTCA,   1, 
                CTTA,   1, 
                CTDA,   1, 
                LANA,   1, 
                Offset (0x483), 
                GCVS,   8, 
                Offset (0x4C0), 
                PSS0,   16, 
                PSS1,   16, 
                Offset (0x4D0), 
                SYU0,   1, 
                SYU1,   1, 
                SYU2,   1, 
                SYU3,   1, 
                SYU4,   1, 
                SYU5,   1, 
                SYU6,   1, 
                SYU7,   1, 
                Offset (0x500), 
                HKCD,   8, 
                Offset (0x502), 
                DLID,   32, 
                DSRN,   32, 
                Offset (0x50E), 
                BDID,   32, 
                DSPW,   1, 
                VGAF,   1, 
                VWE0,   1, 
                VWE1,   1, 
                PPSC,   1, 
                SPSC,   1, 
                EWLD,   1, 
                EPWS,   1, 
                LCDS,   4, 
                CRTS,   4, 
                VWE2,   1, 
                WEF0,   1, 
                WEF1,   1, 
                WED5,   1, 
                IEWE,   1, 
                Offset (0x515), 
                BTMD,   1, 
                WSF0,   1, 
                WSF1,   1, 
                GP83,   1, 
                WUIE,   1, 
                    ,   1, 
                BPFE,   1, 
                BWUE,   1, 
                DVIS,   4, 
                Offset (0x517), 
                HTM0,   1, 
                HTM1,   1, 
                Offset (0x518), 
                PSND,   1, 
                PMDM,   1, 
                Offset (0x520), 
                VGAR,   1, 
                KBCR,   1, 
                ID0R,   1, 
                ID1R,   1, 
                ID2R,   1, 
                ID3R,   1, 
                IDAR,   1, 
                ACLR,   1, 
                BTRE,   1, 
                Offset (0x701), 
                HAPS,   2, 
                HHSW,   2, 
                HPSU,   2, 
                HRCU,   2, 
                HGSU,   2, 
                HEBI,   2, 
                HTMD,   2, 
                Offset (0x708), 
                TNVS,   1, 
                OSPC,   1, 
                ACBK,   1, 
                Offset (0x70A), 
                PULD,   8, 
                PULA,   8, 
                BCLD,   8, 
                BCLA,   8, 
                Offset (0x710), 
                OSID,   8, 
                Offset (0x720), 
                MSSI,   16, 
                MSSS,   8, 
                MSSR,   8, 
                MSP0,   8, 
                MSC0,   8, 
                MSP1,   8, 
                MSC1,   8, 
                Offset (0x740), 
                Offset (0x800), 
                PRES,   32768
            }

            Field (SRAM, AnyAcc, NoLock, Preserve)
            {
                Offset (0x406), 
                NXDD,   4, 
                CTDD,   4
            }

            Field (SRAM, AnyAcc, NoLock, Preserve)
            {
                Offset (0x800), 
                Offset (0x808), 
                Offset (0x812), 
                Offset (0x814), 
                Offset (0x818), 
                FSDP,   8, 
                Offset (0x823), 
                Offset (0x826), 
                Offset (0x836), 
                Offset (0x87E), 
                Offset (0x87F), 
                EDCK,   8
            }
        }

        Device (PCI0)
        {
            Name (_HID, EisaId ("PNP0A03"))
            Name (_ADR, 0x00)
            Name (_CRS, ResourceTemplate ()
            {
                WordBusNumber (ResourceProducer, MinFixed, MaxFixed, PosDecode,
                    0x0000,             // Address Space Granularity
                    0x0000,             // Address Range Minimum
                    0x00FF,             // Address Range Maximum
                    0x0000,             // Address Translation Offset
                    0x0100,             // Address Length
                    ,,)
                IO (Decode16,
                    0x0CF8,             // Address Range Minimum
                    0x0CF8,             // Address Range Maximum
                    0x01,               // Address Alignment
                    0x08,               // Address Length
                    )
                WordIO (ResourceProducer, MinFixed, MaxFixed, PosDecode, EntireRange,
                    0x0000,             // Address Space Granularity
                    0x0000,             // Address Range Minimum
                    0x0CF7,             // Address Range Maximum
                    0x0000,             // Address Translation Offset
                    0x0CF8,             // Address Length
                    ,,, TypeStatic)
                WordIO (ResourceProducer, MinFixed, MaxFixed, PosDecode, EntireRange,
                    0x0000,             // Address Space Granularity
                    0x0D00,             // Address Range Minimum
                    0xFFFF,             // Address Range Maximum
                    0x0000,             // Address Translation Offset
                    0xF300,             // Address Length
                    ,,, TypeStatic)
                DWordMemory (ResourceProducer, PosDecode, MinFixed, MaxFixed, NonCacheable, ReadWrite,
                    0x00000000,         // Address Space Granularity
                    0x000A0000,         // Address Range Minimum
                    0x000BFFFF,         // Address Range Maximum
                    0x00000000,         // Address Translation Offset
                    0x00020000,         // Address Length
                    ,,, AddressRangeMemory, TypeStatic)
                DWordMemory (ResourceProducer, PosDecode, MinFixed, MaxFixed, NonCacheable, ReadWrite,
                    0x00000000,         // Address Space Granularity
                    0x000D8000,         // Address Range Minimum
                    0x000DFFFF,         // Address Range Maximum
                    0x00000000,         // Address Translation Offset
                    0x00008000,         // Address Length
                    ,,, AddressRangeMemory, TypeStatic)
                DWordMemory (ResourceProducer, PosDecode, MinFixed, MaxFixed, NonCacheable, ReadWrite,
                    0x00000000,         // Address Space Granularity
                    0x40100000,         // Address Range Minimum
                    0xFEE9FFFF,         // Address Range Maximum
                    0x00000000,         // Address Translation Offset
                    0xBEEA0000,         // Address Length
                    ,,, AddressRangeMemory, TypeStatic)
            })
            Name (_PRT, Package (0x0A)
            {
                Package (0x04)
                {
                    0x0014FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKD, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0011FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKA, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0011FFFF, 
                    0x01, 
                    \_SB.PCI0.FNC0.LNKB, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x000AFFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKD, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0010FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKC, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0010FFFF, 
                    0x01, 
                    \_SB.PCI0.FNC0.LNKD, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x000CFFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKD, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0006FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKH, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0012FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKA, 
                    0x00
                }, 

                Package (0x04)
                {
                    0x0002FFFF, 
                    0x00, 
                    \_SB.PCI0.FNC0.LNKG, 
                    0x00
                }
            })
            Device (FNC0)
            {
                Name (_ADR, 0x00070000)
                OperationRegion (M153, PCI_Config, 0x00, 0xFF)
                Field (M153, ByteAcc, NoLock, Preserve)
                {
                    Offset (0x44), 
                    IRQJ,   4, 
                        ,   3, 
                    RSTC,   1, 
                    Offset (0x48), 
                    IRQA,   4, 
                    IRQB,   4, 
                    IRQC,   4, 
                    IRQD,   4, 
                    IRQE,   4, 
                    IRQF,   4, 
                    IRQI,   4, 
                    IRQH,   4, 
                    Offset (0x52), 
                        ,   13, 
                    CUS1,   1, 
                    Offset (0x74), 
                    IRQG,   4, 
                    Offset (0x75), 
                    IRQK,   4, 
                    Offset (0x77), 
                        ,   3, 
                    CSND,   1, 
                        ,   1, 
                    CMDM,   1
                }

                Device (LNKA)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x01)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQA))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQA))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQA)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQA)
                    }
                }

                Device (LNKB)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x02)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQB))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQB))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQB)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQB)
                    }
                }

                Device (LNKC)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x03)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQC))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQC))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQC)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQC)
                    }
                }

                Device (LNKD)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x04)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQD))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQD))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQD)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQD)
                    }
                }

                Device (LNKG)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x07)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQG))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQG))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQG)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQG)
                    }
                }

                Device (LNKH)
                {
                    Name (_HID, EisaId ("PNP0C0F"))
                    Name (_UID, 0x08)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STAL (\_SB.PCI0.FNC0.IRQH))
                    }

                    Name (_PRS, ResourceTemplate ()
                    {
                        IRQ (Level, ActiveLow, Shared)
                            {3,4,5,6,7,10,11}
                    })
                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRSL (\_SB.PCI0.FNC0.IRQH))
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.PCI0.FNC0.IRQH)
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        Name (IRQT, Package (0x10)
                        {
                            0x00, 
                            0x08, 
                            0x00, 
                            0x02, 
                            0x04, 
                            0x05, 
                            0x07, 
                            0x06, 
                            0x00, 
                            0x01, 
                            0x03, 
                            0x09, 
                            0x0B, 
                            0x00, 
                            0x0D, 
                            0x0F
                        })
                        CreateWordField (Arg0, 0x01, IRQX)
                        FindSetRightBit (IRQX, Local0)
                        Decrement (Local0)
                        Store (DerefOf (Index (IRQT, Local0)), Local1)
                        Store (Local1, \_SB.PCI0.FNC0.IRQH)
                    }
                }

                Device (DMAC)
                {
                    Name (_HID, EisaId ("PNP0200"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0000,             // Address Range Minimum
                            0x0000,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x10,               // Address Length
                            )
                        IO (Decode16,
                            0x0081,             // Address Range Minimum
                            0x0081,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x03,               // Address Length
                            )
                        IO (Decode16,
                            0x0087,             // Address Range Minimum
                            0x0087,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0089,             // Address Range Minimum
                            0x0089,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x03,               // Address Length
                            )
                        IO (Decode16,
                            0x008F,             // Address Range Minimum
                            0x008F,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x00C0,             // Address Range Minimum
                            0x00C0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x20,               // Address Length
                            )
                        DMA (Compatibility, NotBusMaster, Transfer8)
                            {4}
                    })
                }

                Device (PIC)
                {
                    Name (_HID, EisaId ("PNP0000"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0020,             // Address Range Minimum
                            0x0020,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IO (Decode16,
                            0x00A0,             // Address Range Minimum
                            0x00A0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IRQ (Edge, ActiveHigh, Exclusive)
                            {2}
                    })
                }

                Device (PIT)
                {
                    Name (_HID, EisaId ("PNP0100"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0040,             // Address Range Minimum
                            0x0040,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x04,               // Address Length
                            )
                        IRQ (Edge, ActiveHigh, Exclusive)
                            {0}
                    })
                }

                Device (SPKR)
                {
                    Name (_HID, EisaId ("PNP0800"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0061,             // Address Range Minimum
                            0x0061,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                    })
                }

                Device (NDP)
                {
                    Name (_HID, EisaId ("PNP0C04"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x00F0,             // Address Range Minimum
                            0x00F0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x10,               // Address Length
                            )
                        IRQ (Edge, ActiveHigh, Shared)
                            {13}
                    })
                }

                Device (KBC)
                {
                    Name (_HID, EisaId ("PNP0303"))
                    Method (_STA, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.KBCR, 0x00)) {}
                        Return (0x0F)
                    }

                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0060,             // Address Range Minimum
                            0x0060,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0064,             // Address Range Minimum
                            0x0064,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IRQ (Edge, ActiveHigh, Exclusive)
                            {1}
                    })
                }

                Device (PS2M)
                {
                    Name (_HID, EisaId ("PNP0F13"))
                    Method (_STA, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.KBCR, 0x00)) {}
                        Return (0x0F)
                    }

                    Name (_CRS, ResourceTemplate ()
                    {
                        IRQ (Edge, ActiveHigh, Exclusive)
                            {12}
                    })
                }

                Device (RTC)
                {
                    Name (_HID, EisaId ("PNP0B00"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x0070,             // Address Range Minimum
                            0x0070,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IRQ (Edge, ActiveHigh, Exclusive)
                            {8}
                    })
                }

                Device (SYSR)
                {
                    Name (_HID, EisaId ("PNP0C02"))
                    Name (_STA, 0x0F)
                    Name (_CRS, ResourceTemplate ()
                    {
                        IO (Decode16,
                            0x002E,             // Address Range Minimum
                            0x002E,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IO (Decode16,
                            0x0062,             // Address Range Minimum
                            0x0062,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0066,             // Address Range Minimum
                            0x0066,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0080,             // Address Range Minimum
                            0x0080,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0084,             // Address Range Minimum
                            0x0084,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x03,               // Address Length
                            )
                        IO (Decode16,
                            0x0088,             // Address Range Minimum
                            0x0088,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x008C,             // Address Range Minimum
                            0x008C,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x03,               // Address Length
                            )
                        IO (Decode16,
                            0x0092,             // Address Range Minimum
                            0x0092,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x00B0,             // Address Range Minimum
                            0x00B0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x04,               // Address Length
                            )
                        IO (Decode16,
                            0x00E0,             // Address Range Minimum
                            0x00E0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x10,               // Address Length
                            )
                        IO (Decode16,
                            0x0370,             // Address Range Minimum
                            0x0370,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IO (Decode16,
                            0x040B,             // Address Range Minimum
                            0x040B,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x0480,             // Address Range Minimum
                            0x0480,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x10,               // Address Length
                            )
                        IO (Decode16,
                            0x04D0,             // Address Range Minimum
                            0x04D0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x02,               // Address Length
                            )
                        IO (Decode16,
                            0x04D6,             // Address Range Minimum
                            0x04D6,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0x06C0,             // Address Range Minimum
                            0x06C0,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x40,               // Address Length
                            )
                        IO (Decode16,
                            0xE000,             // Address Range Minimum
                            0xE000,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xE080,             // Address Range Minimum
                            0xE080,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xE400,             // Address Range Minimum
                            0xE400,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xE480,             // Address Range Minimum
                            0xE480,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xE800,             // Address Range Minimum
                            0xE800,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xE880,             // Address Range Minimum
                            0xE880,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xEC00,             // Address Range Minimum
                            0xEC00,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xEC80,             // Address Range Minimum
                            0xEC80,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x80,               // Address Length
                            )
                        IO (Decode16,
                            0xEE00,             // Address Range Minimum
                            0xEE00,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x42,               // Address Length
                            )
                        IO (Decode16,
                            0xEE90,             // Address Range Minimum
                            0xEE90,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x10,               // Address Length
                            )
                        IO (Decode16,
                            0xEEAC,             // Address Range Minimum
                            0xEEAC,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x01,               // Address Length
                            )
                        IO (Decode16,
                            0xEF00,             // Address Range Minimum
                            0xEF00,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x40,               // Address Length
                            )
                        IO (Decode16,
                            0xEF40,             // Address Range Minimum
                            0xEF40,             // Address Range Maximum
                            0x01,               // Address Alignment
                            0x20,               // Address Length
                            )
                    })
                    OperationRegion (SRG1, SystemIO, 0xB1, 0x01)
                    Field (SRG1, ByteAcc, NoLock, Preserve)
                    {
                        TRP4,   8
                    }
                }

                Device (COM)
                {
                    Name (_HID, EisaId ("PNP0501"))
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x0E))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x0E))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x0E))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x0E, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x0E)
                    }

                    Method (_PS0, 0, NotSerialized)
                    {
                        PS0 (0x0E)
                    }

                    Method (_PS3, 0, NotSerialized)
                    {
                        PS3 (0x0E)
                    }

                    Method (_PSC, 0, NotSerialized)
                    {
                        Return (PSC (0x0E))
                    }

                    Name (_PRW, Package (0x02)
                    {
                        0x08, 
                        0x03
                    })
                    Method (_PSW, 1, NotSerialized)
                    {
                        Store (Arg0, \_SB.MEM.WED0)
                    }
                }

                Device (FSIR)
                {
                    Name (_HID, EisaId ("SMCF010"))
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x0F))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x0F))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x0F))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x0F, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x0F)
                    }
                }

                Device (PRT)
                {
                    Name (_HID, EisaId ("PNP0401"))
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x10))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x10))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x10))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x10, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x10)
                    }
                }

                Device (PRT1)
                {
                    Name (_HID, EisaId ("PNP0400"))
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x12))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x12))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x12))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x12, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x12)
                    }
                }

                Device (PCC0)
                {
                    Name (_HID, EisaId ("PNP0E00"))
                    Name (_UID, 0x01)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x13))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x13))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x13))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x13, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x13)
                    }

                    Name (_PRW, Package (0x02)
                    {
                        0x09, 
                        0x03
                    })
                    Method (_PSW, 1, NotSerialized)
                    {
                        Store (Arg0, \_SB.MEM.WED2)
                    }

                    Device (PCS0)
                    {
                        Name (_ADR, 0x00)
                        Name (_SUN, 0x00)
                    }

                    Device (PCS1)
                    {
                        Name (_ADR, 0x01)
                        Name (_SUN, 0x01)
                    }
                }

                Device (ATA)
                {
                    Name (_HID, EisaId ("PNP0600"))
                    Name (_UID, 0x03)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x16))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x16))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x16))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x16, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x16)
                    }
                }
            }

            Device (FNC1)
            {
                Name (_ADR, 0x00040000)
                OperationRegion (IDEC, PCI_Config, 0x00, 0xFF)
                Field (IDEC, ByteAcc, NoLock, Preserve)
                {
                    Offset (0x54), 
                    FTHP,   4, 
                    Offset (0x55), 
                    FTHS,   4, 
                    Offset (0x56), 
                    PUDS,   4, 
                    Offset (0x57), 
                    SUDS,   4, 
                    Offset (0x58), 
                    PAST,   3, 
                    Offset (0x59), 
                    PCRC,   4, 
                    PCAC,   3, 
                    Offset (0x5A), 
                    PDRC,   4, 
                    PDAC,   3, 
                    Offset (0x5C), 
                    SAST,   3, 
                    Offset (0x5D), 
                    SCRC,   4, 
                    SCAC,   3, 
                    Offset (0x5E), 
                    SDRC,   4, 
                    SDAC,   3
                }

                Device (IDE0)
                {
                    Name (_ADR, 0x00)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (0x0F)
                    }

                    Method (_PS0, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                        Store (0x00, \_SB.MEM.PPSC)
                    }

                    Method (_PS3, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                        Store (0x01, \_SB.MEM.PPSC)
                    }

                    Method (_PSC, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                        If (\_SB.MEM.PPSC)
                        {
                            Return (0x03)
                        }
                        Else
                        {
                            Return (0x00)
                        }
                    }

                    Method (_STM, 3, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                        Store (0x01, \_SB.MEM.HTM0)
                        CreateDWordField (Arg0, 0x00, PPIO)
                        CreateDWordField (Arg0, 0x04, PDMA)
                        CreateDWordField (Arg0, 0x10, PFLG)
                        Store (PPIO, Local0)
                        Store (0x03, Local1)
                        Store (0x0A, Local2)
                        Store (0x00, Local3)
                        Store (0x08, Local4)
                        Store (0x08, Local5)
                        If (LNot (LGreater (Local0, 0x78)))
                        {
                            Store (0x02, Local1)
                            Store (0x01, Local2)
                            Store (0x03, Local3)
                            Store (0x01, Local4)
                            Store (0x03, Local5)
                        }
                        Else
                        {
                            If (LNot (LGreater (Local0, 0xB4)))
                            {
                                Store (0x02, Local1)
                                Store (0x03, Local2)
                                Store (0x03, Local3)
                                Store (0x03, Local4)
                                Store (0x03, Local5)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0xF0)))
                                {
                                    Store (0x02, Local1)
                                    Store (0x01, Local2)
                                    Store (0x00, Local3)
                                    Store (0x04, Local4)
                                    Store (0x04, Local5)
                                }
                                Else
                                {
                                    If (LNot (LGreater (Local0, 0x017F)))
                                    {
                                        Store (0x02, Local1)
                                        Store (0x03, Local2)
                                        Store (0x00, Local3)
                                        Store (0x08, Local4)
                                        Store (0x05, Local5)
                                    }
                                }
                            }
                        }

                        If (LNot (LEqual (Local0, 0xFFFFFFFF)))
                        {
                            Store (Local1, \_SB.PCI0.FNC1.PAST)
                            Store (Local2, \_SB.PCI0.FNC1.PCRC)
                            Store (Local3, \_SB.PCI0.FNC1.PCAC)
                            Store (Local4, \_SB.PCI0.FNC1.PDRC)
                            Store (Local5, \_SB.PCI0.FNC1.PDAC)
                            Store (0x05, \_SB.PCI0.FNC1.FTHP)
                        }

                        Store (PDMA, Local0)
                        Store (PFLG, Local1)
                        And (Local1, 0x01, Local1)
                        ShiftLeft (Local1, 0x03, Local1)
                        If (Local1)
                        {
                            Store (0x04, Local2)
                            If (LNot (LGreater (Local0, 0x1E)))
                            {
                                Store (0x00, Local2)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0x2D)))
                                {
                                    Store (0x01, Local2)
                                }
                                Else
                                {
                                    If (LNot (LGreater (Local0, 0x3C)))
                                    {
                                        Store (0x02, Local2)
                                    }
                                    Else
                                    {
                                        If (LNot (LGreater (Local0, 0x5A)))
                                        {
                                            Store (0x03, Local2)
                                        }
                                    }
                                }
                            }
                        }
                        Else
                        {
                            Store (0x07, Local2)
                            If (LNot (LGreater (Local0, 0x4B)))
                            {
                                Store (0x05, Local2)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0x5A)))
                                {
                                    Store (0x06, Local2)
                                }
                            }
                        }

                        If (LNot (LEqual (Local0, 0xFFFFFFFF)))
                        {
                            Or (Local1, Local2, Local1)
                            Store (Local1, \_SB.PCI0.FNC1.PUDS)
                            Store (0x01, \_SB.PCI0.FNC1.FTHP)
                        }
                    }

                    Method (_GTM, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                        Store (0x01, \_SB.MEM.HTM0)
                        Store (\_SB.PCI0.FNC1.PCRC, Local0)
                        Store (\_SB.PCI0.FNC1.PCAC, Local1)
                        ShiftLeft (Local1, 0x04, Local1)
                        Or (Local0, Local1, Local0)
                        Store (0x0258, Local2)
                        If (LEqual (Local0, 0x31))
                        {
                            Store (0x78, Local2)
                        }
                        Else
                        {
                            If (LEqual (Local0, 0x33))
                            {
                                Store (0xB4, Local2)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x01))
                                {
                                    Store (0xF0, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x03))
                                    {
                                        Store (0x017F, Local2)
                                    }
                                }
                            }
                        }

                        Store (\_SB.PCI0.FNC1.PUDS, Local0)
                        And (Local0, 0x08, Local1)
                        And (Local0, 0x07, Local0)
                        Store (0x02, Local4)
                        If (Local1)
                        {
                            Store (0x03, Local4)
                            Store (0x78, Local3)
                            If (LEqual (Local0, 0x00))
                            {
                                Store (0x1E, Local3)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x01))
                                {
                                    Store (0x2D, Local3)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x02))
                                    {
                                        Store (0x3C, Local3)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x03))
                                        {
                                            Store (0x5A, Local3)
                                        }
                                    }
                                }
                            }
                        }
                        Else
                        {
                            Store (0x69, Local3)
                            If (LEqual (Local0, 0x05))
                            {
                                Store (0x4B, Local3)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x06))
                                {
                                    Store (0x5A, Local3)
                                }
                            }
                        }

                        Name (BUFF, Buffer (0x14) {})
                        CreateDWordField (BUFF, 0x00, PIO1)
                        CreateDWordField (BUFF, 0x04, DMA1)
                        CreateDWordField (BUFF, 0x08, PIO2)
                        CreateDWordField (BUFF, 0x0C, DMA2)
                        CreateDWordField (BUFF, 0x10, FLGS)
                        Store (Local2, PIO1)
                        Store (Local3, DMA1)
                        Store (0xFFFFFFFF, PIO2)
                        Store (0xFFFFFFFF, DMA2)
                        Store (Local4, FLGS)
                        Return (BUFF)
                    }

                    Device (HD_0)
                    {
                        Name (_ADR, 0x00)
                        Method (_GTF, 0, NotSerialized)
                        {
                            While (LEqual (\_SB.MEM.ID0R, 0x00)) {}
                            Store (0x01, \_SB.MEM.HTM0)
                            Name (BUFF, Buffer (0x0E)
                            {
                                0x03, 0x0C, 0x00, 0x00, 0x00, 0x00, 0xEF, 0x03, 
                                0x23, 0x00, 0x00, 0x00, 0x00, 0xEF
                            })
                            CreateByteField (BUFF, 0x01, PIOM)
                            CreateByteField (BUFF, 0x08, DMAM)
                            Store (\_SB.PCI0.FNC1.PCRC, Local0)
                            Store (\_SB.PCI0.FNC1.PCAC, Local1)
                            ShiftLeft (Local1, 0x04, Local1)
                            Or (Local0, Local1, Local0)
                            Store (0x08, Local1)
                            If (LEqual (Local0, 0x31))
                            {
                                Store (0x0C, Local1)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x33))
                                {
                                    Store (0x0B, Local1)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x01))
                                    {
                                        Store (0x0A, Local1)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x03))
                                        {
                                            Store (0x09, Local1)
                                        }
                                    }
                                }
                            }

                            Store (\_SB.PCI0.FNC1.PUDS, Local0)
                            And (Local0, 0x08, Local2)
                            And (Local0, 0x07, Local0)
                            If (Local2)
                            {
                                Store (0x40, Local2)
                                If (LEqual (Local0, 0x00))
                                {
                                    Store (0x44, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x01))
                                    {
                                        Store (0x43, Local2)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x02))
                                        {
                                            Store (0x42, Local2)
                                        }
                                        Else
                                        {
                                            If (LEqual (Local0, 0x03))
                                            {
                                                Store (0x41, Local2)
                                            }
                                        }
                                    }
                                }
                            }
                            Else
                            {
                                Store (0x20, Local2)
                                If (LEqual (Local0, 0x05))
                                {
                                    Store (0x22, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x06))
                                    {
                                        Store (0x21, Local2)
                                    }
                                }
                            }

                            Store (Local1, PIOM)
                            Store (Local2, DMAM)
                            Return (BUFF)
                        }
                    }
                }

                Device (IDE1)
                {
                    Name (_ADR, 0x01)
                    Method (_PS0, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                        SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                        And (\_SB.MEM.OECX, 0x02, Local0)
                        If (Local0)
                        {
                            Store (0x00, \_SB.MEM.SPSC)
                            Store (0x01, \_SB.MEM.IESI)
                            Store (0x02, \_SB.MEM.IEDI)
                            SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                            If (\_SB.MEM.OEDX)
                            {
                                Store (0x01, \_SB.MEM.IESI)
                                Store (0x02, \_SB.MEM.IEDI)
                                SMBR (0xFF00, 0x23, 0x20, 0x00, 0xB2)
                                Store (0x01, \_SB.MEM.OECX)
                                While (\_SB.MEM.OECX)
                                {
                                    Store (0x01, \_SB.MEM.IESI)
                                    Store (0x02, \_SB.MEM.IEDI)
                                    SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                                }
                            }
                        }
                    }

                    Method (_PS3, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                        SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                        And (\_SB.MEM.OECX, 0x02, Local0)
                        If (Local0)
                        {
                            Store (0x01, \_SB.MEM.SPSC)
                            Store (0x01, \_SB.MEM.IESI)
                            Store (0x02, \_SB.MEM.IEDI)
                            SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                            If (LNot (LEqual (\_SB.MEM.OEDX, 0x03)))
                            {
                                Store (0x01, \_SB.MEM.IESI)
                                Store (0x02, \_SB.MEM.IEDI)
                                SMBR (0xFF00, 0x23, 0x20, 0x03, 0xB2)
                                Store (0x01, \_SB.MEM.OECX)
                                While (\_SB.MEM.OECX)
                                {
                                    Store (0x01, \_SB.MEM.IESI)
                                    Store (0x02, \_SB.MEM.IEDI)
                                    SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                                }
                            }
                        }
                    }

                    Method (_PSC, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                        SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                        And (\_SB.MEM.OECX, 0x02, Local0)
                        If (Local0)
                        {
                            If (\_SB.MEM.SPSC)
                            {
                                Return (0x03)
                            }
                            Else
                            {
                                Return (0x00)
                            }
                        }
                        Else
                        {
                            Return (0x00)
                        }
                    }

                    Method (_STM, 3, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                        Store (0x01, \_SB.MEM.HTM1)
                        CreateDWordField (Arg0, 0x00, PPIO)
                        CreateDWordField (Arg0, 0x04, PDMA)
                        CreateDWordField (Arg0, 0x10, PFLG)
                        Store (PPIO, Local0)
                        Store (0x03, Local1)
                        Store (0x0A, Local2)
                        Store (0x00, Local3)
                        Store (0x08, Local4)
                        Store (0x08, Local5)
                        If (LNot (LGreater (Local0, 0x78)))
                        {
                            Store (0x02, Local1)
                            Store (0x01, Local2)
                            Store (0x03, Local3)
                            Store (0x01, Local4)
                            Store (0x03, Local5)
                        }
                        Else
                        {
                            If (LNot (LGreater (Local0, 0xB4)))
                            {
                                Store (0x02, Local1)
                                Store (0x03, Local2)
                                Store (0x03, Local3)
                                Store (0x03, Local4)
                                Store (0x03, Local5)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0xF0)))
                                {
                                    Store (0x02, Local1)
                                    Store (0x01, Local2)
                                    Store (0x00, Local3)
                                    Store (0x04, Local4)
                                    Store (0x04, Local5)
                                }
                                Else
                                {
                                    If (LNot (LGreater (Local0, 0x017F)))
                                    {
                                        Store (0x02, Local1)
                                        Store (0x03, Local2)
                                        Store (0x00, Local3)
                                        Store (0x08, Local4)
                                        Store (0x05, Local5)
                                    }
                                }
                            }
                        }

                        If (LNot (LEqual (Local0, 0xFFFFFFFF)))
                        {
                            Store (Local1, \_SB.PCI0.FNC1.SAST)
                            Store (Local2, \_SB.PCI0.FNC1.SCRC)
                            Store (Local3, \_SB.PCI0.FNC1.SCAC)
                            Store (Local4, \_SB.PCI0.FNC1.SDRC)
                            Store (Local5, \_SB.PCI0.FNC1.SDAC)
                            Store (0x05, \_SB.PCI0.FNC1.FTHS)
                        }

                        Store (PDMA, Local0)
                        Store (PFLG, Local1)
                        And (Local1, 0x01, Local1)
                        ShiftLeft (Local1, 0x03, Local1)
                        If (Local1)
                        {
                            Store (0x04, Local2)
                            If (LNot (LGreater (Local0, 0x1E)))
                            {
                                Store (0x00, Local2)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0x2D)))
                                {
                                    Store (0x01, Local2)
                                }
                                Else
                                {
                                    If (LNot (LGreater (Local0, 0x3C)))
                                    {
                                        Store (0x02, Local2)
                                    }
                                    Else
                                    {
                                        If (LNot (LGreater (Local0, 0x5A)))
                                        {
                                            Store (0x03, Local2)
                                        }
                                    }
                                }
                            }
                        }
                        Else
                        {
                            Store (0x07, Local2)
                            If (LNot (LGreater (Local0, 0x4B)))
                            {
                                Store (0x05, Local2)
                            }
                            Else
                            {
                                If (LNot (LGreater (Local0, 0x5A)))
                                {
                                    Store (0x06, Local2)
                                }
                            }
                        }

                        If (LNot (LEqual (Local0, 0xFFFFFFFF)))
                        {
                            Or (Local1, Local2, Local1)
                            Store (Local1, \_SB.PCI0.FNC1.SUDS)
                            Store (0x01, \_SB.PCI0.FNC1.FTHS)
                        }
                    }

                    Method (_GTM, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                        Store (0x01, \_SB.MEM.HTM1)
                        Store (\_SB.PCI0.FNC1.SCRC, Local0)
                        Store (\_SB.PCI0.FNC1.SCAC, Local1)
                        ShiftLeft (Local1, 0x04, Local1)
                        Or (Local0, Local1, Local0)
                        Store (0x0258, Local2)
                        If (LEqual (Local0, 0x31))
                        {
                            Store (0x78, Local2)
                        }
                        Else
                        {
                            If (LEqual (Local0, 0x33))
                            {
                                Store (0xB4, Local2)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x01))
                                {
                                    Store (0xF0, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x03))
                                    {
                                        Store (0x017F, Local2)
                                    }
                                }
                            }
                        }

                        Store (\_SB.PCI0.FNC1.SUDS, Local0)
                        And (Local0, 0x08, Local1)
                        And (Local0, 0x07, Local0)
                        Store (0x02, Local4)
                        If (Local1)
                        {
                            Store (0x03, Local4)
                            Store (0x78, Local3)
                            If (LEqual (Local0, 0x00))
                            {
                                Store (0x1E, Local3)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x01))
                                {
                                    Store (0x2D, Local3)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x02))
                                    {
                                        Store (0x3C, Local3)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x03))
                                        {
                                            Store (0x5A, Local3)
                                        }
                                    }
                                }
                            }
                        }
                        Else
                        {
                            Store (0x69, Local3)
                            If (LEqual (Local0, 0x05))
                            {
                                Store (0x4B, Local3)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x06))
                                {
                                    Store (0x5A, Local3)
                                }
                            }
                        }

                        Name (BUFF, Buffer (0x14) {})
                        CreateDWordField (BUFF, 0x00, PIO1)
                        CreateDWordField (BUFF, 0x04, DMA1)
                        CreateDWordField (BUFF, 0x08, PIO2)
                        CreateDWordField (BUFF, 0x0C, DMA2)
                        CreateDWordField (BUFF, 0x10, FLGS)
                        Store (Local2, PIO1)
                        Store (Local3, DMA1)
                        Store (0xFFFFFFFF, PIO2)
                        Store (0xFFFFFFFF, DMA2)
                        Store (Local4, FLGS)
                        Return (BUFF)
                    }

                    Device (HD_1)
                    {
                        Name (_ADR, 0x00)
                        Method (_STA, 0, NotSerialized)
                        {
                            While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                            SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                            And (\_SB.MEM.OECX, 0x02, Local0)
                            If (Local0)
                            {
                                Return (0x0F)
                            }
                            Else
                            {
                                Return (0x00)
                            }
                        }

                        Method (_EJ0, 1, NotSerialized)
                        {
                            SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                            And (\_SB.MEM.OECX, 0x02, Local0)
                            If (Local0)
                            {
                                Store (0x01, \_SB.MEM.IESI)
                                Store (0x02, \_SB.MEM.IEDI)
                                SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                                If (LNot (LEqual (\_SB.MEM.OEDX, 0x03)))
                                {
                                    Store (0x01, \_SB.MEM.IESI)
                                    Store (0x02, \_SB.MEM.IEDI)
                                    SMBR (0xFF00, 0x23, 0x20, 0x03, 0xB2)
                                    Store (0x01, \_SB.MEM.OECX)
                                    While (\_SB.MEM.OECX)
                                    {
                                        Store (0x01, \_SB.MEM.IESI)
                                        Store (0x02, \_SB.MEM.IEDI)
                                        SMBR (0xFE00, 0x23, 0x20, 0x00, 0xB2)
                                    }
                                }
                            }
                        }

                        Method (_GTF, 0, NotSerialized)
                        {
                            While (LEqual (\_SB.MEM.ID1R, 0x00)) {}
                            Store (0x01, \_SB.MEM.HTM1)
                            Name (BUFF, Buffer (0x0E)
                            {
                                0x03, 0x0C, 0x00, 0x00, 0x00, 0x00, 0xEF, 0x03, 
                                0x23, 0x00, 0x00, 0x00, 0x00, 0xEF
                            })
                            CreateByteField (BUFF, 0x01, PIOM)
                            CreateByteField (BUFF, 0x08, DMAM)
                            Store (\_SB.PCI0.FNC1.SCRC, Local0)
                            Store (\_SB.PCI0.FNC1.SCAC, Local1)
                            ShiftLeft (Local1, 0x04, Local1)
                            Or (Local0, Local1, Local0)
                            Store (0x08, Local1)
                            If (LEqual (Local0, 0x31))
                            {
                                Store (0x0C, Local1)
                            }
                            Else
                            {
                                If (LEqual (Local0, 0x33))
                                {
                                    Store (0x0B, Local1)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x01))
                                    {
                                        Store (0x0A, Local1)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x03))
                                        {
                                            Store (0x09, Local1)
                                        }
                                    }
                                }
                            }

                            Store (\_SB.PCI0.FNC1.SUDS, Local0)
                            And (Local0, 0x08, Local2)
                            And (Local0, 0x07, Local0)
                            If (Local2)
                            {
                                Store (0x40, Local2)
                                If (LEqual (Local0, 0x00))
                                {
                                    Store (0x44, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x01))
                                    {
                                        Store (0x43, Local2)
                                    }
                                    Else
                                    {
                                        If (LEqual (Local0, 0x02))
                                        {
                                            Store (0x42, Local2)
                                        }
                                        Else
                                        {
                                            If (LEqual (Local0, 0x03))
                                            {
                                                Store (0x41, Local2)
                                            }
                                        }
                                    }
                                }
                            }
                            Else
                            {
                                Store (0x20, Local2)
                                If (LEqual (Local0, 0x05))
                                {
                                    Store (0x22, Local2)
                                }
                                Else
                                {
                                    If (LEqual (Local0, 0x06))
                                    {
                                        Store (0x21, Local2)
                                    }
                                }
                            }

                            Store (Local1, PIOM)
                            Store (Local2, DMAM)
                            Return (BUFF)
                        }
                    }
                }
            }

            Device (USB1)
            {
                Name (_ADR, 0x00020000)
                OperationRegion (USP1, PCI_Config, 0x00, 0xFF)
                Field (USP1, ByteAcc, NoLock, Preserve)
                {
                    UVI1,   16, 
                    UDI1,   16, 
                    Offset (0x09), 
                    UPI1,   8, 
                    USC1,   8, 
                    UBC1,   8
                }

                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x03
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.WED3)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.WED3)
                    }
                }

                Device (RHB0)
                {
                    Name (_ADR, 0x00)
                    Device (PT01)
                    {
                        Name (_ADR, 0x01)
                        Name (_EJD, "\\_SB_.PCI0.DOCK")
                    }

                    Device (PT02)
                    {
                        Name (_ADR, 0x02)
                        Name (_EJD, "\\_SB_.PCI0.DOCK")
                    }
                }
            }

            Device (ASND)
            {
                Name (_ADR, 0x00060000)
                Method (_PS0, 0, NotSerialized)
                {
                    While (LEqual (\_SB.MEM.ACLR, 0x00)) {}
                    Store (0x00, \_SB.MEM.PSND)
                }

                Method (_PS3, 0, NotSerialized)
                {
                    Store (0x01, \_SB.MEM.PSND)
                }

                Method (_PSC, 0, NotSerialized)
                {
                    If (\_SB.MEM.PSND)
                    {
                        Return (0x03)
                    }
                    Else
                    {
                        Return (0x00)
                    }
                }

                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x03
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.WED1)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.WED1)
                    }
                }
            }

            Device (IEEE)
            {
                Name (_ADR, 0x000C0000)
                OperationRegion (IEEC, PCI_Config, 0x00, 0xFF)
                Field (IEEC, ByteAcc, NoLock, Preserve)
                {
                    IVI0,   16, 
                    IDI0,   16, 
                    Offset (0x09), 
                    IPI0,   8, 
                    ISC0,   8, 
                    IBC0,   8
                }

                Name (_EJD, "\\_SB_.PCI0.DOCK")
            }

            Device (VIY0)
            {
                Name (_ADR, 0x00110000)
                Name (_SUN, 0x00)
                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x03
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.VWE0)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.VWE0)
                    }
                }
            }

            Device (VIY1)
            {
                Name (_ADR, 0x00110001)
                Name (_SUN, 0x01)
                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x03
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.VWE1)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.VWE1)
                    }
                }
            }

            Device (LAN)
            {
                Name (_ADR, 0x000A0000)
                OperationRegion (PLAN, PCI_Config, 0x00, 0xFF)
                Field (PLAN, ByteAcc, NoLock, Preserve)
                {
                    PLVI,   16, 
                    Offset (0xE1), 
                    PMES,   8
                }

                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x04
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.WED4)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.WED4)
                    }
                }
            }

            Device (MPC0)
            {
                Name (_ADR, 0x00100000)
                OperationRegion (MPF0, PCI_Config, 0x00, 0xFF)
                Field (MPF0, ByteAcc, NoLock, Preserve)
                {
                    Offset (0x0A), 
                    MCC0,   16
                }

                Method (_PRW, 0, NotSerialized)
                {
                    Name (BUFF, Package (0x02)
                    {
                        0x09, 
                        0x04
                    })
                    If (LEqual (\_SB.PCI0.MPC0.MCC0, 0x0200)) {}
                    Else
                    {
                        Store (0x03, Index (BUFF, 0x01))
                    }

                    Return (BUFF)
                }

                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.WEF0)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.WEF0)
                    }
                }
            }

            Device (MPC1)
            {
                Name (_ADR, 0x00100001)
                OperationRegion (MPF1, PCI_Config, 0x00, 0xFF)
                Field (MPF1, ByteAcc, NoLock, Preserve)
                {
                    Offset (0x0A), 
                    MCC1,   16
                }

                Method (_PRW, 0, NotSerialized)
                {
                    Name (BUFF, Package (0x02)
                    {
                        0x09, 
                        0x04
                    })
                    If (LEqual (\_SB.PCI0.MPC1.MCC1, 0x0200)) {}
                    Else
                    {
                        Store (0x03, Index (BUFF, 0x01))
                    }

                    Return (BUFF)
                }

                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.WEF1)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.WEF1)
                    }
                }
            }

            Device (SDC)
            {
                Name (_ADR, 0x00120000)
            }

            Device (DOCK)
            {
                Name (_HID, EisaId ("PNP0A05"))
                Method (_STA, 0, NotSerialized)
                {
                    SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local0)
                    If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                    {
                        Store (0x00, \_SB.MEM.RDID)
                        Store (0x00, \_SB.MEM.RDSN)
                        Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                        Store (\_SB.MEM.RDID, \_SB.MEM.DLID)
                        Store (\_SB.MEM.RDSN, \_SB.MEM.DSRN)
                        If (\_SB.MEM.PAR1)
                        {
                            Return (0x00)
                        }
                        Else
                        {
                            If (LOr (LEqual (0x1B51F351, \_SB.MEM.RDID), LEqual (0x1C51F351, \_SB.MEM.RDID)))
                            {
                                Return (0x0F)
                            }
                            Else
                            {
                                If (LEqual (0x1D51F351, \_SB.MEM.RDID))
                                {
                                    Return (0x0F)
                                }
                                Else
                                {
                                    Return (0x00)
                                }
                            }
                        }
                    }
                    Else
                    {
                        Return (0x00)
                    }
                }

                Method (_BDN, 0, NotSerialized)
                {
                    Store (0x00, \_SB.MEM.RDID)
                    Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                    Return (\_SB.MEM.RDID)
                }

                Method (_UID, 0, NotSerialized)
                {
                    Store (0x00, \_SB.MEM.RDSN)
                    Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                    Return (\_SB.MEM.RDSN)
                }

                Method (_DCK, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                        If (\_SB.MEM.PAR1)
                        {
                            Store (0x41, \_SB.PCI0.FNC0.SYSR.TRP4)
                            Reset (\_SB.PCI0.DKSQ)
                            Wait (\_SB.PCI0.DKSQ, 0x0BB8)
                            Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                            DIS (0x23)
                            Return (One)
                        }

                        Return (Zero)
                    }
                    Else
                    {
                        Return (One)
                    }
                }

                Method (_EJ0, 1, NotSerialized)
                {
                    If (LOr (\_SB.MEM.BES1, \_SB.MEM.BES2))
                    {
                        Store (0x40, \_SB.PCI0.FNC0.SYSR.TRP4)
                        Reset (\_SB.PCI0.DKSQ)
                        Wait (\_SB.PCI0.DKSQ, 0x1388)
                        Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                    }
                }

                Device (ATAE)
                {
                    Name (_HID, EisaId ("PNP0600"))
                    Name (_UID, 0x04)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x24))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x24))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x24))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x24, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x24)
                    }
                }

                Device (PCE0)
                {
                    Name (_HID, EisaId ("PNP0E00"))
                    Name (_UID, 0x02)
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (STA (0x25))
                    }

                    Method (_CRS, 0, NotSerialized)
                    {
                        Return (CRS (0x25))
                    }

                    Method (_PRS, 0, NotSerialized)
                    {
                        Return (PRS (0x25))
                    }

                    Method (_SRS, 1, NotSerialized)
                    {
                        SRS (0x25, Arg0)
                    }

                    Method (_DIS, 0, NotSerialized)
                    {
                        DIS (0x25)
                    }

                    Method (_PS0, 0, NotSerialized)
                    {
                        PS0 (0x25)
                    }

                    Method (_PS3, 0, NotSerialized)
                    {
                        PS3 (0x25)
                    }

                    Method (_PSC, 0, NotSerialized)
                    {
                        Return (PSC (0x25))
                    }

                    Name (_PRW, Package (0x02)
                    {
                        0x09, 
                        0x03
                    })
                    Method (_PSW, 1, NotSerialized)
                    {
                        Store (Arg0, \_SB.MEM.WED2)
                    }

                    Device (PCS2)
                    {
                        Name (_ADR, 0x00)
                        Name (_SUN, 0x02)
                    }
                }

                PowerResource (PDOC, 0x01, 0x0000)
                {
                    Method (_STA, 0, NotSerialized)
                    {
                        Return (\_SB.MEM.DSPW)
                    }

                    Method (_ON, 0, NotSerialized)
                    {
                        Store (0x01, \_SB.MEM.DSPW)
                    }

                    Method (_OFF, 0, NotSerialized)
                    {
                        Store (0x00, \_SB.MEM.DSPW)
                    }
                }

                Name (_PR0, Package (0x01)
                {
                    \_SB.PCI0.DOCK.PDOC
                })
                Name (_PR1, Package (0x01)
                {
                    \_SB.PCI0.DOCK.PDOC
                })
            }

            Event (DKSQ)
            Device (NOV0)
            {
                Name (_ADR, 0x00140000)
                OperationRegion (NVC0, PCI_Config, 0x00, 0xFF)
                Field (NVC0, ByteAcc, NoLock, Preserve)
                {
                    TVI0,   16, 
                    TDI0,   16, 
                    Offset (0x09), 
                    TPI0,   8, 
                    TSC0,   8, 
                    TBC0,   8
                }

                Name (_SUN, 0x02)
                Name (_EJD, "\\_SB_.PCI0.DOCK")
                Name (_PRW, Package (0x02)
                {
                    0x09, 
                    0x03
                })
                Method (_PSW, 1, NotSerialized)
                {
                    If (Arg0)
                    {
                        Store (0x01, \_SB.MEM.VWE2)
                    }
                    Else
                    {
                        Store (0x00, \_SB.MEM.VWE2)
                    }
                }
            }

            Device (PCI1)
            {
                Name (_ADR, 0x00010000)
                Name (_PRT, Package (0x01)
                {
                    Package (0x04)
                    {
                        0xFFFF, 
                        0x00, 
                        \_SB.PCI0.FNC0.LNKC, 
                        0x00
                    }
                })
                Device (VGA)
                {
                    Name (_ADR, 0x00)
                    Method (_PS0, 0, Serialized)
                    {
                        While (LEqual (\_SB.MEM.VGAR, 0x00)) {}
                        Store (0x01, \_SB.MEM.IESI)
                        Store (0x00, \_SB.MEM.IEDI)
                        SMBR (0xFE00, 0x23, 0x0100, 0x00, 0xB2)
                        If (LEqual (\_SB.MEM.OEAX, 0x00))
                        {
                            Store (0x01, \_SB.MEM.IESI)
                            Store (0x00, \_SB.MEM.IEDI)
                            SMBR (0xFF00, 0x23, 0x0100, 0x00, 0xB2)
                            WPSX (0x0100, 0x01, 0x00, 0x00)
                            Store (0x00, \_SB.MEM.VGAF)
                        }
                    }

                    Method (_PS3, 0, Serialized)
                    {
                        While (LEqual (\_SB.MEM.VGAR, 0x00)) {}
                        Store (0x01, \_SB.MEM.IESI)
                        Store (0x00, \_SB.MEM.IEDI)
                        SMBR (0xFE00, 0x23, 0x0100, 0x00, 0xB2)
                        If (LEqual (\_SB.MEM.OEAX, 0x00))
                        {
                            Store (0x01, \_SB.MEM.IESI)
                            Store (0x00, \_SB.MEM.IEDI)
                            SMBR (0xFF00, 0x23, 0x0100, 0x03, 0xB2)
                            WPSX (0x0100, 0x01, 0x00, 0x03)
                            Store (0x01, \_SB.MEM.VGAF)
                        }
                    }

                    Method (_PSC, 0, NotSerialized)
                    {
                        While (LEqual (\_SB.MEM.VGAR, 0x00)) {}
                        Store (0x01, \_SB.MEM.IESI)
                        Store (0x00, \_SB.MEM.IEDI)
                        SMBR (0xFE00, 0x23, 0x0100, 0x00, 0xB2)
                        Return (\_SB.MEM.OEDX)
                    }

                    Method (_DOS, 1, NotSerialized)
                    {
                        If (LEqual (Arg0, 0x00))
                        {
                            Store (0x01, \_SB.MEM.DCST)
                            Store (0x00, \_SB.MEM.DOS2)
                        }
                        Else
                        {
                            If (LEqual (Arg0, 0x01))
                            {
                                Store (0x00, \_SB.MEM.DCST)
                                Store (0x01, \_SB.MEM.DOS2)
                            }
                            Else
                            {
                                If (LEqual (Arg0, 0x02))
                                {
                                    Store (0x01, \_SB.MEM.DCST)
                                    Store (0x01, \_SB.MEM.DOS2)
                                }
                            }
                        }
                    }

                    Method (_DOD, 0, NotSerialized)
                    {
                        Name (BUFF, Package (0x02)
                        {
                            0x0110, 
                            0x0100
                        })
                        Return (BUFF)
                    }

                    Method (_ROM, 2, NotSerialized)
                    {
                        Add (Arg0, 0x000C0000, Local0)
                        ShiftLeft (Arg1, 0x03, Local1)
                        Name (BUFF, Buffer (Arg1) {})
                        Scope (\)
                        {
                            OperationRegion (VROM, SystemMemory, Local0, Local1)
                            Field (VROM, ByteAcc, NoLock, Preserve)
                            {
                                ROMI,   65536
                            }
                        }

                        Store (\ROMI, BUFF)
                        Return (BUFF)
                    }

                    Device (LCD)
                    {
                        Name (_ADR, 0x0110)
                        Method (_DCS, 0, NotSerialized)
                        {
                            If (\_SB.MEM.CTLA)
                            {
                                Return (0x0F)
                            }
                            Else
                            {
                                Return (0x0D)
                            }
                        }

                        Method (_DDC, 1, NotSerialized)
                        {
                            If (LEqual (Arg0, 0x01))
                            {
                                Store (0x80, Local0)
                            }
                            Else
                            {
                                If (LEqual (Arg0, 0x02))
                                {
                                    Store (0x0100, Local0)
                                }
                                Else
                                {
                                    Return (Zero)
                                }
                            }

                            Store (0x00, \_SB.MEM.PRES)
                            ShiftLeft (Arg0, 0x08, Local1)
                            Or (Local1, 0x01, Local1)
                            Name (BUFF, Buffer (Local0) {})
                            SMBR (0xFE00, 0x37, Local1, 0x000EF000, 0xB2)
                            And (Local1, 0xFF00, Local1)
                            Store (0x0100, \_SB.MEM.OECX)
                            While (\_SB.MEM.OECX)
                            {
                                SMBR (0xFE00, 0x37, Local1, 0x00, 0xB2)
                            }

                            Store (\_SB.MEM.FSDP, Local0)
                            Or (Local0, 0x22, \_SB.MEM.FSDP)
                            Subtract (\_SB.MEM.FSDP, Local0, Local0)
                            Subtract (\_SB.MEM.EDCK, Local0, \_SB.MEM.EDCK)
                            Store (\_SB.MEM.PRES, BUFF)
                            Return (BUFF)
                        }

                        Method (_DGS, 0, NotSerialized)
                        {
                            If (\_SB.MEM.NXLA)
                            {
                                Return (One)
                            }
                            Else
                            {
                                Return (Zero)
                            }
                        }

                        Method (_DSS, 1, NotSerialized)
                        {
                            Store (Arg0, Local0)
                            And (Local0, 0x01, Local1)
                            If (Local1)
                            {
                                Store (0x01, \_SB.MEM.NXLA)
                            }
                            Else
                            {
                                Store (0x00, \_SB.MEM.NXLA)
                            }

                            And (Local0, 0x80000000, Local1)
                            If (Local1)
                            {
                                Store (0x0100, Local1)
                                If (\_SB.MEM.NXLA)
                                {
                                    Or (0x01, Local1, Local1)
                                }

                                If (\_SB.MEM.NXCA)
                                {
                                    Or (0x02, Local1, Local1)
                                }

                                If (\_SB.MEM.NXTA)
                                {
                                    Or (0x04, Local1, Local1)
                                }

                                If (\_SB.MEM.NXDA)
                                {
                                    Or (0x08, Local1, Local1)
                                }

                                SMBR (0xFF00, 0x1C, Local1, 0x00, 0xB2)
                                And (\_SB.MEM.OEAX, 0xFF00, Local1)
                                If (LEqual (Local1, 0x00))
                                {
                                    Store (0x80, Local1)
                                    While (LEqual (Local1, 0x80))
                                    {
                                        SMBR (0xFE00, 0x1C, 0x00, 0x00, 0xB2)
                                        And (\_SB.MEM.OECX, 0x80, Local1)
                                    }

                                    If (\_SB.MEM.CTLA)
                                    {
                                        If (LEqual (\_SB.MEM.LCDS, 0x00))
                                        {
                                            SMBR (0xFF00, 0x02, 0x01, 0x00, 0xB2)
                                            Store (0x01, \_SB.MEM.OEDX)
                                            While (\_SB.MEM.OEDX)
                                            {
                                                SMBR (0xFE00, 0x02, 0x00, 0x00, 0xB2)
                                            }
                                        }
                                    }
                                }
                            }
                        }

                        Method (_BCL, 0, NotSerialized)
                        {
                            Name (BUFF, Package (0x05)
                            {
                                0x64, 
                                0x28, 
                                0x00, 
                                0x28, 
                                0x64
                            })
                            If (\_SB.MEM.HPSU)
                            {
                                Store (\_SB.MEM.BCLA, Index (BUFF, 0x00))
                                Store (\_SB.MEM.BCLD, Index (BUFF, 0x01))
                            }

                            Return (BUFF)
                        }

                        Method (_BCM, 1, NotSerialized)
                        {
                            If (LEqual (\_SB.MEM.HPSU, 0x00))
                            {
                                Multiply (Arg0, 0xFFFF, Local0)
                                Divide (Local0, 0x64, , Local0)
                                SMBR (0xFF00, 0x2A, Local0, 0x00, 0xB2)
                            }
                        }

                        Method (_PS0, 0, Serialized)
                        {
                            Store (0x00, \_SB.MEM.LCDS)
                        }

                        Method (_PS3, 0, Serialized)
                        {
                            Store (0x03, \_SB.MEM.LCDS)
                        }

                        Method (_PSC, 0, Serialized)
                        {
                            Return (\_SB.MEM.LCDS)
                        }
                    }

                    Device (CRT)
                    {
                        Name (_ADR, 0x0100)
                        Method (_DCS, 0, NotSerialized)
                        {
                            If (\_SB.MEM.CTCA)
                            {
                                Return (0x0F)
                            }
                            Else
                            {
                                Return (0x0D)
                            }
                        }

                        Method (_DDC, 1, NotSerialized)
                        {
                            If (LEqual (Arg0, 0x01))
                            {
                                Store (0x80, Local0)
                            }
                            Else
                            {
                                If (LEqual (Arg0, 0x02))
                                {
                                    Store (0x0100, Local0)
                                }
                                Else
                                {
                                    Return (Zero)
                                }
                            }

                            Store (0x00, \_SB.MEM.PRES)
                            ShiftLeft (Arg0, 0x08, Local1)
                            Or (Local1, 0x02, Local1)
                            Name (BUFF, Buffer (Local0) {})
                            SMBR (0xFE00, 0x37, Local1, 0x000EF000, 0xB2)
                            And (Local1, 0xFF00, Local1)
                            Store (0x0100, \_SB.MEM.OECX)
                            While (\_SB.MEM.OECX)
                            {
                                SMBR (0xFE00, 0x37, Local1, 0x00, 0xB2)
                            }

                            Store (\_SB.MEM.PRES, BUFF)
                            Return (BUFF)
                        }

                        Method (_DGS, 0, NotSerialized)
                        {
                            If (\_SB.MEM.NXCA)
                            {
                                Return (One)
                            }
                            Else
                            {
                                Return (Zero)
                            }
                        }

                        Method (_DSS, 1, NotSerialized)
                        {
                            Store (Arg0, Local0)
                            And (Local0, 0x01, Local1)
                            If (Local1)
                            {
                                Store (0x01, \_SB.MEM.NXCA)
                            }
                            Else
                            {
                                Store (0x00, \_SB.MEM.NXCA)
                            }

                            And (Local0, 0x80000000, Local1)
                            If (Local1)
                            {
                                Store (0x0100, Local1)
                                If (\_SB.MEM.NXLA)
                                {
                                    Or (0x01, Local1, Local1)
                                }

                                If (\_SB.MEM.NXCA)
                                {
                                    Or (0x02, Local1, Local1)
                                }

                                If (\_SB.MEM.NXTA)
                                {
                                    Or (0x04, Local1, Local1)
                                }

                                SMBR (0xFF00, 0x1C, Local1, 0x00, 0xB2)
                                And (\_SB.MEM.OEAX, 0xFF00, Local1)
                                If (LEqual (Local1, 0x00))
                                {
                                    Store (0x80, Local1)
                                    While (LEqual (Local1, 0x80))
                                    {
                                        SMBR (0xFE00, 0x1C, 0x00, 0x00, 0xB2)
                                        And (\_SB.MEM.OECX, 0x80, Local1)
                                    }

                                    If (\_SB.MEM.CTLA)
                                    {
                                        If (LEqual (\_SB.MEM.LCDS, 0x00))
                                        {
                                            SMBR (0xFF00, 0x02, 0x01, 0x00, 0xB2)
                                            Store (0x01, \_SB.MEM.OEDX)
                                            While (\_SB.MEM.OEDX)
                                            {
                                                SMBR (0xFE00, 0x02, 0x00, 0x00, 0xB2)
                                            }
                                        }
                                    }
                                }
                            }
                        }

                        Method (_PS0, 0, Serialized)
                        {
                            Store (0x00, \_SB.MEM.CRTS)
                        }

                        Method (_PS3, 0, Serialized)
                        {
                            Store (0x03, \_SB.MEM.CRTS)
                        }

                        Method (_PSC, 0, Serialized)
                        {
                            Return (\_SB.MEM.CRTS)
                        }
                    }
                }
            }

            Method (_INI, 0, NotSerialized)
            {
                Store (\_SB.MEM.BES1, \_SB.MEM.BT1F)
                Store (\_SB.MEM.BES2, \_SB.MEM.BT2F)
                Store (0x00, \_SB.MEM.DSPW)
                Store (0x00, \_SB.MEM.VGAF)
                Store (0x00, \_SB.MEM.VWE0)
                Store (0x00, \_SB.MEM.VWE1)
                Store (0x00, \_SB.MEM.PPSC)
                Store (0x00, \_SB.MEM.SPSC)
                Store (0x00, Local0)
                If (CMPS (\_OS, "Microsoft Windows NT"))
                {
                    Store (0x03, Local0)
                    If (CondRefOf (\_OSI, Local1))
                    {
                        If (\_OSI ("Windows 2001"))
                        {
                            Store (0x04, Local0)
                        }
                    }
                }
                Else
                {
                    If (CMPS (\_OS, "Microsoft Windows"))
                    {
                        Store (0x01, Local0)
                    }

                    If (CMPS (\_OS, "Microsoft WindowsME:Millennium Edition"))
                    {
                        Store (0x02, Local0)
                    }
                }

                Store (Local0, \_SB.MEM.OSID)
                DIS (0x14)
                DIS (0x23)
                SMBR (0xFF00, 0x1E, 0x01, 0x00, 0xB2)
                Store (0x01, \_SB.MEM.PAR1)
                Store (0x60, \_SB.PCI0.FNC0.SYSR.TRP4)
            }
        }

        Device (BT)
        {
            Name (_HID, "TOS6205")
            Method (_STA, 0, NotSerialized)
            {
                If (\_SB.MEM.BTMD)
                {
                    Return (0x0F)
                }
                Else
                {
                    Return (0x00)
                }
            }

            Name (_PRW, Package (0x02)
            {
                0x09, 
                0x04
            })
            Method (BTST, 0, NotSerialized)
            {
                Store (0x00, \_SB.MEM.OESI)
                SMBR (0xFE00, 0x4D, 0x01, 0xC600, 0xB2)
                Store (0x01, Local0)
                While (Local0)
                {
                    SMBR (0xFE00, 0x4D, 0x0101, 0xC600, 0xB2)
                    Store (\_SB.MEM.OESI, Local2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local1)
                    If (Local1)
                    {
                        And (\_SB.MEM.OEAX, 0xFF, Local1)
                        If (LNot (LEqual (Local1, 0x20)))
                        {
                            Store (0x00, Local2)
                            Store (0x00, Local0)
                        }
                    }
                    Else
                    {
                        Store (0x00, Local0)
                    }
                }

                And (Local2, 0x02, Local0)
                ShiftLeft (Local0, 0x06, Local0)
                And (Local2, 0x04, Local1)
                ShiftLeft (Local1, 0x04, Local1)
                Or (Local0, Local1, Local0)
                And (Local2, 0x10, Local3)
                ShiftRight (Local3, 0x04, Local3)
                Or (Local0, Local3, Local0)
                Return (Local0)
            }

            Method (AUSB, 0, NotSerialized)
            {
                If (\_SB.MEM.BTMD)
                {
                    Store (0x00, \_SB.MEM.IEDI)
                    Store (0x03, \_SB.MEM.IESI)
                    SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                    Store (0x01, Local0)
                    While (Local0)
                    {
                        SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local1)
                        If (Local1)
                        {
                            And (\_SB.MEM.OEAX, 0xFF, Local1)
                            If (LNot (LEqual (Local1, 0x20)))
                            {
                                Store (0x00, Local0)
                            }
                        }
                        Else
                        {
                            Store (0x00, Local0)
                        }
                    }
                }
            }

            Method (DUSB, 0, NotSerialized)
            {
                If (\_SB.MEM.BTMD)
                {
                    Store (0x00, \_SB.MEM.IEDI)
                    Store (0x04, \_SB.MEM.IESI)
                    SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                    Store (0x01, Local0)
                    While (Local0)
                    {
                        SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local1)
                        If (Local1)
                        {
                            And (\_SB.MEM.OEAX, 0xFF, Local1)
                            If (LNot (LEqual (Local1, 0x20)))
                            {
                                Store (0x00, Local0)
                            }
                        }
                        Else
                        {
                            Store (0x00, Local0)
                        }
                    }
                }
            }

            Method (BTPO, 0, NotSerialized)
            {
                If (\_SB.MEM.BTMD)
                {
                    Store (0x00, \_SB.MEM.IEDI)
                    Store (0x01, \_SB.MEM.IESI)
                    SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                    Store (0x01, Local0)
                    While (Local0)
                    {
                        SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local1)
                        If (Local1)
                        {
                            And (\_SB.MEM.OEAX, 0xFF, Local1)
                            If (LNot (LEqual (Local1, 0x20)))
                            {
                                Store (0x00, Local0)
                            }
                        }
                        Else
                        {
                            Store (0x00, \_SB.MEM.IEDI)
                            Store (0x14, \_SB.MEM.IESI)
                            SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                            Store (0x01, Local2)
                            While (Local2)
                            {
                                SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                                And (\_SB.MEM.OEAX, 0xFF00, Local3)
                                If (Local3)
                                {
                                    And (\_SB.MEM.OEAX, 0xFF, Local3)
                                    If (LNot (LEqual (Local3, 0x20)))
                                    {
                                        Store (0x00, Local2)
                                    }
                                }
                                Else
                                {
                                    Store (0x00, Local2)
                                }
                            }

                            Store (0x00, Local0)
                        }
                    }
                }
            }

            Method (BTPF, 0, NotSerialized)
            {
                If (\_SB.MEM.BTMD)
                {
                    Store (0x00, \_SB.MEM.IEDI)
                    Store (0x02, \_SB.MEM.IESI)
                    SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                    Store (0x01, Local0)
                    While (Local0)
                    {
                        SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local1)
                        If (Local1)
                        {
                            And (\_SB.MEM.OEAX, 0xFF, Local1)
                            If (LNot (LEqual (Local1, 0x20)))
                            {
                                Store (0x00, Local0)
                            }
                        }
                        Else
                        {
                            Store (0x00, \_SB.MEM.IEDI)
                            Store (0x13, \_SB.MEM.IESI)
                            SMBR (0xFF00, 0x4D, 0x01, 0x7C00, 0xB2)
                            Store (0x01, Local2)
                            While (Local2)
                            {
                                SMBR (0xFF00, 0x4D, 0x0101, 0x7C00, 0xB2)
                                And (\_SB.MEM.OEAX, 0xFF00, Local3)
                                If (Local3)
                                {
                                    And (\_SB.MEM.OEAX, 0xFF, Local3)
                                    If (LNot (LEqual (Local3, 0x20)))
                                    {
                                        Store (0x00, Local2)
                                    }
                                }
                                Else
                                {
                                    Store (0x00, Local2)
                                }
                            }

                            Store (0x00, Local0)
                        }
                    }
                }
            }
        }

        Device (LID)
        {
            Name (_HID, EisaId ("PNP0C0D"))
            Method (_LID, 0, NotSerialized)
            {
                Return (\_SB.MEM.LIDS)
            }

            Name (_PRW, Package (0x02)
            {
                0x25, 
                0x04
            })
            Method (_PSW, 1, NotSerialized)
            {
                If (LEqual (Arg0, 0x00))
                {
                    Store (0x00, \_SB.MEM.EWLD)
                }
                Else
                {
                    Store (0x01, \_SB.MEM.EWLD)
                }
            }
        }

        Device (BAT1)
        {
            Name (_HID, EisaId ("PNP0C0A"))
            Name (_UID, 0x01)
            Name (_PCL, Package (0x01)
            {
                \_SB
            })
            Method (_STA, 0, NotSerialized)
            {
                If (\_SB.MEM.BES1)
                {
                    Return (0x1F)
                }
                Else
                {
                    Return (0x0F)
                }
            }

            Method (_BIF, 0, NotSerialized)
            {
                Name (BUFF, Package (0x0D) {})
                Store (0x00, Index (BUFF, 0x00))
                Store (\_SB.MEM.BDV1, Local2)
                Multiply (\_SB.MEM.BDC1, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x01))
                Multiply (\_SB.MEM.BLF1, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x02))
                Store (\_SB.MEM.BTC1, Index (BUFF, 0x03))
                Store (\_SB.MEM.BDV1, Index (BUFF, 0x04))
                Multiply (\_SB.MEM.BCW1, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x05))
                Multiply (\_SB.MEM.BCL1, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x06))
                Multiply (\_SB.MEM.BG11, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x07))
                Multiply (\_SB.MEM.BG21, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x08))
                Store (\_SB.MEM.BMN1, Index (BUFF, 0x09))
                Store (\_SB.MEM.BSN1, Index (BUFF, 0x0A))
                Store (\_SB.MEM.BTP1, Index (BUFF, 0x0B))
                Store (\_SB.MEM.BOI1, Index (BUFF, 0x0C))
                Return (BUFF)
            }

            Method (_BST, 0, NotSerialized)
            {
                If (\_SB.MEM.BES2)
                {
                    And (\_SB.MEM.BST1, 0x03, Local0)
                    And (\_SB.MEM.BST2, 0x03, Local1)
                    If (LOr (Local0, Local1))
                    {
                        Multiply (\_SB.MEM.BPR1, \_SB.MEM.BDV1, Local0)
                        Divide (Local0, 0x07D0, Local1, Local0)
                    }
                    Else
                    {
                        Store (0x00, Local0)
                    }
                }
                Else
                {
                    If (LAnd (\_SB.MEM.BST1, 0x03))
                    {
                        Multiply (\_SB.MEM.BPR1, \_SB.MEM.BDV1, Local0)
                        Divide (Local0, 0x03E8, Local1, Local0)
                    }
                    Else
                    {
                        Store (0x00, Local0)
                    }
                }

                Name (BUFF, Package (0x04) {})
                Store (\_SB.MEM.BST1, Index (BUFF, 0x00))
                Store (Local0, Index (BUFF, 0x01))
                Multiply (\_SB.MEM.BRC1, \_SB.MEM.BDV1, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x02))
                Store (\_SB.MEM.BPV1, Index (BUFF, 0x03))
                Return (BUFF)
            }

            Method (_BTP, 1, NotSerialized)
            {
                Store (0x01, \_SB.MEM.PAR1)
                Store (Arg0, \_SB.MEM.PAR2)
                Store (0x61, \_SB.PCI0.FNC0.SYSR.TRP4)
            }
        }

        Device (BAT2)
        {
            Name (_HID, EisaId ("PNP0C0A"))
            Name (_UID, 0x02)
            Name (_PCL, Package (0x01)
            {
                \_SB
            })
            Method (_STA, 0, NotSerialized)
            {
                If (\_SB.MEM.BES2)
                {
                    Return (0x1F)
                }
                Else
                {
                    Return (0x0F)
                }
            }

            Method (_BIF, 0, NotSerialized)
            {
                Name (BUFF, Package (0x0D) {})
                Store (0x00, Index (BUFF, 0x00))
                Store (\_SB.MEM.BDV2, Local2)
                Multiply (\_SB.MEM.BDC2, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x01))
                Multiply (\_SB.MEM.BLF2, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x02))
                Store (\_SB.MEM.BTC2, Index (BUFF, 0x03))
                Store (\_SB.MEM.BDV2, Index (BUFF, 0x04))
                Multiply (\_SB.MEM.BCW2, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x05))
                Multiply (\_SB.MEM.BCL2, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x06))
                Multiply (\_SB.MEM.BG12, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x07))
                Multiply (\_SB.MEM.BG22, Local2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x08))
                Store (\_SB.MEM.BMN2, Index (BUFF, 0x09))
                Store (\_SB.MEM.BSN2, Index (BUFF, 0x0A))
                Store (\_SB.MEM.BTP2, Index (BUFF, 0x0B))
                Store (\_SB.MEM.BOI2, Index (BUFF, 0x0C))
                Return (BUFF)
            }

            Method (_BST, 0, NotSerialized)
            {
                If (\_SB.MEM.BES1)
                {
                    And (\_SB.MEM.BST1, 0x03, Local0)
                    And (\_SB.MEM.BST2, 0x03, Local1)
                    If (LOr (Local0, Local1))
                    {
                        Multiply (\_SB.MEM.BPR2, \_SB.MEM.BDV2, Local0)
                        Divide (Local0, 0x07D0, Local1, Local0)
                    }
                    Else
                    {
                        Store (0x00, Local0)
                    }
                }
                Else
                {
                    If (LAnd (\_SB.MEM.BST2, 0x03))
                    {
                        Multiply (\_SB.MEM.BPR2, \_SB.MEM.BDV2, Local0)
                        Divide (Local0, 0x03E8, Local1, Local0)
                    }
                    Else
                    {
                        Store (0x00, Local0)
                    }
                }

                Name (BUFF, Package (0x04) {})
                Store (\_SB.MEM.BST2, Index (BUFF, 0x00))
                Store (Local0, Index (BUFF, 0x01))
                Multiply (\_SB.MEM.BRC2, \_SB.MEM.BDV2, Local0)
                Divide (Local0, 0x03E8, Local1, Local0)
                Store (Local0, Index (BUFF, 0x02))
                Store (\_SB.MEM.BPV2, Index (BUFF, 0x03))
                Return (BUFF)
            }

            Method (_BTP, 1, NotSerialized)
            {
                Store (0x02, \_SB.MEM.PAR1)
                Store (Arg0, \_SB.MEM.PAR2)
                Store (0x61, \_SB.PCI0.FNC0.SYSR.TRP4)
            }
        }

        Device (ADP1)
        {
            Name (_HID, "ACPI0003")
            Name (_PCL, Package (0x03)
            {
                \_SB, 
                \_SB.BAT1, 
                \_SB.BAT2
            })
            Name (_STA, 0x0F)
            Method (_PSR, 0, NotSerialized)
            {
                Return (\_SB.MEM.ACST)
            }
        }

        Device (VALD)
        {
            Name (_HID, EisaId ("TOS6200"))
            Name (_DDN, "VALD")
            Name (_STA, 0x0B)
            Method (ENAB, 0, NotSerialized)
            {
                Store (0x01, \_SB.MEM.VALF)
                SMBR (0xFF00, 0x16, 0x01, 0x00, 0xB2)
            }

            Method (INFO, 0, NotSerialized)
            {
                Store (0x00, \_SB.MEM.OECX)
                SMBR (0xFE00, 0x16, 0x00, 0x00, 0xB2)
                If (LNot (LEqual (\_SB.MEM.OEAX, 0x00)))
                {
                    Store (0x00, \_SB.MEM.OECX)
                }

                Return (\_SB.MEM.OECX)
            }

            Method (GHCI, 6, Serialized)
            {
                CreateDWordField (Arg0, 0x00, REAX)
                CreateWordField (Arg1, 0x00, R_BX)
                And (REAX, 0xFF00, Local0)
                If (LEqual (Local0, 0xFE00))
                {
                    If (LEqual (R_BX, 0xC000))
                    {
                        Return (G000 (Local0, R_BX, Arg2, Arg3, Arg4, Arg5))
                    }

                    If (LEqual (R_BX, 0xC800))
                    {
                        Return (G800 (Local0, R_BX, Arg2, Arg3, Arg4, Arg5))
                    }

                    If (LEqual (R_BX, 0xC801))
                    {
                        Return (G801 (Local0, R_BX, Arg2, Arg3, Arg4, Arg5))
                    }
                }

                If (LEqual (Local0, 0xFF00))
                {
                    If (LEqual (R_BX, 0xC000))
                    {
                        Return (G000 (Local0, R_BX, Arg2, Arg3, Arg4, Arg5))
                    }

                    If (LEqual (R_BX, 0xC801))
                    {
                        Return (G801 (Local0, R_BX, Arg2, Arg3, Arg4, Arg5))
                    }
                }

                Return (GCH0 (Arg0, Arg1, Arg2, Arg3, Arg4, Arg5))
            }

            Method (GCH0, 6, NotSerialized)
            {
                Store (Arg4, \_SB.MEM.IESI)
                Store (Arg5, \_SB.MEM.IEDI)
                SMBR (Arg0, Arg1, Arg2, Arg3, 0xB2)
                Name (BUFF, Package (0x06) {})
                Store (\_SB.MEM.OEAX, Index (BUFF, 0x00))
                Store (\_SB.MEM.OEBX, Index (BUFF, 0x01))
                Store (\_SB.MEM.OECX, Index (BUFF, 0x02))
                Store (\_SB.MEM.OEDX, Index (BUFF, 0x03))
                Store (\_SB.MEM.OESI, Index (BUFF, 0x04))
                Store (\_SB.MEM.OEDI, Index (BUFF, 0x05))
                Return (BUFF)
            }

            Method (G000, 6, NotSerialized)
            {
                Name (BUFF, Package (0x06) {})
                CreateDWordField (Arg2, 0x00, RECX)
                CreateDWordField (Arg3, 0x00, REDX)
                CreateDWordField (Arg4, 0x00, RESI)
                CreateDWordField (Arg5, 0x00, REDI)
                CreateByteField (Arg2, 0x00, R_CL)
                Store (0x00, Index (BUFF, 0x00))
                Store (Arg1, Index (BUFF, 0x01))
                Store (RECX, Index (BUFF, 0x02))
                Store (REDX, Index (BUFF, 0x03))
                Store (RESI, Index (BUFF, 0x04))
                Store (REDI, Index (BUFF, 0x05))
                If (\_SB.MEM.GCVS)
                {
                    If (LEqual (Arg0, 0xFE00))
                    {
                        If (LEqual (R_CL, 0x00))
                        {
                            Store (\_SB.MEM.TNVS, Local0)
                            Store (Local0, Index (BUFF, 0x02))
                        }
                        Else
                        {
                            If (LAnd (LNot (LLess (R_CL, 0x01)), LNot (LGreater (R_CL, 0x04))))
                            {
                                Store (R_CL, Local0)
                                Or (Local0, 0x3000, Local0)
                                SMBR (0xFA00, Local0, 0x00, 0x00, 0xB2)
                                Store (\_SB.MEM.OECX, Index (BUFF, 0x02))
                                Store (\_SB.MEM.OEDX, Index (BUFF, 0x03))
                            }
                            Else
                            {
                                If (LEqual (R_CL, 0x05))
                                {
                                    Store (0x21, Index (BUFF, 0x02))
                                }
                                Else
                                {
                                    Store (0x8300, Index (BUFF, 0x00))
                                }
                            }
                        }
                    }
                    Else
                    {
                        CreateWordField (Arg3, 0x00, R_DX)
                        If (LEqual (R_CL, 0x00))
                        {
                            If (LEqual (R_DX, 0x00))
                            {
                                Store (0x00, \_SB.MEM.TNVS)
                            }
                            Else
                            {
                                Store (0x01, \_SB.MEM.TNVS)
                            }
                        }
                        Else
                        {
                            If (LEqual (R_CL, 0x01))
                            {
                                Store (R_CL, Local0)
                                Or (Local0, 0x3080, Local0)
                                SMBR (0xFA00, Local0, R_DX, 0x00, 0xB2)
                            }
                            Else
                            {
                                If (LEqual (R_CL, 0x02))
                                {
                                    FindSetRightBit (R_DX, Local0)
                                    Store (Local0, \_SB.MEM.NXDD)
                                    If (LLess (\_SB.MEM.OSID, 0x03))
                                    {
                                        Or (Local0, 0x0100, Local0)
                                        SMBR (0xFF00, 0x1C, Local0, 0x00, 0xB2)
                                        And (\_SB.MEM.OEAX, 0xFF00, Local0)
                                        If (LEqual (Local0, 0x00))
                                        {
                                            Store (0x80, Local0)
                                            While (LEqual (Local0, 0x80))
                                            {
                                                SMBR (0xFE00, 0x1C, 0x00, 0x00, 0xB2)
                                                And (\_SB.MEM.OECX, 0x80, Local0)
                                            }

                                            If (\_SB.MEM.CTLA)
                                            {
                                                If (LEqual (\_SB.MEM.LCDS, 0x00))
                                                {
                                                    SMBR (0xFF00, 0x02, 0x01, 0x00, 0xB2)
                                                    Store (0x01, \_SB.MEM.OEDX)
                                                    While (\_SB.MEM.OEDX)
                                                    {
                                                        SMBR (0xFE00, 0x02, 0x00, 0x00, 0xB2)
                                                    }
                                                }
                                            }
                                        }
                                    }
                                    Else
                                    {
                                        Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                                    }
                                }
                                Else
                                {
                                    Store (0x8300, Index (BUFF, 0x00))
                                }
                            }
                        }
                    }
                }
                Else
                {
                    Store (0x8000, Index (BUFF, 0x00))
                }

                Return (BUFF)
            }

            Method (G800, 6, NotSerialized)
            {
                Store (\_SB.MEM.OSPC, Local0)
                Name (BUFF, Package (0x06) {})
                CreateDWordField (Arg3, 0x00, REDX)
                CreateDWordField (Arg4, 0x00, RESI)
                CreateDWordField (Arg5, 0x00, REDI)
                Store (0x00, Index (BUFF, 0x00))
                Store (Arg1, Index (BUFF, 0x01))
                Store (Local0, Index (BUFF, 0x02))
                Store (REDX, Index (BUFF, 0x03))
                Store (RESI, Index (BUFF, 0x04))
                Store (REDI, Index (BUFF, 0x05))
                Return (BUFF)
            }

            Method (G801, 6, NotSerialized)
            {
                CreateDWordField (Arg2, 0x00, RECX)
                CreateDWordField (Arg3, 0x00, REDX)
                CreateDWordField (Arg4, 0x00, RESI)
                CreateDWordField (Arg5, 0x00, REDI)
                Store (0x8300, Local0)
                Store (RECX, Local1)
                If (LEqual (REDX, 0x01))
                {
                    Store (0x00, Local0)
                    If (LEqual (Arg0, 0xFE00))
                    {
                        Store (\_SB.MEM.PULD, Local1)
                        Store (\_SB.MEM.PULA, Local2)
                        ShiftLeft (Local2, 0x08, Local2)
                        Or (Local1, Local2, Local1)
                    }
                    Else
                    {
                        And (Local1, 0xFF, Local2)
                        ShiftRight (Local1, 0x08, Local3)
                        Store (Local2, \_SB.MEM.PULD)
                        Store (Local3, \_SB.MEM.PULA)
                    }
                }

                If (LEqual (REDX, 0x02))
                {
                    Store (0x00, Local0)
                    If (LEqual (Arg0, 0xFE00))
                    {
                        Store (\_SB.MEM.BCLD, Local1)
                        Store (\_SB.MEM.BCLA, Local2)
                        ShiftLeft (Local2, 0x08, Local2)
                        Or (Local1, Local2, Local1)
                    }
                    Else
                    {
                        And (Local1, 0xFF, Local2)
                        ShiftRight (Local1, 0x08, Local3)
                        Store (Local2, \_SB.MEM.BCLD)
                        Store (Local3, \_SB.MEM.BCLA)
                    }
                }

                Name (BUFF, Package (0x06) {})
                Store (Local0, Index (BUFF, 0x00))
                Store (Arg1, Index (BUFF, 0x01))
                Store (Local1, Index (BUFF, 0x02))
                Store (REDX, Index (BUFF, 0x03))
                Store (RESI, Index (BUFF, 0x04))
                Store (REDI, Index (BUFF, 0x05))
                Return (BUFF)
            }
        }

        Device (VALG)
        {
            Name (_HID, EisaId ("TOS6202"))
            Name (_DDN, "VALGeneral")
            Name (_STA, 0x0B)
            Method (VCID, 0, NotSerialized)
            {
                Store (0x00, \_SB.MEM.RDID)
                Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                Return (\_SB.MEM.RDID)
            }

            Method (VUID, 0, NotSerialized)
            {
                Store (0x00, \_SB.MEM.RDSN)
                Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                Return (\_SB.MEM.RDSN)
            }

            Method (VDCK, 1, NotSerialized)
            {
                If (Arg0)
                {
                    Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
                    If (\_SB.MEM.PAR1)
                    {
                        Store (0x41, \_SB.PCI0.FNC0.SYSR.TRP4)
                        Reset (\_SB.PCI0.DKSQ)
                        Wait (\_SB.PCI0.DKSQ, 0x0BB8)
                        Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                        DIS (0x23)
                        Return (One)
                    }

                    Return (Zero)
                }
                Else
                {
                    Return (One)
                }
            }

            Method (VEJ0, 1, NotSerialized)
            {
                If (LOr (\_SB.MEM.BES1, \_SB.MEM.BES2))
                {
                    Store (0x40, \_SB.PCI0.FNC0.SYSR.TRP4)
                    Reset (\_SB.PCI0.DKSQ)
                    Wait (\_SB.PCI0.DKSQ, 0x1388)
                    Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                }
            }

            Method (DLSZ, 0, NotSerialized)
            {
                Return (0x04)
            }

            Method (DLIB, 0, NotSerialized)
            {
                Name (BUFF, Buffer (0x40)
                {
                    0x80, 0x00, 0x07, 0x06, 0xFF, 0xA0, 0x00, 0x00, 
                    0x79, 0x11, 0x17, 0x06, 0x00, 0x00, 0x00, 0x00, 
                    0x80, 0x00, 0x00, 0x00, 0x01, 0x10, 0x00, 0x00, 
                    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
                    0x80, 0x00, 0x00, 0x00, 0x02, 0x10, 0x00, 0x00, 
                    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
                    0x80, 0x00, 0x00, 0x00, 0x02, 0x60, 0x00, 0x00, 
                    0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
                })
                Store (\_SB.PCI0.USB1.UVI1, Local0)
                CreateByteField (BUFF, 0x18, VI1L)
                CreateByteField (BUFF, 0x19, VI1H)
                CreateByteField (BUFF, 0x28, VI2L)
                CreateByteField (BUFF, 0x29, VI2H)
                ShiftRight (Local0, 0x08, Local1)
                And (Local0, 0xFF, Local0)
                Store (Local0, VI1L)
                Store (Local1, VI1H)
                Store (Local0, VI2L)
                Store (Local1, VI2H)
                Store (\_SB.PCI0.USB1.UDI1, Local0)
                CreateByteField (BUFF, 0x1A, DI1L)
                CreateByteField (BUFF, 0x1B, DI1H)
                CreateByteField (BUFF, 0x2A, DI2L)
                CreateByteField (BUFF, 0x2B, DI2H)
                ShiftRight (Local0, 0x08, Local1)
                And (Local0, 0xFF, Local0)
                Store (Local0, DI1L)
                Store (Local1, DI1H)
                Store (Local0, DI2L)
                Store (Local1, DI2H)
                Store (\_SB.PCI0.USB1.UPI1, Local0)
                CreateByteField (BUFF, 0x11, PIC1)
                CreateByteField (BUFF, 0x21, PIC2)
                Store (Local0, PIC1)
                Store (Local0, PIC2)
                Store (\_SB.PCI0.USB1.USC1, Local0)
                CreateByteField (BUFF, 0x12, SCC1)
                CreateByteField (BUFF, 0x22, SCC2)
                Store (Local0, SCC1)
                Store (Local0, SCC2)
                Store (\_SB.PCI0.USB1.UBC1, Local0)
                CreateByteField (BUFF, 0x13, BCC1)
                CreateByteField (BUFF, 0x23, BCC2)
                Store (Local0, BCC1)
                Store (Local0, BCC2)
                If (LAnd (LEqual (\_SB.PCI0.IEEE.IVI0, 0x104C), LEqual (\_SB.PCI0.IEEE.IDI0, 0x8023)))
                {
                    Store (\_SB.PCI0.IEEE.IVI0, Local0)
                    CreateByteField (BUFF, 0x38, VI3L)
                    CreateByteField (BUFF, 0x39, VI3H)
                    ShiftRight (Local0, 0x08, Local1)
                    And (Local0, 0xFF, Local0)
                    Store (Local0, VI3L)
                    Store (Local1, VI3H)
                    Store (\_SB.PCI0.IEEE.IDI0, Local0)
                    CreateByteField (BUFF, 0x3A, DI3L)
                    CreateByteField (BUFF, 0x3B, DI3H)
                    ShiftRight (Local0, 0x08, Local1)
                    And (Local0, 0xFF, Local0)
                    Store (Local0, DI3L)
                    Store (Local1, DI3H)
                    Store (\_SB.PCI0.IEEE.IPI0, Local0)
                    CreateByteField (BUFF, 0x31, PIC3)
                    Store (Local0, PIC3)
                    Store (\_SB.PCI0.IEEE.ISC0, Local0)
                    CreateByteField (BUFF, 0x32, SCC3)
                    Store (Local0, SCC3)
                    Store (\_SB.PCI0.IEEE.IBC0, Local0)
                    CreateByteField (BUFF, 0x33, BCC3)
                    Store (Local0, BCC3)
                }
                Else
                {
                    CreateByteField (BUFF, 0x30, VLD3)
                    Store (0x00, VLD3)
                }

                Return (BUFF)
            }

            Method (VNTF, 1, NotSerialized)
            {
                And (Arg0, 0xFFFF, Local0)
                ShiftRight (Arg0, 0x10, Local1)
                If (LEqual (Local1, 0x01))
                {
                    Notify (\_PR.CPU0, Local0)
                }
            }
        }
    }

    Scope (\_TZ)
    {
        PowerResource (PFAN, 0x00, 0x0000)
        {
            Method (_STA, 0, NotSerialized)
            {
                SMBR (0xFA00, 0x2201, 0x00, 0x00, 0xB2)
                If (\_SB.MEM.OECX)
                {
                    Return (One)
                }
                Else
                {
                    Return (0x00)
                }
            }

            Method (_ON, 0, Serialized)
            {
                SMBR (0xFA00, 0x2200, 0xFF, 0x00, 0xB2)
            }

            Method (_OFF, 0, Serialized)
            {
                SMBR (0xFA00, 0x2200, 0x00, 0x00, 0xB2)
            }
        }

        Device (FAN)
        {
            Name (_HID, EisaId ("PNP0C0B"))
            Name (_PR0, Package (0x01)
            {
                \_TZ.PFAN
            })
        }

        ThermalZone (THRM)
        {
            Method (_TMP, 0, NotSerialized)
            {
                If (LNot (LGreater (\_SB.MEM.TMP1, 0x0B4C)))
                {
                    Store (0x0B4C, \_SB.MEM.AST1)
                    Return (0x0B4C)
                }
                Else
                {
                    Store (\_SB.MEM.TMP1, \_SB.MEM.AST1)
                    Return (\_SB.MEM.TMP1)
                }
            }

            Method (_AC0, 0, NotSerialized)
            {
                Return (\_SB.MEM.AC01)
            }

            Method (_AC1, 0, NotSerialized)
            {
                Return (\_SB.MEM.AC11)
            }

            Name (_AL0, Package (0x01)
            {
                \_TZ.FAN
            })
            Name (_AL1, Package (0x01)
            {
                \_TZ.FAN
            })
            Method (_PSV, 0, NotSerialized)
            {
                Return (\_SB.MEM.PSV1)
            }

            Name (_PSL, Package (0x01)
            {
                \_PR.CPU0
            })
            Method (_CRT, 0, NotSerialized)
            {
                Return (\_SB.MEM.CRT1)
            }

            Name (_TC1, 0x09)
            Name (_TC2, 0x02)
            Name (_TSP, 0x0708)
        }
    }

    Scope (\_GPE)
    {
        Method (_L08, 0, Serialized)
        {
            If (\_SB.MEM.GP72)
            {
                Store (0x00, \_SB.MEM.GP72)
                Notify (\_SB.PCI0.FNC0.COM, 0x02)
            }
        }

        Method (_L09, 0, Serialized)
        {
            If (LNot (LEqual (\_SB.PCI0.LAN.PLVI, 0xFFFF)))
            {
                And (\_SB.PCI0.LAN.PMES, 0x80, Local0)
                If (LEqual (Local0, 0x80))
                {
                    Notify (\_SB.PCI0.LAN, 0x02)
                }
            }

            While (LOr (\_SB.MEM.GP73, LOr (\_SB.MEM.GP74, LOr (\_SB.MEM.GP75, LOr (\_SB.MEM.GP83, LOr (\_SB.MEM.BWUE, LOr (\_SB.MEM.WUIE, LOr (\_SB.MEM.WSF0, \_SB.MEM.WSF1))))))))
            {
                If (\_SB.MEM.GP73)
                {
                    Store (0x00, \_SB.MEM.GP73)
                    Notify (\_SB.PCI0.ASND, 0x02)
                }

                If (\_SB.MEM.GP74)
                {
                    Store (0x00, \_SB.MEM.GP74)
                    Notify (\_SB.PCI0.FNC0.PCC0, 0x02)
                    Notify (\_SB.PCI0.VIY0, 0x02)
                    Notify (\_SB.PCI0.VIY1, 0x02)
                    Notify (\_SB.PCI0.NOV0, 0x02)
                }

                If (\_SB.MEM.GP75)
                {
                    Store (0x00, \_SB.MEM.GP75)
                    Notify (\_SB.PCI0.USB1, 0x02)
                }

                If (\_SB.MEM.GP83)
                {
                    Store (0x00, \_SB.MEM.GP83)
                    Notify (\_SB.PCI0.LAN, 0x02)
                }

                If (\_SB.MEM.BWUE)
                {
                    Store (0x00, \_SB.MEM.BWUE)
                    Notify (\_SB.BT, 0x80)
                }

                If (\_SB.MEM.WUIE)
                {
                    Store (0x00, \_SB.MEM.WUIE)
                    Notify (\_SB.PCI0.IEEE, 0x02)
                }

                If (\_SB.MEM.WSF0)
                {
                    Store (0x00, \_SB.MEM.WSF0)
                    Notify (\_SB.PCI0.MPC0, 0x02)
                }
            }
        }

        Method (_L25, 0, Serialized)
        {
            Store (0xAF, \_SB.MEM.IEDI)
            SMBR (0xFF00, 0x0028B10B, 0x00, 0x00, 0xB2)
            While (LOr (\_SB.MEM.GP50, LOr (\_SB.MEM.GP51, LOr (\_SB.MEM.GP52, LOr (\_SB.MEM.GP53, LOr (\_SB.MEM.GP54, LOr (\_SB.MEM.GP60, LOr (\_SB.MEM.GP61, LOr (\_SB.MEM.GP62, LOr (\_SB.MEM.GP63, LOr (\_SB.MEM.GP64, LOr (\_SB.MEM.GP66, LOr (\_SB.MEM.GP70, LOr (\_SB.MEM.GP71, \_SB.MEM.BPFE))))))))))))))
            {
                If (\_SB.MEM.GP50)
                {
                    Store (0x00, \_SB.MEM.GP50)
                    Notify (\_SB.ADP1, 0x80)
                }

                If (\_SB.MEM.GP51)
                {
                    Store (0x00, \_SB.MEM.GP51)
                    If (LEqual (\_SB.MEM.BES2, \_SB.MEM.BT2F))
                    {
                        Notify (\_SB.BAT2, 0x80)
                    }
                    Else
                    {
                        Store (\_SB.MEM.BES2, \_SB.MEM.BT2F)
                        If (\_SB.MEM.BES2)
                        {
                            Notify (\_SB.BAT2, 0x00)
                        }
                        Else
                        {
                            Notify (\_SB.BAT2, 0x01)
                        }
                    }
                }

                If (\_SB.MEM.GP52)
                {
                    Store (0x00, \_SB.MEM.GP52)
                    If (LEqual (\_SB.MEM.BES1, \_SB.MEM.BT1F))
                    {
                        Notify (\_SB.BAT1, 0x80)
                    }
                    Else
                    {
                        Store (\_SB.MEM.BES1, \_SB.MEM.BT1F)
                        If (\_SB.MEM.BES1)
                        {
                            Notify (\_SB.BAT1, 0x00)
                        }
                        Else
                        {
                            Notify (\_SB.BAT1, 0x01)
                        }
                    }
                }

                If (\_SB.MEM.GP53)
                {
                    Store (0x00, \_SB.MEM.GP53)
                    If (LNot (LEqual (\_SB.MEM.TMP1, \_SB.MEM.AST1)))
                    {
                        Notify (\_TZ.THRM, 0x80)
                    }
                }

                If (\_SB.MEM.GP54)
                {
                    Store (0x00, \_SB.MEM.GP54)
                    If (\_SB.MEM.LANA)
                    {
                        Store (0x00, \_SB.MEM.LANA)
                        Notify (\_SB.PCI0.LAN, 0x01)
                    }
                }

                If (\_SB.MEM.GP60)
                {
                    Store (0x00, \_SB.MEM.GP60)
                    SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local0)
                    If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                    {
                        Notify (\_SB.PCI0.DOCK, 0x00)
                    }
                    Else
                    {
                        Notify (\_SB.VALG, 0x83)
                    }
                }

                If (\_SB.MEM.GP61)
                {
                    Signal (\_SB.PCI0.DKSQ)
                    Store (0x00, \_SB.MEM.GP61)
                    SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local0)
                    If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                    {
                        Notify (\_SB.PCI0.DOCK, 0x00)
                    }
                    Else
                    {
                        Notify (\_SB.VALG, 0x83)
                    }
                }

                If (\_SB.MEM.GP62)
                {
                    Store (0x00, \_SB.MEM.GP62)
                    SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local0)
                    If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                    {
                        Notify (\_SB.PCI0.DOCK, 0x01)
                    }
                    Else
                    {
                        Notify (\_SB.VALG, 0x82)
                    }
                }

                If (\_SB.MEM.GP63)
                {
                    Store (0x00, \_SB.MEM.GP63)
                    If (LEqual (\_SB.MEM.DCKF, 0x00))
                    {
                        Store (0x01, \_SB.MEM.DCKF)
                        SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local0)
                        If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                        {
                            Notify (\_SB.PCI0.DOCK, 0x00)
                        }
                        Else
                        {
                            Notify (\_SB.VALG, 0x81)
                        }
                    }
                    Else
                    {
                        Signal (\_SB.PCI0.DKSQ)
                        Store (0x00, \_SB.MEM.DCKF)
                    }
                }

                If (\_SB.MEM.GP64)
                {
                    Store (0x00, \_SB.MEM.GP64)
                    If (\_SB.MEM.VALF)
                    {
                        Notify (\_SB.VALD, 0x80)
                    }
                    Else
                    {
                        If (\_SB.MEM.SBL0)
                        {
                            Store (0x00, \_SB.MEM.SBL0)
                            SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                            Store (\_SB.MEM.OECX, \_SB.MEM.BDID)
                            If (LNot (LEqual (\_SB.MEM.OECX, 0x00)))
                            {
                                If (LEqual (\_SB.MEM.OECX, 0x01)) {}
                                Else
                                {
                                    If (LEqual (\_SB.MEM.OECX, 0x04)) {}
                                    Else
                                    {
                                        Notify (\_SB.PCI0.FNC1.IDE1, 0x03)
                                    }
                                }
                            }
                        }

                        If (\_SB.MEM.SBL1)
                        {
                            Store (0x00, \_SB.MEM.SBL1)
                            SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                            If (LNot (LEqual (\_SB.MEM.OECX, 0x00)))
                            {
                                If (LEqual (\_SB.MEM.OECX, 0x01)) {}
                                Else
                                {
                                    If (LEqual (\_SB.MEM.OECX, 0x04)) {}
                                    Else
                                    {
                                        Notify (\_SB.PCI0.FNC1.IDE1, 0x00)
                                        Sleep (0x64)
                                        Notify (\_SB.PCI0.FNC1.IDE1, 0x01)
                                    }
                                }
                            }
                        }

                        If (\_SB.MEM.SBL2)
                        {
                            Store (0x00, \_SB.MEM.SBL2)
                            If (LNot (LEqual (\_SB.MEM.BDID, 0x00)))
                            {
                                If (LEqual (\_SB.MEM.BDID, 0x01)) {}
                                Else
                                {
                                    If (LEqual (\_SB.MEM.BDID, 0x04)) {}
                                    Else
                                    {
                                        Notify (\_SB.PCI0.FNC1.IDE1, 0x01)
                                    }
                                }
                            }
                        }

                        If (\_SB.MEM.SBL3)
                        {
                            Store (0x00, \_SB.MEM.SBL3)
                        }
                    }
                }

                If (\_SB.MEM.GP66)
                {
                    Store (0x00, \_SB.MEM.GP66)
                    SMBR (0xFE00, 0x14, 0x00, 0x00, 0xB2)
                    If (LNot (LEqual (\_SB.MEM.OECX, 0x00)))
                    {
                        If (LEqual (\_SB.MEM.OECX, 0x01)) {}
                        Else
                        {
                            If (LEqual (\_SB.MEM.OECX, 0x04))
                            {
                                Notify (\_SB.BAT2, 0x00)
                            }
                            Else
                            {
                                Notify (\_SB.PCI0.FNC1.IDE1, 0x00)
                                Sleep (0x64)
                                Notify (\_SB.PCI0.FNC1.IDE1, 0x01)
                            }
                        }
                    }
                }

                If (\_SB.MEM.GP70)
                {
                    Store (0x00, \_SB.MEM.GP70)
                    If (\_SB.MEM.VALF)
                    {
                        Notify (\_SB.VALD, 0x80)
                    }

                    If (LEqual (\_SB.MEM.HKCD, 0x3D))
                    {
                        TRAP (\_SB.MEM.HKCD)
                    }

                    If (LEqual (\_SB.MEM.DOS2, 0x00))
                    {
                        If (LEqual (\_SB.MEM.HKCD, 0x3F))
                        {
                            If (LEqual (\_SB.MEM.TNVS, 0x00))
                            {
                                Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                            }
                        }
                    }
                }

                If (\_SB.MEM.GP71)
                {
                    Store (0x00, \_SB.MEM.GP71)
                    Notify (\_SB.LID, 0x80)
                }

                If (\_SB.MEM.BPFE)
                {
                    Store (0x00, \_SB.MEM.BPFE)
                    Notify (\_SB.BT, 0x90)
                }
            }
        }
    }

    Method (_PTS, 1, NotSerialized)
    {
        If (LOr (LOr (\_SB.MEM.VWE0, \_SB.MEM.VWE1), \_SB.MEM.VWE2))
        {
            Store (0x01, \_SB.MEM.WED2)
        }
        Else
        {
            Store (0x00, \_SB.MEM.WED2)
        }

        Store (\_SB.MEM.ACST, \_SB.MEM.ACBK)
        If (LAnd (LNot (LLess (Arg0, 0x01)), LNot (LGreater (Arg0, 0x04))))
        {
            Store (\_SB.MEM.EWLD, \_SB.MEM.PAR1)
            Store (0x60, \_SB.PCI0.FNC0.SYSR.TRP4)
        }

        And (Arg0, 0x07, Local0)
        Or (Local0, 0x2100, Local0)
        SMBR (0xFA00, Local0, 0x00, 0x00, 0xB2)
    }

    Method (_WAK, 1, NotSerialized)
    {
        And (Arg0, 0x07, Local0)
        Or (Local0, 0x2180, Local0)
        SMBR (0xFA00, Local0, 0x00, 0x00, 0xB2)
        Notify (\_SB.PCI0.FNC1.IDE1, 0x00)
        Store (0x00, \_SB.MEM.RDID)
        Store (0x00, \_SB.MEM.RDSN)
        Store (0x05, \_SB.PCI0.FNC0.SYSR.TRP4)
        If (LEqual (\_SB.MEM.PAR1, 0x00))
        {
            If (LOr (LEqual (0x1B51F351, \_SB.MEM.RDID), LEqual (0x1C51F351, \_SB.MEM.RDID)))
            {
                If (LOr (LNot (LEqual (\_SB.MEM.RDID, \_SB.MEM.DLID)), LNot (LEqual (\_SB.MEM.RDSN, \_SB.MEM.DSRN))))
                {
                    SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                    And (\_SB.MEM.OEAX, 0xFF00, Local0)
                    If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                    {
                        Notify (\_SB.PCI0.DOCK, 0x00)
                    }
                    Else
                    {
                        Notify (\_SB.VALG, 0x81)
                    }
                }
            }
            Else
            {
                If (LEqual (0x1D51F351, \_SB.MEM.RDID))
                {
                    If (LOr (LNot (LEqual (\_SB.MEM.RDID, \_SB.MEM.DLID)), LNot (LEqual (\_SB.MEM.RDSN, \_SB.MEM.DSRN))))
                    {
                        SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                        And (\_SB.MEM.OEAX, 0xFF00, Local0)
                        If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                        {
                            Notify (\_SB.PCI0.DOCK, 0x00)
                        }
                        Else
                        {
                            Notify (\_SB.VALG, 0x81)
                        }
                    }
                }
            }
        }
        Else
        {
            If (\_SB.MEM.DLID)
            {
                SMBR (0x0136FA00, 0x05F3, 0x00, 0x00, 0xB2)
                And (\_SB.MEM.OEAX, 0xFF00, Local0)
                If (LOr (LAnd (LEqual (Local0, 0x00), LEqual (\_SB.MEM.OECX, 0x00)), LNot (LEqual (Local0, 0x00))))
                {
                    Notify (\_SB.PCI0.DOCK, 0x01)
                }
                Else
                {
                    Notify (\_SB.VALG, 0x83)
                }
            }
        }

        If (LEqual (\_SB.MEM.DOS2, 0x00))
        {
            If (LOr (LNot (LEqual (\_SB.MEM.CTLA, \_SB.MEM.NXLA)), LNot (LEqual (\_SB.MEM.CTCA, \_SB.MEM.NXCA))))
            {
                Notify (\_SB.PCI0.PCI1.VGA, 0x80)
            }
            Else
            {
                If (LNot (LEqual (\_SB.MEM.CTTA, \_SB.MEM.NXTA)))
                {
                    Notify (\_SB.PCI0.PCI1.VGA, 0x80)
                }
            }
        }

        DIS (0x14)
        DIS (0x23)
        SMBR (0xFF00, 0x1E, 0x01, 0x00, 0xB2)
        If (LNot (LGreater (\_SB.MEM.OSID, 0x03)))
        {
            While (LEqual (\_SB.MEM.KBCR, 0x00)) {}
        }

        Store (0x01, \_SB.MEM.PAR1)
        Store (0x60, \_SB.PCI0.FNC0.SYSR.TRP4)
        If (LNot (LEqual (\_SB.MEM.ACST, \_SB.MEM.ACBK)))
        {
            Notify (\_PR.CPU0, 0x80)
        }

        Name (BUFF, Package (0x02)
        {
            0x00, 
            0x01
        })
        If (LEqual (\_SB.MEM.ACST, 0x00))
        {
            And (\_SB.MEM.BST1, 0x04, Local0)
            If (LEqual (Local0, 0x04))
            {
                Store (0x01, Index (BUFF, 0x00))
            }
        }

        Return (BUFF)
    }

    Method (TRAP, 1, NotSerialized)
    {
        Add (Arg0, 0x12340000, Debug)
    }

    Method (SMBR, 5, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.IEAX)
        Store (Arg1, \_SB.MEM.IEBX)
        Store (Arg2, \_SB.MEM.IECX)
        Store (Arg3, \_SB.MEM.IEDX)
        Store (Arg4, \_SB.PCI0.FNC0.SYSR.TRP4)
    }

    Method (STA, 1, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.PAR1)
        Store (0x00, \_SB.MEM.PAR2)
        Store (0x00, \_SB.MEM.PAR3)
        Store (0x00, \_SB.MEM.PAR4)
        Store (0x00, \_SB.MEM.PAR5)
        Store (0x00, \_SB.MEM.PAR6)
        Store (0x01, \_SB.PCI0.FNC0.SYSR.TRP4)
        Return (\_SB.MEM.PAR4)
    }

    Method (CRS, 1, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.PAR1)
        Store (0x00, \_SB.MEM.PAR2)
        Store (0x00, \_SB.MEM.PAR3)
        Store (0x00, \_SB.MEM.PAR4)
        Store (0x00, \_SB.MEM.PAR5)
        Store (0x00, \_SB.MEM.PAR6)
        Store (0x01, \_SB.PCI0.FNC0.SYSR.TRP4)
        If (LEqual (\_SB.MEM.PAR3, 0x00))
        {
            Return (ResourceTemplate ()
            {
            })
        }

        Name (BUFF, Buffer (\_SB.MEM.PAR3) {})
        Store (\_SB.MEM.PRES, BUFF)
        Return (BUFF)
    }

    Method (PRS, 1, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.PAR1)
        Store (0x01, \_SB.MEM.PAR2)
        Store (0x00, \_SB.MEM.PAR3)
        Store (0x00, \_SB.MEM.PAR4)
        Store (0x00, \_SB.MEM.PAR5)
        Store (0x00, \_SB.MEM.PAR6)
        Store (0x01, \_SB.PCI0.FNC0.SYSR.TRP4)
        If (LEqual (\_SB.MEM.PAR3, 0x00))
        {
            Return (ResourceTemplate ()
            {
            })
        }

        Name (BUFF, Buffer (\_SB.MEM.PAR3) {})
        Store (\_SB.MEM.PRES, BUFF)
        Return (BUFF)
    }

    Method (SRS, 2, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.PAR1)
        Store (0x00, \_SB.MEM.PAR2)
        Store (0x00, \_SB.MEM.PAR3)
        Store (0x00, \_SB.MEM.PAR4)
        Store (0x00, \_SB.MEM.PAR5)
        Store (0x00, \_SB.MEM.PAR6)
        Store (Arg1, \_SB.MEM.PRES)
        Store (0x02, \_SB.PCI0.FNC0.SYSR.TRP4)
    }

    Method (DIS, 1, NotSerialized)
    {
        Store (Arg0, \_SB.MEM.PAR1)
        Store (0x00, \_SB.MEM.PAR2)
        Store (0x00, \_SB.MEM.PAR3)
        Store (0x00, \_SB.MEM.PAR4)
        Store (0x00, \_SB.MEM.PAR5)
        Store (0x00, \_SB.MEM.PAR6)
        Store (0x03, \_SB.PCI0.FNC0.SYSR.TRP4)
    }

    Method (PS0, 1, NotSerialized)
    {
        Store (0x00, \_SB.MEM.IESI)
        SMBR (0xFE00, 0x23, Arg0, 0x00, 0xB2)
        If (LEqual (\_SB.MEM.OEAX, 0x00))
        {
            Store (0x00, \_SB.MEM.IESI)
            SMBR (0xFF00, 0x23, Arg0, 0x00, 0xB2)
            WPSX (Arg0, 0x00, 0x00, 0x00)
        }
    }

    Method (PS3, 1, NotSerialized)
    {
        Store (0x00, \_SB.MEM.IESI)
        SMBR (0xFE00, 0x23, Arg0, 0x00, 0xB2)
        If (LEqual (\_SB.MEM.OEAX, 0x00))
        {
            Store (0x00, \_SB.MEM.IESI)
            SMBR (0xFF00, 0x23, Arg0, 0x03, 0xB2)
            WPSX (Arg0, 0x00, 0x00, 0x03)
        }
    }

    Method (WPSX, 4, NotSerialized)
    {
        Store (Arg1, \_SB.MEM.IESI)
        Store (Arg2, \_SB.MEM.IEDI)
        SMBR (0xFE00, 0x23, Arg0, 0x00, 0xB2)
        While (LNot (LEqual (\_SB.MEM.OECX, 0x00)))
        {
            Store (Arg1, \_SB.MEM.IESI)
            Store (Arg2, \_SB.MEM.IEDI)
            SMBR (0xFE00, 0x23, Arg0, 0x00, 0xB2)
        }
    }

    Method (PSC, 1, NotSerialized)
    {
        Store (0x00, \_SB.MEM.IESI)
        SMBR (0xFE00, 0x23, Arg0, 0x00, 0xB2)
        Return (\_SB.MEM.OEDX)
    }

    Method (CMPS, 2, NotSerialized)
    {
        If (LEqual (SizeOf (Arg0), SizeOf (Arg1)))
        {
            Return (One)
        }
        Else
        {
            Return (Zero)
        }
    }

    Method (STAL, 1, NotSerialized)
    {
        If (LEqual (Arg0, 0x00))
        {
            Return (0x09)
        }
        Else
        {
            Return (0x0B)
        }
    }

    Method (CRSL, 1, NotSerialized)
    {
        Name (IRQB, ResourceTemplate ()
        {
            IRQ (Level, ActiveLow, Shared)
                {}
        })
        CreateWordField (IRQB, 0x01, INTX)
        If (LNot (LEqual (Arg0, 0x00)))
        {
            Name (IRQT, Package (0x10)
            {
                0x00, 
                0x0200, 
                0x08, 
                0x0400, 
                0x10, 
                0x20, 
                0x80, 
                0x40, 
                0x02, 
                0x0800, 
                0x00, 
                0x1000, 
                0x00, 
                0x4000, 
                0x00, 
                0x8000
            })
            Store (DerefOf (Index (IRQT, Arg0)), Local0)
            Store (Local0, INTX)
        }

        Return (IRQB)
    }

    Mutex (MTEX, 0x00)
}


[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-06  3:29                   ` Andrey Borzenkov
@ 2007-06-06 19:09                     ` Bjorn Helgaas
  2007-06-06 20:45                       ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-06 19:09 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

On Tuesday 05 June 2007 09:29:11 pm Andrey Borzenkov wrote:
> On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> > Something's wrong with this strategy.  The BIOS is telling us that an
> > SMCf010 device is present, active, and responds at io ports 0x100-0x107
> > and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
> > an ISA or LPC bridge should be immaterial to the OS driver.
> 
> I thought this as well.

If this is really true, it also means we shouldn't twiddle with the
bridge.  If the BIOS left us a working setup, the preconfiguration
is certainly going to change it to something incompatible with the
PNP info.

What if we try the following patch, which keeps the FIR/SIR swap and
just removes the preconfiguration?

Index: linux-2.6/drivers/net/irda/smsc-ircc2.c
===================================================================
--- linux-2.6.orig/drivers/net/irda/smsc-ircc2.c	2007-06-04 10:35:03.000000000 -0600
+++ linux-2.6/drivers/net/irda/smsc-ircc2.c	2007-06-06 13:05:31.000000000 -0600
@@ -232,9 +232,7 @@
 #ifdef CONFIG_PCI
 static int __init preconfigure_smsc_chip(struct smsc_ircc_subsystem_configuration *conf);
 static int __init preconfigure_through_82801(struct pci_dev *dev, struct smsc_ircc_subsystem_configuration *conf);
-static void __init preconfigure_ali_port(struct pci_dev *dev,
 					 unsigned short port);
-static int __init preconfigure_through_ali(struct pci_dev *dev, struct smsc_ircc_subsystem_configuration *conf);
 static int __init smsc_ircc_preconfigure_subsystems(unsigned short ircc_cfg,
 						    unsigned short ircc_fir,
 						    unsigned short ircc_sir,
@@ -386,8 +384,8 @@
 	      pnp_dma_valid(dev, 0) && pnp_irq_valid(dev, 0)))
 		return -EINVAL;
 
-	sirbase = pnp_port_start(dev, 0);
-	firbase = pnp_port_start(dev, 1);
+	firbase = pnp_port_start(dev, 0);
+	sirbase = pnp_port_start(dev, 1);
 	dma = pnp_dma(dev, 0);
 	irq = pnp_irq(dev, 0);
 
@@ -2511,20 +2509,6 @@
 		.preconfigure = preconfigure_through_82801,
 		.name = "Toshiba laptop with Intel 8281DBM LPC bridge",
 	},
-	{
-		/* ALi M1533/M1535 PCI to ISA Bridge [Aladdin IV/V/V+] */
-		.vendor = PCIID_VENDOR_ALI,
-		.device = 0x1533,
-		.subvendor = 0x1179,
-		.subdevice = 0xffff, /* 0xffff is "any" */
-		.sir_io = 0x02e8,
-		.fir_io = 0x02f8,
-		.fir_irq = 0x07,
-		.fir_dma = 0x03,
-		.cfg_base = 0x002e,
-		.preconfigure = preconfigure_through_ali,
-		.name = "Toshiba laptop with ALi ISA bridge",
-	},
 	{ } // Terminator
 };
 
@@ -2783,63 +2767,6 @@
 	return preconfigure_smsc_chip(conf);
 }
 
-/*
- * Pre-configure a certain port on the ALi 1533 bridge.
- * This is based on reverse-engineering since ALi does not
- * provide any data sheet for the 1533 chip.
- */
-static void __init preconfigure_ali_port(struct pci_dev *dev,
-					 unsigned short port)
-{
-	unsigned char reg;
-	/* These bits obviously control the different ports */
-	unsigned char mask;
-	unsigned char tmpbyte;
-
-	switch(port) {
-	case 0x0130:
-	case 0x0178:
-		reg = 0xb0;
-		mask = 0x80;
-		break;
-	case 0x03f8:
-		reg = 0xb4;
-		mask = 0x80;
-		break;
-	case 0x02f8:
-		reg = 0xb4;
-		mask = 0x30;
-		break;
-	case 0x02e8:
-		reg = 0xb4;
-		mask = 0x08;
-		break;
-	default:
-		IRDA_ERROR("Failed to configure unsupported port on ALi 1533 bridge: 0x%04x\n", port);
-		return;
-	}
-
-	pci_read_config_byte(dev, reg, &tmpbyte);
-	/* Turn on the right bits */
-	tmpbyte |= mask;
-	pci_write_config_byte(dev, reg, tmpbyte);
-	IRDA_MESSAGE("Activated ALi 1533 ISA bridge port 0x%04x.\n", port);
-	return;
-}
-
-static int __init preconfigure_through_ali(struct pci_dev *dev,
-					   struct
-					   smsc_ircc_subsystem_configuration
-					   *conf)
-{
-	/* Configure the two ports on the ALi 1533 */
-	preconfigure_ali_port(dev, conf->sir_io);
-	preconfigure_ali_port(dev, conf->fir_io);
-
-	/* Pre-configure chip */
-	return preconfigure_smsc_chip(conf);
-}
-
 static int __init smsc_ircc_preconfigure_subsystems(unsigned short ircc_cfg,
 						    unsigned short ircc_fir,
 						    unsigned short ircc_sir,

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-06 19:09                     ` Bjorn Helgaas
@ 2007-06-06 20:45                       ` Andrey Borzenkov
  2007-06-07 15:52                         ` Bjorn Helgaas
  2007-06-07 18:34                         ` Bjorn Helgaas
  0 siblings, 2 replies; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-06 20:45 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

[-- Attachment #1: Type: text/plain, Size: 1085 bytes --]

On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> On Tuesday 05 June 2007 09:29:11 pm Andrey Borzenkov wrote:
> > On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> > > Something's wrong with this strategy.  The BIOS is telling us that an
> > > SMCf010 device is present, active, and responds at io ports 0x100-0x107
> > > and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
> > > an ISA or LPC bridge should be immaterial to the OS driver.
> >
> > I thought this as well.
>
> If this is really true, it also means we shouldn't twiddle with the
> bridge.  If the BIOS left us a working setup, the preconfiguration
> is certainly going to change it to something incompatible with the
> PNP info.
>
> What if we try the following patch, which keeps the FIR/SIR swap and
> just removes the preconfiguration?
>

I already tried different patch but with similar effect (switch off 
preconfiguration) - it does not work. I am beginning to doubt whether drier 
works on my system at all (i.e. before PnP change); have to find time to 
test.

-andrey

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* RE: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-05 23:23                 ` Bjorn Helgaas
  2007-06-06  3:29                   ` Andrey Borzenkov
@ 2007-06-07 12:23                   ` Linus Walleij (LD/EAB)
  2007-06-07 15:44                     ` Bjorn Helgaas
  1 sibling, 1 reply; 48+ messages in thread
From: Linus Walleij (LD/EAB) @ 2007-06-07 12:23 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Samuel Ortiz, arvidjaar, linux-kernel, Michal Piotrowski, ambx1

Björn wrote:

> Something's wrong with this strategy.  The BIOS is telling us 
> that an SMCf010 device is present, active, and responds at io 
> ports 0x100-0x107 and 0x2e8-0x2ef.  The fact that it happens 
> to be on the other side of an ISA or LPC bridge should be 
> immaterial to the OS driver.

Yes, ideally. Yes of course it is wrong, or from a platonic
perspective. If nobody wrote buggy BIOS:es there would be no
problem.

There is some history in the preconfigure functions:
these come from the smcinit tool (see http://irda.sourceforge.net/smcinit/),
the hacks target laptops where the (buggy) BIOS does not properly
preconfigure the bridge. The assumption in the current code
is that Toshiba laptops with this smscchip will have the problem,
because they always had in the past...

I have no idea how bridges on such laptops are really preconfigured,
possibly with some special hacks to the (manufacturer-supplied-assumed)
"driver CD" for Windows only that apply some low-level tweaks to the
WinNT/XP boot process. All info an reverse-engineering on this subject
is warmly welcomed.

There are some troubles further related to issues due to laptops
supporting both ACPI and APM too I think, never dug into it.

Linus

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-07 12:23                   ` Linus Walleij (LD/EAB)
@ 2007-06-07 15:44                     ` Bjorn Helgaas
  0 siblings, 0 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-07 15:44 UTC (permalink / raw)
  To: Linus Walleij (LD/EAB)
  Cc: Samuel Ortiz, arvidjaar, linux-kernel, Michal Piotrowski, ambx1

On Thursday 07 June 2007 06:23:58 am Linus Walleij (LD/EAB) wrote:
> Björn wrote:
> > Something's wrong with this strategy.  The BIOS is telling us 
> > that an SMCf010 device is present, active, and responds at io 
> > ports 0x100-0x107 and 0x2e8-0x2ef.  The fact that it happens 
> > to be on the other side of an ISA or LPC bridge should be 
> > immaterial to the OS driver.
> 
> Yes, ideally. Yes of course it is wrong, or from a platonic
> perspective. If nobody wrote buggy BIOS:es there would be no
> problem.

Yup, I agree that we will always need to work around BIOS bugs.

But smsc-ircc2 contains a *lot* of preconfigure stuff.  I'm
skeptical that all of it is really to work around BIOS bugs.
I think it's more likely that Linux just isn't using the PNP
info correctly or drivers for other southbridge devices are
getting in the way.

> There is some history in the preconfigure functions:
> these come from the smcinit tool (see http://irda.sourceforge.net/smcinit/),

Thanks for the pointer.  I'll read over that and see if I can
find a laptop to play with.

Bjorn


^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-06 20:45                       ` Andrey Borzenkov
@ 2007-06-07 15:52                         ` Bjorn Helgaas
  2007-06-07 20:47                           ` Samuel Ortiz
  2007-06-07 18:34                         ` Bjorn Helgaas
  1 sibling, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-07 15:52 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

On Wednesday 06 June 2007 02:45:01 pm Andrey Borzenkov wrote:
> On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> > On Tuesday 05 June 2007 09:29:11 pm Andrey Borzenkov wrote:
> > > On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> > > > Something's wrong with this strategy.  The BIOS is telling us that an
> > > > SMCf010 device is present, active, and responds at io ports 0x100-0x107
> > > > and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
> > > > an ISA or LPC bridge should be immaterial to the OS driver.
> > >
> > > I thought this as well.
> >
> > If this is really true, it also means we shouldn't twiddle with the
> > bridge.  If the BIOS left us a working setup, the preconfiguration
> > is certainly going to change it to something incompatible with the
> > PNP info.
> >
> > What if we try the following patch, which keeps the FIR/SIR swap and
> > just removes the preconfiguration?
> 
> I already tried different patch but with similar effect (switch off 
> preconfiguration) - it does not work. I am beginning to doubt whether drier 
> works on my system at all (i.e. before PnP change); have to find time to 
> test.

OK.  My patch wasn't the right approach anyway.  Attached is what I
think we should do instead -- do the preconfig if we're not using PNP.

I need to figure out how to test this though.  The current smsc-ircc2
works on my HP nw8240, but I don't have any indication that it works
on laptops that require preconfiguration.



[patch] smsc-ircc2: skip preconfiguration for PNP devices

If we rely on the device resources from PNPBIOS, we also have to rely on
the BIOS to configure any bridges on the way to the device.

Using the PNPBIOS resources but twiddling the configuration of a
bridge behind the back of the firmware is likely to make things
inconsistent.

With "smsc-ircc2.nopnp", we do the legacy device probe, including
manual bridge preconfiguration, as before.

Index: w/drivers/net/irda/smsc-ircc2.c
===================================================================
--- w.orig/drivers/net/irda/smsc-ircc2.c	2007-06-06 15:45:14.000000000 -0600
+++ w/drivers/net/irda/smsc-ircc2.c	2007-06-06 15:50:40.000000000 -0600
@@ -416,6 +416,13 @@
 {
 	int ret = 0;
 
+#ifdef CONFIG_PCI
+	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir, ircc_dma, ircc_irq) < 0) {
+		/* Ignore errors from preconfiguration */
+		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
+	}
+#endif
+
 	if (ircc_fir > 0 && ircc_sir > 0) {
 		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
 		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
@@ -459,13 +466,6 @@
 		return ret;
 	}
 
-#ifdef CONFIG_PCI
-	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir, ircc_dma, ircc_irq) < 0) {
-		/* Ignore errors from preconfiguration */
-		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
-	}
-#endif
-
 	dev_count = 0;
 
 	if (smsc_nopnp || !pnp_platform_devices ||

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-06 20:45                       ` Andrey Borzenkov
  2007-06-07 15:52                         ` Bjorn Helgaas
@ 2007-06-07 18:34                         ` Bjorn Helgaas
  2007-06-08  5:24                           ` Andrey Borzenkov
  2007-06-10  8:03                           ` Andrey Borzenkov
  1 sibling, 2 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-07 18:34 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

On Wednesday 06 June 2007 02:45:01 pm Andrey Borzenkov wrote:
> I am beginning to doubt whether drier 
> works on my system at all (i.e. before PnP change); have to find time to 
> test.

In 2.6.21, smsc-ircc2 at least found the device.  So we definitely have
a problem because in 2.6.22-rc, we don't find the device.

What laptop do you have?  Maybe I can find one to play with.

I think Windows always calls _SRS, even if it doesn't need to change
the current resource settings.  Linux doesn't do that, and my HP nw8240
firmware has a bug that leaves the IR device partly-enabled until _SRS
is called.  Maybe yours has a similar bug.

Can you set CONFIG_ACPI_DEBUG=y, make it so smsc-ircc2 isn't loaded
automatically, and try this (along with my previous patch to swap
FIR and SIR):

  # dmesg -n 8
  # echo 0x200 > /sys/module/acpi/parameters/debug_level
  # echo disable > /sys/bus/pnp/devices/00:0a/resources
  # echo activate > /sys/bus/pnp/devices/00:0a/resources
  # modprobe smsc-ircc2

If you try this, can you collect the whole dmesg log?

It's also possible that some other driver like i2c is messing with
the ISA/LPC bridge configuration and breaking the IR device config.
Your lspnp output doesn't show any other ISA devices down there,
but I know i2c likes to poke around and discover things that kinda,
sorta work, but the BIOS didn't expose.

Bjorn

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-07 15:52                         ` Bjorn Helgaas
@ 2007-06-07 20:47                           ` Samuel Ortiz
  2007-06-10  6:47                             ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Samuel Ortiz @ 2007-06-07 20:47 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrey Borzenkov, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1

Hi Bjorn,

On 6/7/2007, "Bjorn Helgaas" <bjorn.helgaas@hp.com> wrote:

>On Wednesday 06 June 2007 02:45:01 pm Andrey Borzenkov wrote:
>> On Wednesday 06 June 2007, Bjorn Helgaas wrote:
>> > On Tuesday 05 June 2007 09:29:11 pm Andrey Borzenkov wrote:
>> > > On Wednesday 06 June 2007, Bjorn Helgaas wrote:
>> > > > Something's wrong with this strategy.  The BIOS is telling us that an
>> > > > SMCf010 device is present, active, and responds at io ports 0x100-0x107
>> > > > and 0x2e8-0x2ef.  The fact that it happens to be on the other side of
>> > > > an ISA or LPC bridge should be immaterial to the OS driver.
>> > >
>> > > I thought this as well.
>> >
>> > If this is really true, it also means we shouldn't twiddle with the
>> > bridge.  If the BIOS left us a working setup, the preconfiguration
>> > is certainly going to change it to something incompatible with the
>> > PNP info.
>> >
>> > What if we try the following patch, which keeps the FIR/SIR swap and
>> > just removes the preconfiguration?
>>
>> I already tried different patch but with similar effect (switch off
>> preconfiguration) - it does not work. I am beginning to doubt whether drier
>> works on my system at all (i.e. before PnP change); have to find time to
>> test.
>
>OK.  My patch wasn't the right approach anyway.  Attached is what I
>think we should do instead -- do the preconfig if we're not using PNP.
Thats sounds good, yes.
Maybe we should also run the legacy probe when the PnP one fails. I
don't know how the preconfiguration stuff will behave with the device
being PnP enabled, but with your patch Andrey will still need to
modprobe smsc-ircc with smsc_nopnp.

So, here is the patch I propose (I had to move smsc_ircc_legacy_probe()
a bit earlier in the code to avoid forward declaration, but it's
basically your patch plus a call to smsc_ircc_legacy_probe() from the
pnp_probe() routine):


diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
index 9043bf4..1d7ab3f 100644
--- a/drivers/net/irda/smsc-ircc2.c
+++ b/drivers/net/irda/smsc-ircc2.c
@@ -366,6 +366,44 @@ static inline void register_bank(int iobase, int bank)
                iobase + IRCC_MASTER);
 }
 
+
+static int __init smsc_ircc_legacy_probe(void)
+{
+	int ret = 0;
+
+#ifdef CONFIG_PCI
+	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir,
+					      ircc_dma, ircc_irq) < 0) {
+		/* Ignore errors from preconfiguration */
+		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
+	}
+#endif
+
+	if (ircc_fir > 0 && ircc_sir > 0) {
+		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
+		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
+
+		if (smsc_ircc_open(ircc_fir, ircc_sir, ircc_dma, ircc_irq))
+			ret = -ENODEV;
+	} else {
+		ret = -ENODEV;
+
+		/* try user provided configuration register base address */
+		if (ircc_cfg > 0) {
+			IRDA_MESSAGE(" Overriding configuration address "
+				     "0x%04x\n", ircc_cfg);
+			if (!smsc_superio_fdc(ircc_cfg))
+				ret = 0;
+			if (!smsc_superio_lpc(ircc_cfg))
+				ret = 0;
+		}
+
+		if (smsc_ircc_look_for_chips() > 0)
+			ret = 0;
+	}
+	return ret;
+}
+
 /* PNP hotplug support */
 static const struct pnp_device_id smsc_ircc_pnp_table[] = {
 	{ .id = "SMCf010", .driver_data = 0 },
@@ -391,9 +429,14 @@ static int __init smsc_ircc_pnp_probe(struct pnp_dev *dev,
 	dma = pnp_dma(dev, 0);
 	irq = pnp_irq(dev, 0);
 
-	if (smsc_ircc_open(firbase, sirbase, dma, irq))
-		return -ENODEV;
-
+	if (smsc_ircc_open(firbase, sirbase, dma, irq)) {
+		IRDA_ERROR("PnP probe failed\n");
+		if (smsc_ircc_legacy_probe()) {
+			IRDA_ERROR("Legacy probe failed\n");
+			return -ENODEV;
+		}
+	}
+	
 	return 0;
 }
 
@@ -412,35 +455,6 @@ static struct pnp_driver smsc_ircc_pnp_driver = {
  *
  *******************************************************************************/
 
-static int __init smsc_ircc_legacy_probe(void)
-{
-	int ret = 0;
-
-	if (ircc_fir > 0 && ircc_sir > 0) {
-		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
-		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
-
-		if (smsc_ircc_open(ircc_fir, ircc_sir, ircc_dma, ircc_irq))
-			ret = -ENODEV;
-	} else {
-		ret = -ENODEV;
-
-		/* try user provided configuration register base address */
-		if (ircc_cfg > 0) {
-			IRDA_MESSAGE(" Overriding configuration address "
-				     "0x%04x\n", ircc_cfg);
-			if (!smsc_superio_fdc(ircc_cfg))
-				ret = 0;
-			if (!smsc_superio_lpc(ircc_cfg))
-				ret = 0;
-		}
-
-		if (smsc_ircc_look_for_chips() > 0)
-			ret = 0;
-	}
-	return ret;
-}
-
 /*
  * Function smsc_ircc_init ()
  *
@@ -459,13 +473,6 @@ static int __init smsc_ircc_init(void)
 		return ret;
 	}
 
-#ifdef CONFIG_PCI
-	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir, ircc_dma, ircc_irq) < 0) {
-		/* Ignore errors from preconfiguration */
-		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
-	}
-#endif
-
 	dev_count = 0;
 
 	if (smsc_nopnp || !pnp_platform_devices ||


^ permalink raw reply related	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-07 18:34                         ` Bjorn Helgaas
@ 2007-06-08  5:24                           ` Andrey Borzenkov
  2007-06-10  8:03                           ` Andrey Borzenkov
  1 sibling, 0 replies; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-08  5:24 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

[-- Attachment #1: Type: text/plain, Size: 342 bytes --]

On Thursday 07 June 2007, Bjorn Helgaas wrote:
> In 2.6.21, smsc-ircc2 at least found the device.  So we definitely have
> a problem because in 2.6.22-rc, we don't find the device.
>
> What laptop do you have?  Maybe I can find one to play with.
>

This is Toshiba Portege 4000. The rest of your questions later when I have 
time :)

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-07 20:47                           ` Samuel Ortiz
@ 2007-06-10  6:47                             ` Andrey Borzenkov
  2007-06-10 21:03                               ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-10  6:47 UTC (permalink / raw)
  To: Samuel Ortiz
  Cc: Bjorn Helgaas, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 8573 bytes --]

On Friday 08 June 2007, Samuel Ortiz wrote:
> Hi Bjorn,
>
> On 6/7/2007, "Bjorn Helgaas" <bjorn.helgaas@hp.com> wrote:
> >On Wednesday 06 June 2007 02:45:01 pm Andrey Borzenkov wrote:
> >> On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> >> > On Tuesday 05 June 2007 09:29:11 pm Andrey Borzenkov wrote:
> >> > > On Wednesday 06 June 2007, Bjorn Helgaas wrote:
> >> > > > Something's wrong with this strategy.  The BIOS is telling us that
> >> > > > an SMCf010 device is present, active, and responds at io ports
> >> > > > 0x100-0x107 and 0x2e8-0x2ef.  The fact that it happens to be on
> >> > > > the other side of an ISA or LPC bridge should be immaterial to the
> >> > > > OS driver.
> >> > >
> >> > > I thought this as well.
> >> >
> >> > If this is really true, it also means we shouldn't twiddle with the
> >> > bridge.  If the BIOS left us a working setup, the preconfiguration
> >> > is certainly going to change it to something incompatible with the
> >> > PNP info.
> >> >
> >> > What if we try the following patch, which keeps the FIR/SIR swap and
> >> > just removes the preconfiguration?
> >>
> >> I already tried different patch but with similar effect (switch off
> >> preconfiguration) - it does not work. I am beginning to doubt whether
> >> drier works on my system at all (i.e. before PnP change); have to find
> >> time to test.
> >
> >OK.  My patch wasn't the right approach anyway.  Attached is what I
> >think we should do instead -- do the preconfig if we're not using PNP.
>
> Thats sounds good, yes.
> Maybe we should also run the legacy probe when the PnP one fails. I
> don't know how the preconfiguration stuff will behave with the device
> being PnP enabled, but with your patch Andrey will still need to
> modprobe smsc-ircc with smsc_nopnp.
>

One thing that makes me uneasy - ideally we have to do it *after* PnP probe 
fails. Currently we lie to PnP layer that we successfully probed for device 
while in effect we did not (at least, not where PnP told us to).

> So, here is the patch I propose (I had to move smsc_ircc_legacy_probe()
> a bit earlier in the code to avoid forward declaration, but it's
> basically your patch plus a call to smsc_ircc_legacy_probe() from the
> pnp_probe() routine):
>

Yes this patch works:

[58674.337465] pnp: Device 00:0a activated.
[58674.337465] smsc_ircc_present(), addr 0x02e8 - no device found!
[58674.337465] PnP probe failed
[58674.340799] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
IrDA chip, pre-configuring device.
[58674.340799] Activated ALi 1533 ISA bridge port 0x02e8.
[58674.340799] Activated ALi 1533 ISA bridge port 0x02f8.
[58674.340799] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): 
LPC47N227
[58674.340799] smsc_superio_flat(): IrDA not enabled
[58674.340799] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, 
mode: 0x02
[58674.340799] SMsC IrDA Controller found
[58674.340799]  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
[58674.340799] No transceiver found. Defaulting to Fast pin select


But I noticed something very strange.

{pts/1}% lspnp -vv 00:0a
00:0a SMCf010 SMC Fast Infrared Port
    state = active
    allocated resources:
        io 0x100-0x107
        io 0x2e8-0x2ef
        irq 5
        dma 1
    possible resources:
        port 0x100-0x130, align 0xf, size 0x8, 16-bit address decoding
        irq 3,4,5,6,7,10,11 High-Edge
        dma 1,2,3 16-bit compatible
        Dependent: 01 - Priority acceptable
           port 0x3f8-0x3f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 02 - Priority acceptable
           port 0x2e8-0x2e8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 03 - Priority acceptable
           port 0x2f8-0x2f8, align 0x0, size 0x8, 16-bit address decoding
        Dependent: 04 - Priority acceptable
           port 0x3e8-0x3e8, align 0x0, size 0x8, 16-bit address decoding

but

{pts/1}% cat /proc/ioports
0000-001f : dma1
0020-0021 : pic1
0040-0043 : timer0
0050-0053 : timer1
0060-006f : keyboard
0070-0077 : rtc
0080-008f : dma page reg
00a0-00a1 : pic2
00c0-00df : dma2
00f0-00ff : fpu
0100-013f : pcmcia_socket0
^^^^^^^^^^^^^^^^^^^^^^^^^^ hell, what's it?

and really

{pts/1}% sudo 
cat /sys/class/pcmcia_socket/pcmcia_socket0/available_resources_io
0x00000100 - 0x000003af
0x000003e0 - 0x000004ff
0x00000820 - 0x000008ff
0x00000a00 - 0x00000aff
0x00000c00 - 0x00000cf7

Does it mean we did not inform PnP layer when PCMCIA is configured? Should we 
do it? I Cc to PCMCIA maintainer as well :) Configuration I have

{pts/1}% pccardctl status
Socket 0:
  3.3V 16-bit PC Card
  Subdevice 0 (function 0) bound to driver "wlags49"
Socket 1:
  no card
Socket 2:
  no card
{pts/1}% pccardctl info
PRODID_1="TOSHIBA"
PRODID_2="Wireless LAN Card"
PRODID_3="Version 01.01"
PRODID_4=""
MANFID=0156,0002
FUNCID=6
PRODID_1=""
PRODID_2=""
PRODID_3=""
PRODID_4=""
MANFID=0000,0000
FUNCID=255
PRODID_1=""
PRODID_2=""
PRODID_3=""
PRODID_4=""
MANFID=0000,0000
FUNCID=255

>
> diff --git a/drivers/net/irda/smsc-ircc2.c b/drivers/net/irda/smsc-ircc2.c
> index 9043bf4..1d7ab3f 100644
> --- a/drivers/net/irda/smsc-ircc2.c
> +++ b/drivers/net/irda/smsc-ircc2.c
> @@ -366,6 +366,44 @@ static inline void register_bank(int iobase, int bank)
>                 iobase + IRCC_MASTER);
>  }
>
> +
> +static int __init smsc_ircc_legacy_probe(void)
> +{
> +	int ret = 0;
> +
> +#ifdef CONFIG_PCI
> +	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir,
> +					      ircc_dma, ircc_irq) < 0) {
> +		/* Ignore errors from preconfiguration */
> +		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
> +	}
> +#endif
> +
> +	if (ircc_fir > 0 && ircc_sir > 0) {
> +		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
> +		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
> +
> +		if (smsc_ircc_open(ircc_fir, ircc_sir, ircc_dma, ircc_irq))
> +			ret = -ENODEV;
> +	} else {
> +		ret = -ENODEV;
> +
> +		/* try user provided configuration register base address */
> +		if (ircc_cfg > 0) {
> +			IRDA_MESSAGE(" Overriding configuration address "
> +				     "0x%04x\n", ircc_cfg);
> +			if (!smsc_superio_fdc(ircc_cfg))
> +				ret = 0;
> +			if (!smsc_superio_lpc(ircc_cfg))
> +				ret = 0;
> +		}
> +
> +		if (smsc_ircc_look_for_chips() > 0)
> +			ret = 0;
> +	}
> +	return ret;
> +}
> +
>  /* PNP hotplug support */
>  static const struct pnp_device_id smsc_ircc_pnp_table[] = {
>  	{ .id = "SMCf010", .driver_data = 0 },
> @@ -391,9 +429,14 @@ static int __init smsc_ircc_pnp_probe(struct pnp_dev
> *dev, dma = pnp_dma(dev, 0);
>  	irq = pnp_irq(dev, 0);
>
> -	if (smsc_ircc_open(firbase, sirbase, dma, irq))
> -		return -ENODEV;
> -
> +	if (smsc_ircc_open(firbase, sirbase, dma, irq)) {
> +		IRDA_ERROR("PnP probe failed\n");
> +		if (smsc_ircc_legacy_probe()) {
> +			IRDA_ERROR("Legacy probe failed\n");
> +			return -ENODEV;
> +		}
> +	}
> +
>  	return 0;
>  }
>
> @@ -412,35 +455,6 @@ static struct pnp_driver smsc_ircc_pnp_driver = {
>   *
>  
> ***************************************************************************
>****/
>
> -static int __init smsc_ircc_legacy_probe(void)
> -{
> -	int ret = 0;
> -
> -	if (ircc_fir > 0 && ircc_sir > 0) {
> -		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
> -		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
> -
> -		if (smsc_ircc_open(ircc_fir, ircc_sir, ircc_dma, ircc_irq))
> -			ret = -ENODEV;
> -	} else {
> -		ret = -ENODEV;
> -
> -		/* try user provided configuration register base address */
> -		if (ircc_cfg > 0) {
> -			IRDA_MESSAGE(" Overriding configuration address "
> -				     "0x%04x\n", ircc_cfg);
> -			if (!smsc_superio_fdc(ircc_cfg))
> -				ret = 0;
> -			if (!smsc_superio_lpc(ircc_cfg))
> -				ret = 0;
> -		}
> -
> -		if (smsc_ircc_look_for_chips() > 0)
> -			ret = 0;
> -	}
> -	return ret;
> -}
> -
>  /*
>   * Function smsc_ircc_init ()
>   *
> @@ -459,13 +473,6 @@ static int __init smsc_ircc_init(void)
>  		return ret;
>  	}
>
> -#ifdef CONFIG_PCI
> -	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir,
> ircc_dma, ircc_irq) < 0) { -		/* Ignore errors from preconfiguration */
> -		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
> -	}
> -#endif
> -
>  	dev_count = 0;
>
>  	if (smsc_nopnp || !pnp_platform_devices ||



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-07 18:34                         ` Bjorn Helgaas
  2007-06-08  5:24                           ` Andrey Borzenkov
@ 2007-06-10  8:03                           ` Andrey Borzenkov
  2007-06-10 20:04                             ` Bjorn Helgaas
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-10  8:03 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

[-- Attachment #1: Type: text/plain, Size: 1840 bytes --]

On Thursday 07 June 2007, Bjorn Helgaas wrote:
> On Wednesday 06 June 2007 02:45:01 pm Andrey Borzenkov wrote:
> > I am beginning to doubt whether drier
> > works on my system at all (i.e. before PnP change); have to find time to
> > test.
>
> In 2.6.21, smsc-ircc2 at least found the device.  So we definitely have
> a problem because in 2.6.22-rc, we don't find the device.
>
> What laptop do you have?  Maybe I can find one to play with.
>
> I think Windows always calls _SRS, even if it doesn't need to change
> the current resource settings.  Linux doesn't do that, and my HP nw8240
> firmware has a bug that leaves the IR device partly-enabled until _SRS
> is called.  Maybe yours has a similar bug.
>
> Can you set CONFIG_ACPI_DEBUG=y, make it so smsc-ircc2 isn't loaded
> automatically, and try this (along with my previous patch to swap
> FIR and SIR):
>
>   # dmesg -n 8
>   # echo 0x200 > /sys/module/acpi/parameters/debug_level
>   # echo disable > /sys/bus/pnp/devices/00:0a/resources
>   # echo activate > /sys/bus/pnp/devices/00:0a/resources
>   # modprobe smsc-ircc2
>
> If you try this, can you collect the whole dmesg log?
>

well, dmesg (/var/log/messages) is around 35MB :) Even bz2 compressed it is 
over 700KB. I put it here: 
http://dump.ru:80/loadfile.php?filename=fir_acpi_debug.bz2&id=379192 

This is from /var/log/messages. I do not have serial console and cannot 
capture output directly; I can only hope nothing is lost at this rate.

> It's also possible that some other driver like i2c is messing with
> the ISA/LPC bridge configuration and breaking the IR device config.
> Your lspnp output doesn't show any other ISA devices down there,
> but I know i2c likes to poke around and discover things that kinda,
> sorta work, but the BIOS didn't expose.
>
> Bjorn



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-10  8:03                           ` Andrey Borzenkov
@ 2007-06-10 20:04                             ` Bjorn Helgaas
  0 siblings, 0 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-10 20:04 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Linus Walleij (LD/EAB),
	Samuel Ortiz, linux-kernel, Michal Piotrowski, ambx1

On Sunday 10 June 2007 02:03:03 am Andrey Borzenkov wrote:
> > Can you set CONFIG_ACPI_DEBUG=y, make it so smsc-ircc2 isn't loaded
> > automatically, and try this (along with my previous patch to swap
> > FIR and SIR):
> >
> >   # dmesg -n 8
> >   # echo 0x200 > /sys/module/acpi/parameters/debug_level
> >   # echo disable > /sys/bus/pnp/devices/00:0a/resources
> >   # echo activate > /sys/bus/pnp/devices/00:0a/resources
> >   # modprobe smsc-ircc2
> >
> > If you try this, can you collect the whole dmesg log?
> 
> well, dmesg (/var/log/messages) is around 35MB :) Even bz2 compressed it is 
> over 700KB. I put it here: 
> http://dump.ru:80/loadfile.php?filename=fir_acpi_debug.bz2&id=379192 
> 
> This is from /var/log/messages. I do not have serial console and cannot 
> capture output directly; I can only hope nothing is lost at this rate.

Wow, that is big :-)

I guess smsc-ircc2 still didn't find the device, so you got
something like this:

  smsc_ircc_present(), addr 0x02e8 - no device found!

Right?

I'm out of ideas, and I don't want to waste more of your time on
this.  I'm going to try to find a Portege 4000 to play with myself.
That might take a few days, and I'm going to be out of the office
from June 20-July 9, so I'm afraid it will be slow.  But I *will*
fix it!

Bjorn


^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-10  6:47                             ` Andrey Borzenkov
@ 2007-06-10 21:03                               ` Bjorn Helgaas
  2007-06-11 14:04                                 ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-10 21:03 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

On Sunday 10 June 2007 12:47:07 am Andrey Borzenkov wrote:
> > Maybe we should also run the legacy probe when the PnP one fails. I
> > don't know how the preconfiguration stuff will behave with the device
> > being PnP enabled, but with your patch Andrey will still need to
> > modprobe smsc-ircc with smsc_nopnp.
> 
> One thing that makes me uneasy - ideally we have to do it *after* PnP probe 
> fails. Currently we lie to PnP layer that we successfully probed for device 
> while in effect we did not (at least, not where PnP told us to).
> 
> > So, here is the patch I propose (I had to move smsc_ircc_legacy_probe()
> > a bit earlier in the code to avoid forward declaration, but it's
> > basically your patch plus a call to smsc_ircc_legacy_probe() from the
> > pnp_probe() routine):

This patch does the legacy probe if PNP says we have an SMCf010, but
we couldn't make it work.  In that situation, I think we need a PNP
quirk or other kernel PNP fix.  Ultimately, we should only use the
legacy probe if we don't have PNP at all.  

But we're a long ways from that.  First, we have to figure out how
to make PNP detection work at all, then make sure it works for all
the machines we know about.

> Yes this patch works:
> 
> [58674.337465] pnp: Device 00:0a activated.
> [58674.337465] smsc_ircc_present(), addr 0x02e8 - no device found!
> [58674.337465] PnP probe failed
> [58674.340799] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
> IrDA chip, pre-configuring device.

So while this patch works, I don't think it's the right long-term
direction.

> {pts/1}% lspnp -vv 00:0a
> 00:0a SMCf010 SMC Fast Infrared Port
>     state = active
>     allocated resources:
>         io 0x100-0x107
> ...

> {pts/1}% cat /proc/ioports
> ...
> 0100-013f : pcmcia_socket0
> ...

> {pts/1}% sudo cat /sys/class/pcmcia_socket/pcmcia_socket0/available_resources_io
> 0x00000100 - 0x000003af
> 0x000003e0 - 0x000004ff
> 0x00000820 - 0x000008ff
> 0x00000a00 - 0x00000aff
> 0x00000c00 - 0x00000cf7

It's indeed very interesting that pcmcia_socket0 seems to have its
fingers in the same ioport range the IR device thinks it's using.
I don't know much about PCMCIA, but I can see I'm going to have to
learn something :-)

Can you send me your "lspci -vv" output, the whole /proc/ioports and
/proc/iomem, and your dmesg log?  And maybe your pcmcia_socket
available_resources_io and available_resources_mem for good measure.

Bjorn

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-10 21:03                               ` Bjorn Helgaas
@ 2007-06-11 14:04                                 ` Andrey Borzenkov
  2007-06-14 21:30                                   ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-11 14:04 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 43480 bytes --]

On Monday 11 June 2007, Bjorn Helgaas wrote:
> > {pts/1}% lspnp -vv 00:0a
> > 00:0a SMCf010 SMC Fast Infrared Port
> >     state = active
> >     allocated resources:
> >         io 0x100-0x107
> > ...
> >
> > {pts/1}% cat /proc/ioports
> > ...
> > 0100-013f : pcmcia_socket0
> > ...
> >
> > {pts/1}% sudo cat
> > /sys/class/pcmcia_socket/pcmcia_socket0/available_resources_io 0x00000100
> > - 0x000003af
> > 0x000003e0 - 0x000004ff
> > 0x00000820 - 0x000008ff
> > 0x00000a00 - 0x00000aff
> > 0x00000c00 - 0x00000cf7
>
> It's indeed very interesting that pcmcia_socket0 seems to have its
> fingers in the same ioport range the IR device thinks it's using.
> I don't know much about PCMCIA, but I can see I'm going to have to
> learn something :-)
>

For the record - I tried to completely unload PCMCIA driver for slot 0 (and 
verified that 0x100 IO port is free) and tried to load smsc, but it did not 
change anything whether I used first or second port for FIR.

> Can you send me your "lspci -vv" output, the whole /proc/ioports and
> /proc/iomem, and your dmesg log?  And maybe your pcmcia_socket
> available_resources_io and available_resources_mem for good measure.
>

Sure.

lspci:
00:00.0 Host bridge: ALi Corporation M1644/M1644T Northbridge+Trident (rev 01)
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort+ >SERR- <PERR+
	Latency: 0
	Region 0: Memory at f0000000 (32-bit, prefetchable) [size=64M]
	Capabilities: [b0] AGP version 2.0
		Status: RQ=28 Iso- ArqSz=0 Cal=0 SBA+ ITACoh- GART64- HTrans- 64bit- FW- 
AGP3- Rate=x1,x2,x4
		Command: RQ=1 ArqSz=0 Cal=0 SBA- AGP- GART64- 64bit- FW- Rate=<none>
	Capabilities: [a4] Power Management version 1
		Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

00:01.0 PCI bridge: ALi Corporation PCI to AGP Controller (prog-if 00 [Normal 
decode])
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap- 66MHz- UDF- FastB2B- ParErr- DEVSEL=slow >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 0
	Bus: primary=00, secondary=01, subordinate=01, sec-latency=0
	Memory behind bridge: f7f00000-fdffffff
	Prefetchable memory behind bridge: 48000000-480fffff
	Secondary status: 66MHz+ FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort+ <SERR- <PERR+
	BridgeCtl: Parity- SERR- NoISA- VGA+ MAbort- >Reset- FastB2B-

00:02.0 USB Controller: ALi Corporation USB 1.1 Controller (rev 03) (prog-if 
10 [OHCI])
	Subsystem: Toshiba America Info Systems Unknown device 0004
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 64 (20000ns max), Cache Line Size: 32 bytes
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at f7eff000 (32-bit, non-prefetchable) [size=4K]
	Capabilities: [60] Power Management version 2
		Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot+,D3cold+)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

00:04.0 IDE interface: ALi Corporation M5229 IDE (rev c3) (prog-if f0)
	Subsystem: Toshiba America Info Systems Unknown device 0004
	Control: I/O+ Mem- BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 64 (500ns min, 1000ns max)
	Interrupt: pin A routed to IRQ 255
	Region 0: [virtual] Memory at 000001f0 (32-bit, non-prefetchable) [disabled] 
[size=8]
	Region 1: [virtual] Memory at 000003f0 (type 3, non-prefetchable) [disabled] 
[size=1]
	Region 2: [virtual] Memory at 00000170 (32-bit, non-prefetchable) [disabled] 
[size=8]
	Region 3: [virtual] Memory at 00000370 (type 3, non-prefetchable) [disabled] 
[size=1]
	Region 4: I/O ports at eff0 [size=16]
	Capabilities: [60] Power Management version 2
		Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

00:06.0 Multimedia audio controller: ALi Corporation M5451 PCI AC-Link 
Controller Audio Device (rev 01)
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR+ <PERR+
	Latency: 64 (500ns min, 6000ns max)
	Interrupt: pin A routed to IRQ 11
	Region 0: I/O ports at ed00 [size=256]
	Region 1: Memory at f7efe000 (32-bit, non-prefetchable) [size=4K]
	Capabilities: [dc] Power Management version 2
		Flags: PMEClk- DSI+ D1+ D2+ AuxCurrent=0mA PME(D0-,D1-,D2+,D3hot+,D3cold+)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

00:07.0 ISA bridge: ALi Corporation M1533/M1535 PCI to ISA Bridge [Aladdin 
IV/V/V+]
	Subsystem: Toshiba America Info Systems Unknown device 0004
	Control: I/O+ Mem+ BusMaster+ SpecCycle+ MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 0
	Capabilities: [a0] Power Management version 1
		Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

00:08.0 Bridge: ALi Corporation M7101 Power Management Controller [PMU]
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O- Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap- 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-

00:0a.0 Ethernet controller: Intel Corporation 82557/8/9 [Ethernet Pro 100] 
(rev 08)
	Subsystem: Toshiba America Info Systems 8255x-based Fast Ethernet
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 64 (2000ns min, 14000ns max), Cache Line Size: 32 bytes
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at f7efd000 (32-bit, non-prefetchable) [size=4K]
	Region 1: I/O ports at eb40 [size=64]
	Region 2: Memory at f7d00000 (32-bit, non-prefetchable) [size=1M]
	Capabilities: [dc] Power Management version 2
		Flags: PMEClk- DSI+ D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
		Status: D0 PME-Enable- DSel=0 DScale=2 PME-

00:10.0 CardBus bridge: Texas Instruments PCI1410 PC card Cardbus Controller 
(rev 01)
	Subsystem: Lucent Technologies Unknown device ab01
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 168, Cache Line Size: 32 bytes
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at 48100000 (32-bit, non-prefetchable) [size=4K]
	Bus: primary=00, secondary=02, subordinate=05, sec-latency=176
	Memory window 0: 30000000-33fff000 (prefetchable)
	Memory window 1: 34000000-37fff000
	I/O window 0: 00001000-000010ff
	I/O window 1: 00001400-000014ff
	BridgeCtl: Parity- SERR- ISA- VGA- MAbort- >Reset+ 16bInt- PostWrite+
	16-bit legacy interface ports at 0001

00:11.0 CardBus bridge: Toshiba America Info Systems ToPIC100 PCI to Cardbus 
Bridge with ZV Support (rev 32)
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=slow >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 168
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at 48101000 (32-bit, non-prefetchable) [size=4K]
	Bus: primary=00, secondary=06, subordinate=09, sec-latency=0
	Memory window 0: 38000000-3bfff000 (prefetchable)
	Memory window 1: 3c000000-3ffff000
	I/O window 0: 00001800-000018ff
	I/O window 1: 00001c00-00001cff
	BridgeCtl: Parity- SERR- ISA- VGA- MAbort- >Reset- 16bInt+ PostWrite+
	16-bit legacy interface ports at 0001

00:11.1 CardBus bridge: Toshiba America Info Systems ToPIC100 PCI to Cardbus 
Bridge with ZV Support (rev 32)
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=slow >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 168
	Interrupt: pin B routed to IRQ 11
	Region 0: Memory at 48102000 (32-bit, non-prefetchable) [size=4K]
	Bus: primary=00, secondary=0a, subordinate=0d, sec-latency=0
	Memory window 0: 40000000-43fff000 (prefetchable)
	Memory window 1: 44000000-47fff000
	I/O window 0: 00002000-000020ff
	I/O window 1: 00002400-000024ff
	BridgeCtl: Parity- SERR- ISA- VGA- MAbort- >Reset- 16bInt+ PostWrite+
	16-bit legacy interface ports at 0001

00:12.0 System peripheral: Toshiba America Info Systems SD TypA Controller 
(rev 03)
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O- Mem+ BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at f7cffe00 (32-bit, non-prefetchable) [size=512]
	Capabilities: [80] Power Management version 2
		Flags: PMEClk- DSI- D1+ D2+ AuxCurrent=0mA PME(D0+,D1+,D2+,D3hot+,D3cold+)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-

01:00.0 VGA compatible controller: Trident Microsystems CyberBlade XPAi1 (rev 
82) (prog-if 00 [VGA])
	Subsystem: Toshiba America Info Systems Unknown device 0001
	Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- 
SERR- FastB2B-
	Status: Cap+ 66MHz+ UDF- FastB2B- ParErr- DEVSEL=medium >TAbort- <TAbort- 
<MAbort- >SERR- <PERR-
	Latency: 8
	Interrupt: pin A routed to IRQ 11
	Region 0: Memory at fc000000 (32-bit, non-prefetchable) [size=32M]
	Region 1: Memory at fbc00000 (32-bit, non-prefetchable) [size=4M]
	Region 2: Memory at f8000000 (32-bit, non-prefetchable) [size=32M]
	Region 3: Memory at f7ff8000 (32-bit, non-prefetchable) [size=32K]
	[virtual] Expansion ROM at 48000000 [disabled] [size=64K]
	Capabilities: [80] AGP version 2.0
		Status: RQ=33 Iso- ArqSz=0 Cal=0 SBA+ ITACoh- GART64- HTrans- 64bit- FW- 
AGP3- Rate=x1,x2,x4
		Command: RQ=1 ArqSz=0 Cal=0 SBA- AGP- GART64- 64bit- FW- Rate=<none>
	Capabilities: [90] Power Management version 2
		Flags: PMEClk- DSI+ D1+ D2+ AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
		Status: D0 PME-Enable- DSel=0 DScale=0 PME-


/proc/ioports:

0000-001f : dma1
0020-0021 : pic1
0040-0043 : timer0
0050-0053 : timer1
0060-006f : keyboard
0070-0077 : rtc
0080-008f : dma page reg
00a0-00a1 : pic2
00c0-00df : dma2
00f0-00ff : fpu
0100-013f : pcmcia_socket0
0170-0177 : 0000:00:04.0
  0170-0177 : libata
01f0-01f7 : 0000:00:04.0
  01f0-01f7 : libata
0376-0376 : 0000:00:04.0
  0376-0376 : libata
03c0-03df : vesafb
03f6-03f6 : 0000:00:04.0
  03f6-03f6 : libata
03f8-03ff : serial
0cf8-0cff : PCI conf1
1000-10ff : PCI CardBus #02
1400-14ff : PCI CardBus #02
1800-18ff : PCI CardBus #06
1c00-1cff : PCI CardBus #06
2000-20ff : PCI CardBus #0a
2400-24ff : PCI CardBus #0a
eb40-eb7f : 0000:00:0a.0
  eb40-eb7f : e100
ed00-edff : 0000:00:06.0
  ed00-edff : ALI 5451
ee00-ee3f : 0000:00:08.0
  ee00-ee03 : ACPI PM1a_EVT_BLK
  ee04-ee05 : ACPI PM1a_CNT_BLK
  ee08-ee0b : ACPI PM_TMR
  ee10-ee15 : ACPI CPU throttle
  ee18-ee27 : ACPI GPE0_BLK
  ee34-ee34 : ACPI PM2_CNT_BLK
ef00-ef1f : 0000:00:08.0
  ef00-ef1f : ali1535_smbus
eff0-efff : 0000:00:04.0
  eff0-efff : libata

/proc/iomem:

00000000-0009fbff : System RAM
0009fc00-0009ffff : reserved
000a0000-000bffff : Video RAM area
000c0000-000cbfff : Video ROM
000e0000-000eedff : reserved
000eee00-000eefff : ACPI Non-volatile Storage
000f0000-000fffff : System ROM
00100000-1ef5ffff : System RAM
  00100000-002d1409 : Kernel code
  002d140a-003a2c63 : Kernel data
1ef60000-1ef6ffff : ACPI Tables
1ef70000-1fffffff : reserved
30000000-33ffffff : PCI CardBus #02
34000000-37ffffff : PCI CardBus #02
38000000-3bffffff : PCI CardBus #06
3c000000-3fffffff : PCI CardBus #06
40000000-43ffffff : PCI CardBus #0a
44000000-47ffffff : PCI CardBus #0a
48000000-480fffff : PCI Bus #01
  48000000-4800ffff : 0000:01:00.0
48100000-48100fff : 0000:00:10.0
  48100000-48100fff : yenta_socket
48101000-48101fff : 0000:00:11.0
  48101000-48101fff : yenta_socket
48102000-48102fff : 0000:00:11.1
  48102000-48102fff : yenta_socket
60000000-60000fff : pcmcia_socket0
f0000000-f3ffffff : 0000:00:00.0
f7cffe00-f7cfffff : 0000:00:12.0
f7d00000-f7dfffff : 0000:00:0a.0
  f7d00000-f7dfffff : e100
f7efd000-f7efdfff : 0000:00:0a.0
  f7efd000-f7efdfff : e100
f7efe000-f7efefff : 0000:00:06.0
  f7efe000-f7efefff : ALI 5451
f7eff000-f7efffff : 0000:00:02.0
  f7eff000-f7efffff : ohci_hcd
f7f00000-fdffffff : PCI Bus #01
  f7ff8000-f7ffffff : 0000:01:00.0
  f8000000-f9ffffff : 0000:01:00.0
  fbc00000-fbffffff : 0000:01:00.0
  fc000000-fdffffff : 0000:01:00.0
    fc000000-fcffffff : vesafb
fff80000-ffffffff : reserved

dmesg (I played around with smsc so you will see several attempts):

[    0.000000] Linux version 2.6.22-rc4-2avb (bor@cooker) (gcc version 4.1.2 
20070302 (prerelease) (4.1.2-1mdv2007.1)) #13 Sun Jun 10 21:04:18 MSD 2007
[    0.000000] BIOS-provided physical RAM map:
[    0.000000]  BIOS-e820: 0000000000000000 - 000000000009fc00 (usable)
[    0.000000]  BIOS-e820: 000000000009fc00 - 00000000000a0000 (reserved)
[    0.000000]  BIOS-e820: 00000000000e0000 - 00000000000eee00 (reserved)
[    0.000000]  BIOS-e820: 00000000000eee00 - 00000000000ef000 (ACPI NVS)
[    0.000000]  BIOS-e820: 00000000000ef000 - 0000000000100000 (reserved)
[    0.000000]  BIOS-e820: 0000000000100000 - 000000001ef60000 (usable)
[    0.000000]  BIOS-e820: 000000001ef60000 - 000000001ef70000 (ACPI data)
[    0.000000]  BIOS-e820: 000000001ef70000 - 0000000020000000 (reserved)
[    0.000000]  BIOS-e820: 00000000fff80000 - 0000000100000000 (reserved)
[    0.000000] 495MB LOWMEM available.
[    0.000000] Entering add_active_range(0, 0, 126816) 0 entries of 256 used
[    0.000000] Zone PFN ranges:
[    0.000000]   DMA             0 ->     4096
[    0.000000]   Normal       4096 ->   126816
[    0.000000] early_node_map[1] active PFN ranges
[    0.000000]     0:        0 ->   126816
[    0.000000] On node 0 totalpages: 126816
[    0.000000]   DMA zone: 32 pages used for memmap
[    0.000000]   DMA zone: 0 pages reserved
[    0.000000]   DMA zone: 4064 pages, LIFO batch:0
[    0.000000]   Normal zone: 958 pages used for memmap
[    0.000000]   Normal zone: 121762 pages, LIFO batch:31
[    0.000000] DMI 2.3 present.
[    0.000000] ACPI: RSDP 000F0090, 0014 (r0 TOSHIB)
[    0.000000] ACPI: RSDT 1EF60000, 0028 (r1 TOSHIB 750        970814 TASM  
4010000)
[    0.000000] ACPI: FACP 1EF60054, 0084 (r2 TOSHIB 750        970814 TASM  
4010000)
[    0.000000] ACPI: DSDT 1EF600D8, 68DA (r1 TOSHIB 4000     20020417 MSFT  
100000A)
[    0.000000] ACPI: FACS 000EEE00, 0040
[    0.000000] ACPI: PM-Timer IO Port: 0xee08
[    0.000000] Allocating PCI resources starting at 30000000 (gap: 
20000000:dff80000)
[    0.000000] swsusp: Registered nosave memory region: 000000000009f000 - 
00000000000a0000
[    0.000000] swsusp: Registered nosave memory region: 00000000000a0000 - 
00000000000e0000
[    0.000000] swsusp: Registered nosave memory region: 00000000000e0000 - 
00000000000ee000
[    0.000000] swsusp: Registered nosave memory region: 00000000000ee000 - 
00000000000ef000
[    0.000000] swsusp: Registered nosave memory region: 00000000000ef000 - 
0000000000100000
[    0.000000] Built 1 zonelists.  Total pages: 125826
[    0.000000] Kernel command line: BOOT_IMAGE=2.6.22-rc4-kbd-2avb 
root=LABEL=/ resume=/dev/sda1 vga=791
[    0.000000] Enabling fast FPU save and restore... done.
[    0.000000] Enabling unmasked SIMD FPU exception support... done.
[    0.000000] Initializing CPU#0
[    0.000000] PID hash table entries: 2048 (order: 11, 8192 bytes)
[    0.000000] Detected 747.678 MHz processor.
[   62.470759] Console: colour dummy device 80x25
[   62.471005] Lock dependency validator: Copyright (c) 2006 Red Hat, Inc., 
Ingo Molnar
[   62.471023] ... MAX_LOCKDEP_SUBCLASSES:    8
[   62.471033] ... MAX_LOCK_DEPTH:          30
[   62.471043] ... MAX_LOCKDEP_KEYS:        2048
[   62.471053] ... CLASSHASH_SIZE:           1024
[   62.471063] ... MAX_LOCKDEP_ENTRIES:     8192
[   62.471073] ... MAX_LOCKDEP_CHAINS:      16384
[   62.471083] ... CHAINHASH_SIZE:          8192
[   62.471093]  memory used by lock dependency info: 992 kB
[   62.471104]  per task-struct memory footprint: 1200 bytes
[   62.471116] ------------------------
[   62.471125] | Locking API testsuite:
[   
62.471135] ----------------------------------------------------------------------------
[   62.471151]                                  | spin |wlock |rlock |mutex | 
wsem | rsem |
[   
62.471167]   --------------------------------------------------------------------------
[   62.471213]                      A-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.473811]                  A-B-B-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.475664]              A-B-B-C-C-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.477554]              A-B-C-A-B-C deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.479448]          A-B-B-C-C-D-D-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.481400]          A-B-C-D-B-D-D-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.483358]          A-B-C-D-B-C-D-A deadlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.485325]                     double unlock:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.487123]                   initialize held:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   62.488913]                  bad unlock order:  ok  |  ok  |  ok  |  ok  |  
ok  |  ok  |
[   
62.490761]   --------------------------------------------------------------------------
[   62.490777]               recursive read-lock:             |  
ok  |             |  ok  |
[   62.491390]            recursive read-lock #2:             |  
ok  |             |  ok  |
[   62.492001]             mixed read-write-lock:             |  
ok  |             |  ok  |
[   62.492618]             mixed write-read-lock:             |  
ok  |             |  ok  |
[   
62.493235]   --------------------------------------------------------------------------
[   62.493251]      hard-irqs-on + irq-safe-A/12:  ok  |  ok  |  ok  |
[   62.494162]      soft-irqs-on + irq-safe-A/12:  ok  |  ok  |  ok  |
[   62.495081]      hard-irqs-on + irq-safe-A/21:  ok  |  ok  |  ok  |
[   62.495984]      soft-irqs-on + irq-safe-A/21:  ok  |  ok  |  ok  |
[   62.496891]        sirq-safe-A => hirqs-on/12:  ok  |  ok  |  ok  |
[   62.497798]        sirq-safe-A => hirqs-on/21:  ok  |  ok  |  ok  |
[   62.498705]          hard-safe-A + irqs-on/12:  ok  |  ok  |  ok  |
[   62.499612]          soft-safe-A + irqs-on/12:  ok  |  ok  |  ok  |
[   62.500524]          hard-safe-A + irqs-on/21:  ok  |  ok  |  ok  |
[   62.501432]          soft-safe-A + irqs-on/21:  ok  |  ok  |  ok  |
[   62.502339]     hard-safe-A + unsafe-B #1/123:  ok  |  ok  |  ok  |
[   62.503273]     soft-safe-A + unsafe-B #1/123:  ok  |  ok  |  ok  |
[   62.504207]     hard-safe-A + unsafe-B #1/132:  ok  |  ok  |  ok  |
[   62.505137]     soft-safe-A + unsafe-B #1/132:  ok  |  ok  |  ok  |
[   62.506067]     hard-safe-A + unsafe-B #1/213:  ok  |  ok  |  ok  |
[   62.506997]     soft-safe-A + unsafe-B #1/213:  ok  |  ok  |  ok  |
[   62.507929]     hard-safe-A + unsafe-B #1/231:  ok  |  ok  |  ok  |
[   62.508855]     soft-safe-A + unsafe-B #1/231:  ok  |  ok  |  ok  |
[   62.509782]     hard-safe-A + unsafe-B #1/312:  ok  |  ok  |  ok  |
[   62.510695]     soft-safe-A + unsafe-B #1/312:  ok  |  ok  |  ok  |
[   62.511611]     hard-safe-A + unsafe-B #1/321:  ok  |  ok  |  ok  |
[   62.512538]     soft-safe-A + unsafe-B #1/321:  ok  |  ok  |  ok  |
[   62.513465]     hard-safe-A + unsafe-B #2/123:  ok  |  ok  |  ok  |
[   62.514395]     soft-safe-A + unsafe-B #2/123:  ok  |  ok  |  ok  |
[   62.515330]     hard-safe-A + unsafe-B #2/132:  ok  |  ok  |  ok  |
[   62.516258]     soft-safe-A + unsafe-B #2/132:  ok  |  ok  |  ok  |
[   62.517192]     hard-safe-A + unsafe-B #2/213:  ok  |  ok  |  ok  |
[   62.518121]     soft-safe-A + unsafe-B #2/213:  ok  |  ok  |  ok  |
[   62.519053]     hard-safe-A + unsafe-B #2/231:  ok  |  ok  |  ok  |
[   62.519978]     soft-safe-A + unsafe-B #2/231:  ok  |  ok  |  ok  |
[   62.520907]     hard-safe-A + unsafe-B #2/312:  ok  |  ok  |  ok  |
[   62.521834]     soft-safe-A + unsafe-B #2/312:  ok  |  ok  |  ok  |
[   62.522768]     hard-safe-A + unsafe-B #2/321:  ok  |  ok  |  ok  |
[   62.523696]     soft-safe-A + unsafe-B #2/321:  ok  |  ok  |  ok  |
[   62.524626]       hard-irq lock-inversion/123:  ok  |  ok  |  ok  |
[   62.525557]       soft-irq lock-inversion/123:  ok  |  ok  |  ok  |
[   62.526493]       hard-irq lock-inversion/132:  ok  |  ok  |  ok  |
[   62.527420]       soft-irq lock-inversion/132:  ok  |  ok  |  ok  |
[   62.528355]       hard-irq lock-inversion/213:  ok  |  ok  |  ok  |
[   62.529287]       soft-irq lock-inversion/213:  ok  |  ok  |  ok  |
[   62.530223]       hard-irq lock-inversion/231:  ok  |  ok  |  ok  |
[   62.531149]       soft-irq lock-inversion/231:  ok  |  ok  |  ok  |
[   62.532082]       hard-irq lock-inversion/312:  ok  |  ok  |  ok  |
[   62.533011]       soft-irq lock-inversion/312:  ok  |  ok  |  ok  |
[   62.533948]       hard-irq lock-inversion/321:  ok  |  ok  |  ok  |
[   62.534875]       soft-irq lock-inversion/321:  ok  |  ok  |  ok  |
[   62.535806]       hard-irq read-recursion/123:  ok  |
[   62.536124]       soft-irq read-recursion/123:  ok  |
[   62.536444]       hard-irq read-recursion/132:  ok  |
[   62.536762]       soft-irq read-recursion/132:  ok  |
[   62.537082]       hard-irq read-recursion/213:  ok  |
[   62.537400]       soft-irq read-recursion/213:  ok  |
[   62.537719]       hard-irq read-recursion/231:  ok  |
[   62.538036]       soft-irq read-recursion/231:  ok  |
[   62.538354]       hard-irq read-recursion/312:  ok  |
[   62.538671]       soft-irq read-recursion/312:  ok  |
[   62.538990]       hard-irq read-recursion/321:  ok  |
[   62.539308]       soft-irq read-recursion/321:  ok  |
[   62.539629] -------------------------------------------------------
[   62.539643] Good, all 218 testcases passed! |
[   62.539653] ---------------------------------
[   62.541298] Dentry cache hash table entries: 65536 (order: 6, 262144 bytes)
[   62.544144] Inode-cache hash table entries: 32768 (order: 5, 131072 bytes)
[   62.648193] Memory: 495900k/507264k available (1861k kernel code, 10784k 
reserved, 838k data, 184k init, 0k highmem)
[   62.648272] virtual kernel memory layout:
[   62.648277]     fixmap  : 0xffff8000 - 0xfffff000   (  28 kB)
[   62.648282]     vmalloc : 0xdf800000 - 0xffff6000   ( 519 MB)
[   62.648286]     lowmem  : 0xc0000000 - 0xdef60000   ( 495 MB)
[   62.648290]       .init : 0xc03a6000 - 0xc03d4000   ( 184 kB)
[   62.648294]       .data : 0xc02d140a - 0xc03a2c64   ( 838 kB)
[   62.648298]       .text : 0xc0100000 - 0xc02d140a   (1861 kB)
[   62.648344] Checking if this processor honours the WP bit even in 
supervisor mode... Ok.
[   62.732548] Calibrating delay using timer specific routine.. 1497.68 
BogoMIPS (lpj=2495503)
[   62.732851] Mount-cache hash table entries: 512
[   62.733789] CPU: After generic identify, caps: 0383f9ff 00000000 00000000 
00000000 00000000 00000000 00000000
[   62.733825] CPU: L1 I cache: 16K, L1 D cache: 16K
[   62.733844] CPU: L2 cache: 256K
[   62.733861] CPU: After all inits, caps: 0383f9ff 00000000 00000000 00000040 
00000000 00000000 00000000
[   62.733898] Compat vDSO mapped to ffffe000.
[   62.733953] CPU: Intel Pentium III (Coppermine) stepping 0a
[   62.733982] Checking 'hlt' instruction... OK.
[   62.746236] ACPI: Core revision 20070126
[   62.766712] Parsing all Control Methods:
[   62.767183] Table [DSDT](id 0001) - 683 Objects with 60 Devices 195 Methods 
10 Regions
[   62.767216]  tbxface-0587 [02] tb_load_namespace     : ACPI Tables 
successfully acquired
[   62.767245] ACPI: setting ELCR to 0200 (from 0a00)
[   62.767811] evxfevnt-0091 [02] enable                : Transition to ACPI 
mode successful
[   62.769429] NET: Registered protocol family 16
[   62.770649] ACPI: bus type pci registered
[   62.771700] PCI: PCI BIOS revision 2.10 entry at 0xfe5ae, last bus=5
[   62.771716] PCI: Using configuration type 1
[   62.771726] Setting up standard PCI resources
[   62.780975] evgpeblk-0952 [04] ev_create_gpe_block   : GPE 00 to 3F [_GPE] 
8 regs on int 0x9
[   62.784458] evgpeblk-1048 [03] ev_initialize_gpe_bloc: Found 3 Wake, 
Enabled 0 Runtime GPEs in this block
[   62.785892] Completing Region/Field/Buffer/Package 
initialization:........................................
[   62.790995] Initialized 8/10 Regions 0/0 Fields 16/16 Buffers 16/27 
Packages (692 nodes)
[   62.791019] Initializing Device/Processor/Thermal objects by executing _INI 
methods:.
[   62.795837] Executed 1 _INI methods requiring 0 _STA executions (examined 
64 objects)
[   62.795947] ACPI: Interpreter enabled
[   62.795963] ACPI: (supports S0 S3 S4 S5)
[   62.796153] ACPI: Using PIC for interrupt routing
[   62.839902] ACPI: PCI Root Bridge [PCI0] (0000:00)
[   62.840045] PCI: Probing PCI hardware (bus 00)
[   62.841201] PCI quirk: region ee00-ee3f claimed by ali7101 ACPI
[   62.841225] PCI quirk: region ef00-ef1f claimed by ali7101 SMB
[   62.842978] ACPI: PCI Interrupt Routing Table [\_SB_.PCI0._PRT]
[   62.843697] ACPI: PCI Interrupt Routing Table [\_SB_.PCI0.PCI1._PRT]
[   62.882557] ACPI: PCI Interrupt Link [LNKA] (IRQs 3 4 5 6 7 10 *11)
[   62.883832] ACPI: PCI Interrupt Link [LNKB] (IRQs 3 4 5 6 7 10 *11)
[   62.885042] ACPI: PCI Interrupt Link [LNKC] (IRQs 3 4 5 6 7 10 *11)
[   62.886305] ACPI: PCI Interrupt Link [LNKD] (IRQs 3 4 5 6 7 10 *11)
[   62.887525] ACPI: PCI Interrupt Link [LNKG] (IRQs 3 4 5 6 7 10 *11)
[   62.888737] ACPI: PCI Interrupt Link [LNKH] (IRQs 3 4 5 6 7 10 *11)
[   62.890370] ACPI: Power Resource [PFAN] (off)
[   62.890436] Linux Plug and Play Support v0.97 (c) Adam Belay
[   62.890562] pnp: PnP ACPI init
[   62.890691] ACPI: bus type pnp registered
[   62.954051] pnp: PnP ACPI: found 12 devices
[   62.954101] ACPI: ACPI bus type pnp unregistered
[   62.954430] PCI: Using ACPI for IRQ routing
[   62.954448] PCI: If a device doesn't work, try "pci=routeirq".  If it 
helps, post a report
[   62.965460] pnp: 00:00: iomem range 0x0-0x9ffff could not be reserved
[   62.965489] pnp: 00:00: iomem range 0xe0000-0xeffff could not be reserved
[   62.965506] pnp: 00:00: iomem range 0xf0000-0xfffff could not be reserved
[   62.965524] pnp: 00:00: iomem range 0x100000-0x1ef5ffff could not be 
reserved
[   62.965785] Time: tsc clocksource has been installed.
[   62.997630] PCI: Bridge: 0000:00:01.0
[   62.997661]   IO window: disabled.
[   62.997682]   MEM window: f7f00000-fdffffff
[   62.997699]   PREFETCH window: 48000000-480fffff
[   62.997720] PCI: Bus 2, cardbus bridge: 0000:00:10.0
[   62.997733]   IO window: 00001000-000010ff
[   62.997749]   IO window: 00001400-000014ff
[   62.997765]   PREFETCH window: 30000000-33ffffff
[   62.997781]   MEM window: 34000000-37ffffff
[   62.997797] PCI: Bus 6, cardbus bridge: 0000:00:11.0
[   62.997809]   IO window: 00001800-000018ff
[   62.997824]   IO window: 00001c00-00001cff
[   62.997841]   PREFETCH window: 38000000-3bffffff
[   62.997857]   MEM window: 3c000000-3fffffff
[   62.997874] PCI: Bus 10, cardbus bridge: 0000:00:11.1
[   62.997885]   IO window: 00002000-000020ff
[   62.997901]   IO window: 00002400-000024ff
[   62.997917]   PREFETCH window: 40000000-43ffffff
[   62.997934]   MEM window: 44000000-47ffffff
[   62.997972] PCI: Setting latency timer of device 0000:00:01.0 to 64
[   62.998018] PCI: Enabling device 0000:00:10.0 (0000 -> 0003)
[   63.000663] ACPI: PCI Interrupt Link [LNKC] enabled at IRQ 11
[   63.000694] PCI: setting IRQ 11 as level-triggered
[   63.000703] ACPI: PCI Interrupt 0000:00:10.0[A] -> Link [LNKC] -> GSI 11 
(level, low) -> IRQ 11
[   63.000762] PCI: Enabling device 0000:00:11.0 (0000 -> 0003)
[   63.002889] ACPI: PCI Interrupt Link [LNKA] enabled at IRQ 11
[   63.002906] ACPI: PCI Interrupt 0000:00:11.0[A] -> Link [LNKA] -> GSI 11 
(level, low) -> IRQ 11
[   63.002961] PCI: Enabling device 0000:00:11.1 (0000 -> 0003)
[   63.005055] ACPI: PCI Interrupt Link [LNKB] enabled at IRQ 11
[   63.005071] ACPI: PCI Interrupt 0000:00:11.1[B] -> Link [LNKB] -> GSI 11 
(level, low) -> IRQ 11
[   63.005213] NET: Registered protocol family 2
[   63.036018] IP route cache hash table entries: 4096 (order: 2, 16384 bytes)
[   63.036544] TCP established hash table entries: 16384 (order: 7, 720896 
bytes)
[   63.043090] TCP bind hash table entries: 16384 (order: 7, 720896 bytes)
[   63.049915] TCP: Hash tables configured (established 16384 bind 16384)
[   63.050082] TCP reno registered
[   63.059914] checking if image is initramfs... it is
[   63.277188] Freeing initrd memory: 1171k freed
[   63.279813] audit: initializing netlink socket (disabled)
[   63.279958] audit(1181566616.319:1): initialized
[   63.281313] io scheduler noop registered
[   63.281345] io scheduler anticipatory registered
[   63.281357] io scheduler deadline registered
[   63.281416] io scheduler cfq registered (default)
[   63.281501] Activating ISA DMA hang workarounds.
[   63.281548] Boot video device is 0000:01:00.0
[   63.282463] vesafb: framebuffer at 0xfc000000, mapped to 0xdf880000, using 
3072k, total 16384k
[   63.282499] vesafb: mode is 1024x768x16, linelength=2048, pages=9
[   63.282513] vesafb: protected mode interface info at c000:775e
[   63.282527] vesafb: pmi: set display start = c00c777f, set palette = 
c00c77e2
[   63.282539] vesafb: scrolling: redraw
[   63.282553] vesafb: Truecolor: size=0:5:6:5, shift=0:11:5:0
[   63.353029] Console: switching to colour frame buffer device 128x48
[   63.416464] fb0: VESA VGA frame buffer device
[   63.499013] Switched to high resolution mode on CPU 0
[   63.720982] Real Time Clock Driver v1.12ac
[   63.726162] RAMDISK driver initialized: 16 RAM disks of 32000K size 1024 
blocksize
[   63.728972] PNP: PS/2 Controller [PNP0303:KBC,PNP0f13:PS2M] at 0x60,0x64 
irq 1,12
[   63.734870] serio: i8042 KBD port at 0x60,0x64 irq 1
[   63.735602] serio: i8042 AUX port at 0x60,0x64 irq 12
[   63.737242] mice: PS/2 mouse device common for all mice
[   63.738753] NET: Registered protocol family 1
[   63.739484] Using IPI Shortcut mode
[   63.741458] BIOS EDD facility v0.16 2004-Jun-25, 1 devices found
[   63.743207] Freeing unused kernel memory: 184k freed
[   63.744180] Write protecting the kernel text: 1864k
[   63.744842] Write protecting the kernel read-only data: 684k
[   63.778506] SCSI subsystem initialized
[   63.795649] input: AT Translated Set 2 keyboard as /class/input/input0
[   63.857915] libata version 2.21 loaded.
[   63.890575] ACPI: Unable to derive IRQ for device 0000:00:04.0
[   63.915820] ACPI: PCI Interrupt 0000:00:04.0[A]: no GSI
[   63.941192] scsi0 : pata_ali
[   63.966093] scsi1 : pata_ali
[   63.990183] ata1: PATA max UDMA/100 cmd 0x000101f0 ctl 0x000103f6 bmdma 
0x0001eff0 irq 14
[   64.014754] ata2: PATA max UDMA/100 cmd 0x00010170 ctl 0x00010376 bmdma 
0x0001eff8 irq 15
[   64.199340] ata1.00: ata_hpa_resize 1: sectors = 39070080, hpa_sectors = 
39070080
[   64.223901] ata1.00: ATA-5: IC25N020ATDA04-0, DA3OA70A, max UDMA/100
[   64.248487] ata1.00: 39070080 sectors, multi 0: LBA 
[   64.272985] ata1.00: limited to UDMA/33 due to 40-wire cable
[   64.309244] ata1.00: ata_hpa_resize 1: sectors = 39070080, hpa_sectors = 
39070080
[   64.334495] ata1.00: configured for UDMA/33
[   64.688923] ata2.00: ATAPI, max UDMA/33
[   64.895513] ata2.00: configured for UDMA/33
[   64.921423] scsi 0:0:0:0: Direct-Access     ATA      IC25N020ATDA04-0 DA3O 
PQ: 0 ANSI: 5
[   64.949936] scsi 1:0:0:0: CD-ROM            TOSHIBA  DVD-ROM SD-C2502 1313 
PQ: 0 ANSI: 5
[   65.009344] sd 0:0:0:0: [sda] 39070080 512-byte hardware sectors (20004 MB)
[   65.035141] sd 0:0:0:0: [sda] Write Protect is off
[   65.060285] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[   65.060389] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, 
doesn't support DPO or FUA
[   65.086647] sd 0:0:0:0: [sda] 39070080 512-byte hardware sectors (20004 MB)
[   65.112551] sd 0:0:0:0: [sda] Write Protect is off
[   65.137989] sd 0:0:0:0: [sda] Mode Sense: 00 3a 00 00
[   65.138122] sd 0:0:0:0: [sda] Write cache: enabled, read cache: enabled, 
doesn't support DPO or FUA
[   65.164116]  sda: sda1 sda2
[   65.207818] sd 0:0:0:0: [sda] Attached SCSI disk
[   65.584173] swsusp: Marking nosave pages: 000000000009f000 - 
0000000000100000
[   65.584199] swsusp: Basic memory bitmaps created
[   65.620553] swsusp: Basic memory bitmaps freed
[   65.749800] ReiserFS: sda2: found reiserfs format "3.6" with standard 
journal
[   65.775054] ReiserFS: sda2: using ordered data mode
[   65.817514] ReiserFS: sda2: journal params: device sda2, size 8192, journal 
first block 18, max trans len 1024, max batch 900, max commit age 30, max 
trans age 30
[   65.877779] ReiserFS: sda2: checking transaction log (sda2)
[   65.933489] ReiserFS: sda2: Using r5 hash to sort names
[   74.272441] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   74.272528] scsi 1:0:0:0: Attached scsi generic sg1 type 5
[   74.490146] Linux agpgart interface v0.102 (c) Dave Jones
[   74.542589] usbcore: registered new interface driver usbfs
[   74.542854] usbcore: registered new interface driver hub
[   74.543072] usbcore: registered new device driver usb
[   74.711847] agpgart: Detected ALi M1644 chipset
[   74.721726] agpgart: AGP aperture is 64M @ 0xf0000000
[   74.772905] ohci_hcd: 2006 August 04 USB 1.1 'Open' Host Controller (OHCI) 
Driver
[   74.775874] ACPI: PCI Interrupt Link [LNKG] enabled at IRQ 11
[   74.775892] ACPI: PCI Interrupt 0000:00:02.0[A] -> Link [LNKG] -> GSI 11 
(level, low) -> IRQ 11
[   74.775956] ohci_hcd 0000:00:02.0: OHCI Host Controller
[   74.777721] ohci_hcd 0000:00:02.0: new USB bus registered, assigned bus 
number 1
[   74.777815] ohci_hcd 0000:00:02.0: irq 11, io mem 0xf7eff000
[   74.831804] usb usb1: configuration #1 chosen from 1 choice
[   74.832118] hub 1-0:1.0: USB hub found
[   74.832217] hub 1-0:1.0: 3 ports detected
[   74.955768] Yenta: CardBus bridge found at 0000:00:10.0 [12a3:ab01]
[   74.955818] Yenta: Enabling burst memory read transactions
[   74.955830] Yenta: Using CSCINT to route CSC interrupts to PCI
[   74.955836] Yenta: Routing CardBus interrupts to PCI
[   74.955848] Yenta TI: socket 0000:00:10.0, mfunc 0x01000002, devctl 0x60
[   74.977822] e100: Intel(R) PRO/100 Network Driver, 3.5.17-k4-NAPI
[   74.977838] e100: Copyright(c) 1999-2006 Intel Corporation
[   75.063210] sr0: scsi3-mmc drive: 24x/24x cd/rw xa/form2 cdda tray
[   75.063234] Uniform CD-ROM driver Revision: 3.20
[   75.063700] sr 1:0:0:0: Attached scsi CD-ROM sr0
[   75.185635] Yenta: ISA IRQ mask 0x0000, PCI irq 11
[   75.185652] Socket status: 30000011
[   75.186622] Yenta: CardBus bridge found at 0000:00:11.0 [1179:0001]
[   75.315688] Yenta: ISA IRQ mask 0x04b8, PCI irq 11
[   75.315703] Socket status: 30000007
[   75.316398] Yenta: CardBus bridge found at 0000:00:11.1 [1179:0001]
[   75.442242] Yenta: ISA IRQ mask 0x04b8, PCI irq 11
[   75.442259] Socket status: 30000007
[   75.448429] ACPI: PCI Interrupt Link [LNKD] enabled at IRQ 11
[   75.448457] ACPI: PCI Interrupt 0000:00:0a.0[A] -> Link [LNKD] -> GSI 11 
(level, low) -> IRQ 11
[   75.477665] e100: eth0: e100_probe: addr 0xf7efd000, irq 11, MAC addr 
00:00:39:D7:14:A1
[   75.491638] ACPI: PCI Interrupt Link [LNKH] enabled at IRQ 11
[   75.491664] ACPI: PCI Interrupt 0000:00:06.0[A] -> Link [LNKH] -> GSI 11 
(level, low) -> IRQ 11
[   75.563140] Serial: 8250/16550 driver $Revision: 1.90 $ 4 ports, IRQ 
sharing enabled
[   75.715360] 00:09: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
[   75.818143] pccard: PCMCIA card inserted into slot 0
[   76.208122] NET: Registered protocol family 23
[   79.924209] cs: memory probe 0x0c0000-0x0fffff: excluding 0xc0000-0xcbfff 
0xe0000-0xfffff
[   79.927926] cs: memory probe 0x60000000-0x60ffffff: clean.
[   79.939570] cs: memory probe 0xa0000000-0xa0ffffff: clean.
[   79.951819] pcmcia: registering new device pcmcia0.0
[   80.382434] wlags49_h1_cs v7.18 for PCMCIA, 03/31/2004 14:31:00 by Agere 
Systems, http://www.agere.com
[   80.382454] *** Modified for kernel 2.6 by Andrey Borzenkov 
<arvidjaar@mail.ru> $Revision: 39 $
[   80.382463] *** Station Mode (STA) Support: YES
[   80.382469] *** Access Point Mode (AP) Support: YES
[   80.871844] eth1: PRI 31 variant 2 version 9.48
[   80.871913] eth1: NIC 5 variant 2 version 1.02
[   80.875729] eth1: Wireless, io_addr 0x100, irq 11, mac_address 
00:02:2D:26:95:6C
[   81.373545] Toshiba System Managment Mode driver v1.11 26/9/2001
[   81.579468] Non-volatile memory driver v1.2
[   81.641830] input: ImPS/2 Generic Wheel Mouse as /class/input/input1
[   82.480744] ACPI: AC Adapter [ADP1] (off-line)
[   82.503628] ACPI: Battery Slot [BAT1] (battery present)
[   82.503904] ACPI: Battery Slot [BAT2] (battery absent)
[   82.565695] input: Power Button (FF) as /class/input/input2
[   82.696658] ACPI: Power Button (FF) [PWRF]
[   82.723225] input: Lid Switch as /class/input/input3
[   82.812408] ACPI: Lid Switch [LID]
[   82.932730] ACPI: Transitioning device [FAN] to D3
[   82.932747] ACPI: Transitioning device [FAN] to D3
[   82.932762] ACPI: Fan [FAN] (off)
[   82.967034] ACPI: CPU0 (power states: C1[C1] C2[C2])
[   83.033930] ACPI: Thermal Zone [THRM] (39 C)
[   20.443331] Marking TSC unstable due to: possible TSC halt in C2.
[   20.446664] Time: acpi_pm clocksource has been installed.
[   20.449997] toshiba_acpi: Toshiba Laptop ACPI Extras version 0.18
[   20.449997] toshiba_acpi:     HCI method: \_SB_.VALD.GHCI
[   20.486664] ACPI: Video Device [VGA] (multi-head: yes  rom: yes  post: no)
[   20.653331] device-mapper: ioctl: 4.11.0-ioctl (2006-10-12) initialised: 
dm-devel@redhat.com
[   20.849997] Clocksource tsc unstable (delta = -90684000 ns)
[   21.019997] loop: module loaded
[   25.353330] Adding 500432k swap on /dev/sda1.  Priority:-1 extents:1 
across:500432k
[   38.063329] usbcore: registered new interface driver usbhid
[   38.063329] /home/bor/src/linux-git/drivers/hid/usbhid/hid-core.c: v2.6:USB 
HID core driver
[   40.703329] process `syslogd' is using obsolete setsockopt SO_BSDCOMPAT
[   43.983328] Bluetooth: Core ver 2.11
[   43.983328] NET: Registered protocol family 31
[   43.983328] Bluetooth: HCI device and connection manager initialized
[   43.983328] Bluetooth: HCI socket layer initialized
[   44.436662] Bluetooth: L2CAP ver 2.8
[   44.436662] Bluetooth: L2CAP socket layer initialized
[   45.383328] Bluetooth: RFCOMM socket layer initialized
[   45.383328] Bluetooth: RFCOMM TTY layer initialized
[   45.383328] Bluetooth: RFCOMM ver 1.8
[   46.743328] NET: Registered protocol family 17
[   50.486661] eth1: PRI 31 variant 2 version 9.48
[   50.486661] eth1: NIC 5 variant 2 version 1.02
[   51.476661] eth1: PRI 31 variant 2 version 9.48
[   51.476661] eth1: NIC 5 variant 2 version 1.02
[   51.796661] eth1: PRI 31 variant 2 version 9.48
[   51.796661] eth1: NIC 5 variant 2 version 1.02
[ 2932.806373] pccard: card ejected from slot 0
[ 3021.556364] pnp: Device 00:0a activated.
[ 3021.556364] smsc_ircc_present(), addr 0x02e8 - no device found!
[ 3021.556364] PnP probe failed
[ 3021.556364] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
IrDA chip, pre-configuring device.
[ 3021.556364] Activated ALi 1533 ISA bridge port 0x02e8.
[ 3021.556364] Activated ALi 1533 ISA bridge port 0x02f8.
[ 3021.556364] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): 
LPC47N227
[ 3021.556364] smsc_superio_flat(): IrDA not enabled
[ 3021.556364] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, 
mode: 0x02
[ 3021.556364] SMsC IrDA Controller found
[ 3021.556364]  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
[ 3021.559697] No transceiver found. Defaulting to Fast pin select
[ 3044.583028] pnp: Device 00:0a disabled.
[ 3543.909645] pnp: Device 00:0a activated.
[ 3543.909645] printk: 1 messages suppressed.
[ 3543.909645] smsc_ircc_present(), addr 0x0100 - no device found!
[ 3543.909645] PnP probe failed
[ 3543.912978] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
IrDA chip, pre-configuring device.
[ 3543.912978] Activated ALi 1533 ISA bridge port 0x02e8.
[ 3543.912978] Activated ALi 1533 ISA bridge port 0x02f8.
[ 3543.912978] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): 
LPC47N227
[ 3543.912978] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, 
mode: 0x0a
[ 3543.912978] SMsC IrDA Controller found
[ 3543.912978]  IrCC version 2.0, firport 0x2f8, sirport 0x2e8 dma=3, irq=7
[ 3543.912978] No transceiver found. Defaulting to Fast pin select
[ 3543.922978] IrDA: Registered device irda0
[ 3605.166306] pnp: Device 00:0a disabled.
[ 3615.652971] pccard: PCMCIA card inserted into slot 0
[ 3615.652971] pcmcia: registering new device pcmcia0.0
[ 3615.949638] wlags49_h1_cs v7.18 for PCMCIA, 03/31/2004 14:31:00 by Agere 
Systems, http://www.agere.com
[ 3615.949638] *** Modified for kernel 2.6 by Andrey Borzenkov 
<arvidjaar@mail.ru> $Revision: 39 $
[ 3615.949638] *** Station Mode (STA) Support: YES
[ 3615.949638] *** Access Point Mode (AP) Support: YES
[ 3615.996305] eth1: PRI 31 variant 2 version 9.48
[ 3615.996305] eth1: NIC 5 variant 2 version 1.02
[ 3616.456305] eth1: Wireless, io_addr 0x100, irq 11, mac_address 
00:02:2D:26:95:6C
[ 3617.152971] eth1: PRI 31 variant 2 version 9.48
[ 3617.152971] eth1: NIC 5 variant 2 version 1.02
[ 3617.539638] eth1: PRI 31 variant 2 version 9.48
[ 3617.539638] eth1: NIC 5 variant 2 version 1.02
[ 3617.906304] eth1: PRI 31 variant 2 version 9.48
[ 3617.906304] eth1: NIC 5 variant 2 version 1.02

available_resources_io:

0x00000100 - 0x000003af
0x000003e0 - 0x000004ff
0x00000820 - 0x000008ff
0x00000a00 - 0x00000aff
0x00000c00 - 0x00000cf7

available_resources_mem:

0x000cc000 - 0x000dffff
0x60000000 - 0x60ffffff
0xa0000000 - 0xa0ffffff




[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-11 14:04                                 ` Andrey Borzenkov
@ 2007-06-14 21:30                                   ` Bjorn Helgaas
  2007-06-15 13:44                                     ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-14 21:30 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 497 bytes --]

Hi Andrey,

If you have a chance, can you try the attached two patches?  The
smsc-preconfig patch makes the HP nx5000 work, and the smsc-quirk
patch makes the nw8000/nc8000 work, too.

I've heard rumors that Windows does basically the same thing as the
smsc-quirk patch, so I think there's a chance it might make your
Toshiba work as well.

I sent the smsc-preconfig patch to Andrew this morning.  I'm going
to do some more testing other HP laptops before sending him the
smsc-quirk patch.

Bjorn

[-- Attachment #2: smsc-preconfig --]
[-- Type: text/x-diff, Size: 1843 bytes --]

[patch] smsc-ircc2: skip preconfiguration for PNP devices

If we rely on the device resources from PNPBIOS, we also have to
rely on the BIOS to configure any bridges on the way to the device.

Using the PNPBIOS resources but changing the configuration of a
bridge behind the back of the firmware is likely to make things
inconsistent.

This patch addresses part of this regression:
    "no irda0 interface (2.6.21 was OK), smsc does not find chip"
It fixes smsc-ircc2 PNP device detection on HP nx5000 laptops.
Other laptops, including HP nc6000, HP nc8000, HP nw8000, and Toshiba
Portege 4000, still need PNP quirks to make this work.

With "smsc-ircc2.nopnp", we do the legacy device probe, including
manual bridge preconfiguration, as before.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/net/irda/smsc-ircc2.c
===================================================================
--- w.orig/drivers/net/irda/smsc-ircc2.c	2007-06-06 15:45:14.000000000 -0600
+++ w/drivers/net/irda/smsc-ircc2.c	2007-06-06 15:50:40.000000000 -0600
@@ -416,6 +416,13 @@
 {
 	int ret = 0;
 
+#ifdef CONFIG_PCI
+	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir, ircc_dma, ircc_irq) < 0) {
+		/* Ignore errors from preconfiguration */
+		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
+	}
+#endif
+
 	if (ircc_fir > 0 && ircc_sir > 0) {
 		IRDA_MESSAGE(" Overriding FIR address 0x%04x\n", ircc_fir);
 		IRDA_MESSAGE(" Overriding SIR address 0x%04x\n", ircc_sir);
@@ -459,13 +466,6 @@
 		return ret;
 	}
 
-#ifdef CONFIG_PCI
-	if (smsc_ircc_preconfigure_subsystems(ircc_cfg, ircc_fir, ircc_sir, ircc_dma, ircc_irq) < 0) {
-		/* Ignore errors from preconfiguration */
-		IRDA_ERROR("%s, Preconfiguration failed !\n", driver_name);
-	}
-#endif
-
 	dev_count = 0;
 
 	if (smsc_nopnp || !pnp_platform_devices ||

[-- Attachment #3: smsc-quirk --]
[-- Type: text/x-diff, Size: 3133 bytes --]

[patch] PNP SMCf010 quirk: auto-config device if BIOS left it broken

Some HP firmware leaves the SMCf010 IRDA device incompletely configured,
or reports the wrong resources in _CRS.  As a workaround, when we find
such a device, try to auto-configure the device.

This ignores the _CRS data, picks a config from _PRS, and runs _SRS to
configure the device.  This makes smsc-ircc2 work correctly with PNP
resources on HP nx5000 and nc8000/nw8000 system.

I think Windows does something like this by default for all devices,
so we might want to consider doing the same thing in Linux.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/pnp/quirks.c
===================================================================
--- w.orig/drivers/pnp/quirks.c	2007-06-14 15:08:45.000000000 -0600
+++ w/drivers/pnp/quirks.c	2007-06-14 15:09:56.000000000 -0600
@@ -107,31 +107,61 @@
 	return;
 }
 
-static void quirk_smc_enable(struct pnp_dev *dev)
+static int quirk_smc_fir_enabled(struct pnp_dev *dev)
 {
-	unsigned int firbase;
+	unsigned long firbase;
+	u8 bank, high, low, chip;
+
+	if (!pnp_port_valid(dev, 1))
+		return 0;
+
+	firbase = pnp_port_start(dev, 1);
 
-	if (!dev->active || !pnp_port_valid(dev, 1))
+	/* Select register bank 3 */
+	bank = inb(firbase + 7);
+	bank &= 0xf0;
+	bank |= 3;
+	outb(bank, firbase + 7);
+
+	high = inb(firbase + 0);
+	low  = inb(firbase + 1);
+	chip = inb(firbase + 2);
+
+	/* This corresponds to the check in smsc_ircc_present() */
+	if (high == 0x10 && low == 0xb8 && (chip == 0xf1 || chip == 0xf2))
+		return 1;
+
+	return 0;
+}
+
+static void quirk_smc_enable(struct pnp_dev *dev)
+{
+	/*
+	 * If the BIOS left the device disabled, or it is enabled and
+	 * responding correctly, we're in good shape.
+	 */
+	if (!dev->active || quirk_smc_fir_enabled(dev))
 		return;
 
 	/*
-	 * On the HP/Compaq nw8240 (and probably other similar machines),
-	 * there is an SMCF010 device with two I/O port regions:
-	 *
-	 *	0x3e8-0x3ef SIR
-	 *	0x100-0x10f FIR
+	 * Sometimes the BIOS claims the device is enabled, but it reports
+	 * the wrong FIR resources or doesn't properly configure ISA or LPC
+	 * bridges on the way to the device.
 	 *
-	 * _STA reports the device is enabled, but in fact, the BIOS
-	 * neglects to enable the FIR range.  Fortunately, it does fully
-	 * enable the device if we call _SRS.
+	 * HP nc6000 and nc8000/nw8000 laptops have known problems like
+	 * this.  Fortunately, they do fix things up if we auto-configure
+	 * the device using its _PRS and _SRS methods.
 	 */
-	firbase = pnp_port_start(dev, 1);
-	if (inb(firbase + 0x7 /* IRCC_MASTER */) == 0xff) {
-		pnp_err("%s (%s) enabled but not responding, disabling and "
-			"re-enabling", dev->dev.bus_id, pnp_dev_name(dev));
-		pnp_disable_dev(dev);
-		pnp_activate_dev(dev);
-	}
+	dev_err(&dev->dev, "%s device not responding, auto-configuring "
+		"resources\n", dev->id->id);
+
+	pnp_disable_dev(dev);
+	pnp_init_resource_table(&dev->res);
+	pnp_auto_config_dev(dev);
+	pnp_activate_dev(dev);
+
+	if (!quirk_smc_fir_enabled(dev))
+		dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\"\n");
 }
 
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-14 21:30                                   ` Bjorn Helgaas
@ 2007-06-15 13:44                                     ` Andrey Borzenkov
  2007-06-15 15:19                                       ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-15 13:44 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 819 bytes --]

On Friday 15 June 2007, Bjorn Helgaas wrote:
> Hi Andrey,
>
> If you have a chance, can you try the attached two patches?  The
> smsc-preconfig patch makes the HP nx5000 work, and the smsc-quirk
> patch makes the nw8000/nc8000 work, too.
>
> I've heard rumors that Windows does basically the same thing as the
> smsc-quirk patch, so I think there's a chance it might make your
> Toshiba work as well.
>
> I sent the smsc-preconfig patch to Andrew this morning.  I'm going
> to do some more testing other HP laptops before sending him the
> smsc-quirk patch.
>

Does not work, sorry. (Patches were taken from your another mails but I assume 
they are the same). Does not work even if I unload PCMCIA/yenta_socket 
to "free" resources.

I am out of ideas but am ready to test patches if someone has.

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-15 13:44                                     ` Andrey Borzenkov
@ 2007-06-15 15:19                                       ` Bjorn Helgaas
  2007-06-16 16:38                                         ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-15 15:19 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

On Friday 15 June 2007 07:44:41 am Andrey Borzenkov wrote:
> On Friday 15 June 2007, Bjorn Helgaas wrote:
> > Hi Andrey,
> >
> > If you have a chance, can you try the attached two patches?  The
> > smsc-preconfig patch makes the HP nx5000 work, and the smsc-quirk
> > patch makes the nw8000/nc8000 work, too.
> >
> > I've heard rumors that Windows does basically the same thing as the
> > smsc-quirk patch, so I think there's a chance it might make your
> > Toshiba work as well.
> >
> > I sent the smsc-preconfig patch to Andrew this morning.  I'm going
> > to do some more testing other HP laptops before sending him the
> > smsc-quirk patch.
> >
> 
> Does not work, sorry. (Patches were taken from your another mails but I assume 
> they are the same). Does not work even if I unload PCMCIA/yenta_socket 
> to "free" resources.
> 
> I am out of ideas but am ready to test patches if someone has.

Thanks for testing that.  I bought a Portege 4000 so I can work
on this without bothering you.  I'll let you know if I make any
progress on it.

Bjorn




^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-15 15:19                                       ` Bjorn Helgaas
@ 2007-06-16 16:38                                         ` Andrey Borzenkov
  2007-06-19 23:31                                           ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-16 16:38 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 1677 bytes --]

On Friday 15 June 2007, Bjorn Helgaas wrote:
> On Friday 15 June 2007 07:44:41 am Andrey Borzenkov wrote:
> > On Friday 15 June 2007, Bjorn Helgaas wrote:
> > > Hi Andrey,
> > >
> > > If you have a chance, can you try the attached two patches?  The
> > > smsc-preconfig patch makes the HP nx5000 work, and the smsc-quirk
> > > patch makes the nw8000/nc8000 work, too.
> > >
> > > I've heard rumors that Windows does basically the same thing as the
> > > smsc-quirk patch, so I think there's a chance it might make your
> > > Toshiba work as well.
> > >
> > > I sent the smsc-preconfig patch to Andrew this morning.  I'm going
> > > to do some more testing other HP laptops before sending him the
> > > smsc-quirk patch.
> >
> > Does not work, sorry. (Patches were taken from your another mails but I
> > assume they are the same). Does not work even if I unload
> > PCMCIA/yenta_socket to "free" resources.
> >
> > I am out of ideas but am ready to test patches if someone has.
>
> Thanks for testing that.

it appears that quirk is not even applied because PnP tells us device is not 
active:

[  571.118483] pnp: PnP ACPI init
[  571.118611] ACPI: bus type pnp registered
[  571.158828] quirk_smc_enable: active = 0
[  571.182090] pnp: PnP ACPI: found 12 devices

so this patch effectively did not change anything.

well, that's correct so far, it really is not active after system boot. May 
be, quirk should be applied when device is being activated, not when device 
is being enumerated?

> I bought a Portege 4000 so I can work 
> on this without bothering you.  I'll let you know if I make any
> progress on it.
>
> Bjorn



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-16 16:38                                         ` Andrey Borzenkov
@ 2007-06-19 23:31                                           ` Bjorn Helgaas
  2007-06-28  3:56                                             ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-19 23:31 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 1664 bytes --]

On Saturday 16 June 2007 10:38:56 am Andrey Borzenkov wrote:
> it appears that quirk is not even applied because PnP tells us device is not 
> active:
> 
> [  571.118483] pnp: PnP ACPI init
> [  571.118611] ACPI: bus type pnp registered
> [  571.158828] quirk_smc_enable: active = 0
> [  571.182090] pnp: PnP ACPI: found 12 devices

Yup.  That could probably be improved.

_CRS definitely reports SIR and FIR backwards from most platforms.

I can make the device talk by configuring it "by hand," e.g.,

  # cd /sys/bus/pnp/devices/00:0a
  # echo "set io 0x2e8-0x2ef io 0x100-0x107 irq 5 dma 1" > resources
  # echo activate > resources
  # ~/smsc
  smsc_dump: 0x24 0xfe UART1 config
  smsc_dump: 0x25 0xba SIR base (0x2e8)
  smsc_dump: 0x28 0x45 UART IRQ
  smsc_dump: 0x2b 0x20 FIR base (0x100)
  smsc_dump: 0x2c 0x01 FIR DMA
  smsc_dump: 0x0c 0x0e IRDA mode
  smsc_dump: 0x07 0x50 powerdown mode
  smsc_dump: 0x0a 0x40 toshiba mystery
  # ~/inb 0x100 8 0x100
  selecting bank 3 (fir at 0x100)
  0x0100: 0x10 0xb8 0xf2 0x00 0x51 0x00 0x00 0x03

("smsc" and "inb" are little test programs (attached).  "smsc" dumps
the SIO configuration, and "inb" dumps I/O ports.  In this case,
I'm looking at the FIR ports, and the values there are what smsc-ircc2
expects.)

Seems like it should be simple to do the same thing automatically
in the driver or a quirk, but I haven't been able to get that to work.

I'll be out of the office most of the time from now until July 5, but
I'll get back to this when I return.

Bjorn


P.S.  "reboot" doesn't seem to work on my box.  I tried "reboot=b",
"reboot=c", "reboot=h", and none of them seems to work.  Does it work
on yours?

[-- Attachment #2: smsc.c --]
[-- Type: text/x-csrc, Size: 4696 bytes --]

/*
 * Dump SMSC/LPC47N227 config, typically IRDA config
 */


#include <stdio.h>
#include <stdlib.h>
#include <sys/io.h>

/******************************************
 Keys. They should work with every SMsC SIO
 ******************************************/

#define SMSCSIO_CFGACCESSKEY		0x55
#define SMSCSIO_CFGEXITKEY			0xaa

/*****************************
 * Generic SIO Flat (!?)     *
 *****************************/
 
/* Register 0x0d */
#define SMSCSIOFLAT_DEVICEID_REG				0x0d

/* Register 0x0c */
#define SMSCSIOFLAT_UARTMODE0C_REG				0x0c
#define 	SMSCSIOFLAT_UART2MODE_MASK			0x38
#define 	SMSCSIOFLAT_UART2MODE_VAL_COM		0x00
#define 	SMSCSIOFLAT_UART2MODE_VAL_IRDA		0x08
#define 	SMSCSIOFLAT_UART2MODE_VAL_ASKIR		0x10

/* Register 0x25 */
#define SMSCSIOFLAT_UART2BASEADDR_REG			0x25

/* Register 0x2b */
#define SMSCSIOFLAT_FIRBASEADDR_REG				0x2b

/* Register 0x2c */
#define SMSCSIOFLAT_FIRDMASELECT_REG			0x2c
#define 	SMSCSIOFLAT_FIRDMASELECT_MASK		0x0f

/* Register 0x28 */
#define SMSCSIOFLAT_UARTIRQSELECT_REG			0x28
#define 	SMSCSIOFLAT_UART2IRQSELECT_MASK		0x0f
#define 	SMSCSIOFLAT_UART1IRQSELECT_MASK		0xf0
#define 	SMSCSIOFLAT_UARTIRQSELECT_VAL_NONE	0x00


/*********************
 * LPC47N227         *
 *********************/

#define LPC47N227_CFGACCESSKEY		0x55
#define LPC47N227_CFGEXITKEY		0xaa

/* Register 0x00 */
#define LPC47N227_FDCPOWERVALIDCONF_REG		0x00
#define 	LPC47N227_FDCPOWER_MASK			0x08
#define 	LPC47N227_VALID_MASK				0x80

/* Register 0x02 */
#define LPC47N227_UART12POWER_REG				0x02
#define 	LPC47N227_UART1POWERDOWN_MASK		0x08
#define 	LPC47N227_UART2POWERDOWN_MASK		0x80

/* Register 0x07 */
#define LPC47N227_APMBOOTDRIVE_REG				0x07
#define 	LPC47N227_PARPORT2AUTOPWRDOWN_MASK	0x10 /* auto power down on if set */
#define 	LPC47N227_UART2AUTOPWRDOWN_MASK	0x20 /* auto power down on if set */
#define 	LPC47N227_UART1AUTOPWRDOWN_MASK	0x40 /* auto power down on if set */

/* Register 0x0c */
#define LPC47N227_UARTMODE0C_REG				0x0c
#define 	LPC47N227_UART2MODE_MASK			0x38
#define 	LPC47N227_UART2MODE_VAL_COM		0x00
#define 	LPC47N227_UART2MODE_VAL_IRDA		0x08
#define 	LPC47N227_UART2MODE_VAL_ASKIR		0x10

/* Register 0x0d */
#define LPC47N227_DEVICEID_REG					0x0d
#define 	LPC47N227_DEVICEID_DEFVAL			0x5a

/* Register 0x0e */
#define LPC47N227_REVISIONID_REG				0x0e

/* Register 0x25 */
#define LPC47N227_UART2BASEADDR_REG			0x25

/* Register 0x28 */
#define LPC47N227_UARTIRQSELECT_REG			0x28
#define 	LPC47N227_UART2IRQSELECT_MASK		0x0f
#define 	LPC47N227_UART1IRQSELECT_MASK		0xf0
#define 	LPC47N227_UARTIRQSELECT_VAL_NONE	0x00

/* Register 0x2b */
#define LPC47N227_FIRBASEADDR_REG				0x2b

/* Register 0x2c */
#define LPC47N227_FIRDMASELECT_REG				0x2c
#define 	LPC47N227_FIRDMASELECT_MASK		0x0f
#define 	LPC47N227_FIRDMASELECT_VAL_DMA1	0x01 /* 47n227 has three dma channels */
#define 	LPC47N227_FIRDMASELECT_VAL_DMA2	0x02
#define 	LPC47N227_FIRDMASELECT_VAL_DMA3	0x03
#define 	LPC47N227_FIRDMASELECT_VAL_NONE	0x0f

static inline unsigned int smsc_read(unsigned int port, unsigned int reg)
{
	outb(reg, port);
	return inb(port + 1);
}

static inline void smsc_write(unsigned int port, unsigned int reg, unsigned int
val)
{
	outb(reg, port);
	outb(val, port + 1);
}

static void smsc_dump(unsigned int iobase)
{
	unsigned char val;

	outb(LPC47N227_CFGACCESSKEY, iobase); // enter configuration state

	val = smsc_read(iobase, 0x24);
	printf("%s: 0x%02x 0x%02x UART1 config\n", __FUNCTION__, 0x24, val);

	val = smsc_read(iobase, SMSCSIOFLAT_UART2BASEADDR_REG);
	printf("%s: 0x%02x 0x%02x SIR base (0x%x)\n", __FUNCTION__, SMSCSIOFLAT_UART2BASEADDR_REG, val, val << 2);

	val = smsc_read(iobase, SMSCSIOFLAT_UARTIRQSELECT_REG);
	printf("%s: 0x%02x 0x%02x UART IRQ\n", __FUNCTION__, SMSCSIOFLAT_UARTIRQSELECT_REG, val);

	val = smsc_read(iobase, SMSCSIOFLAT_FIRBASEADDR_REG);
	printf("%s: 0x%02x 0x%02x FIR base (0x%x)\n", __FUNCTION__, SMSCSIOFLAT_FIRBASEADDR_REG, val, val << 3);

	val = smsc_read(iobase, SMSCSIOFLAT_FIRDMASELECT_REG);
	printf("%s: 0x%02x 0x%02x FIR DMA\n", __FUNCTION__, SMSCSIOFLAT_FIRDMASELECT_REG, val);

	val = smsc_read(iobase, SMSCSIOFLAT_UARTMODE0C_REG);
	printf("%s: 0x%02x 0x%02x IRDA mode\n", __FUNCTION__, SMSCSIOFLAT_UARTMODE0C_REG, val);

	val = smsc_read(iobase, LPC47N227_APMBOOTDRIVE_REG);
	printf("%s: 0x%02x 0x%02x powerdown mode\n", __FUNCTION__, LPC47N227_APMBOOTDRIVE_REG, val);

	val = smsc_read(iobase, 0x0a);
	printf("%s: 0x%02x 0x%02x toshiba mystery\n", __FUNCTION__, 0x0a, val);

	outb(LPC47N227_CFGEXITKEY, iobase); // leave configuration state
}

main()
{
	if (iopl(3) < 0) {
		perror("iopl");
		exit(-1);
	}

	/* see smsc-ircc2.c for typical addresses */
	smsc_dump(0x2e);
	exit(0);
}

[-- Attachment #3: inb.c --]
[-- Type: text/x-csrc, Size: 678 bytes --]

#include <stdio.h>
#include <stdlib.h>
#include <sys/io.h>

main(int argc, char **argv)
{
	int port, length, fir;
	int val;
	unsigned char bank;

	if (argc < 3)
		exit(-1);

	port = strtoul(argv[1], NULL, 0);
	length = strtoul(argv[2], NULL, 0);

	if (iopl(3) < 0) {
		perror("iopl");
		exit(-1);
	}

	if (argc > 3) {
		fir = strtoul(argv[3], NULL, 0);
		printf("selecting bank 3 (fir at 0x%x)\n", fir);
		bank = inb(fir + 7);
		bank &= 0xf0;
		bank |= 3;
		outb(bank, fir + 7);
	}

	while (length--) {
		val = inb(port);
		if ((port & 0x7) == 0)
			printf("0x%04x:", port);
		printf(" 0x%02x", val & 0xff);
		if ((port & 0x7) == 0x7)
			printf("\n");
		port++;
	}

	exit(0);
}

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-19 23:31                                           ` Bjorn Helgaas
@ 2007-06-28  3:56                                             ` Bjorn Helgaas
  2007-06-30  2:41                                               ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-28  3:56 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

Andrey,

Can you try the following patch?  It applies on top of the previous
two patches, and it is enough to make the driver find the device on
my Portege 4000.  Unfortunately, I can't tell whether it really works
because I don't have a clue about how to make two IR devices talk
to each other.

Bjorn

Index: w/drivers/pnp/quirks.c
===================================================================
--- w.orig/drivers/pnp/quirks.c	2007-06-27 20:07:45.000000000 -0600
+++ w/drivers/pnp/quirks.c	2007-06-27 20:57:47.000000000 -0600
@@ -136,11 +136,11 @@
 
 static void quirk_smc_enable(struct pnp_dev *dev)
 {
-	/*
-	 * If the BIOS left the device disabled, or it is enabled and
-	 * responding correctly, we're in good shape.
-	 */
-	if (!dev->active || quirk_smc_fir_enabled(dev))
+	unsigned int irq;
+	unsigned long flags;
+
+	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev))
 		return;
 
 	/*
@@ -159,9 +159,34 @@
 	pnp_init_resource_table(&dev->res);
 	pnp_auto_config_dev(dev);
 	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev))
+		return;
+
+	/*
+	 * The Toshiba Portege 4000 reports the IRQ as active high,
+	 * edge-triggered, but the device only seems to work when we
+	 * program it as something else.
+	 */
+	irq = pnp_irq(dev, 0);
+	flags = pnp_irq_flags(dev, 0);
+	pnp_disable_dev(dev);
+	dev->res.irq_resource[0].start = irq;
+	dev->res.irq_resource[0].end   = irq;
+	flags &= ~IORESOURCE_AUTO;
+	if ((flags & IORESOURCE_BITS) == IORESOURCE_IRQ_HIGHEDGE) {
+		flags &= ~IORESOURCE_BITS;
+		flags |= IORESOURCE_IRQ_LOWEDGE;
+		dev_err(&dev->dev, "still not responding, changing high-edge "
+			"IRQ to low-edge\n");
+	}
+	dev->res.irq_resource[0].flags = flags;
+	pnp_activate_dev(dev);
+
+	if (quirk_smc_fir_enabled(dev))
+		return;
 
-	if (!quirk_smc_fir_enabled(dev))
-		dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\"\n");
+	dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\" and "
+		"email bjorn.helgaas@hp.com\n");
 }
 
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-28  3:56                                             ` Bjorn Helgaas
@ 2007-06-30  2:41                                               ` Bjorn Helgaas
  2007-06-30  7:16                                                 ` Andrey Borzenkov
  2007-07-01  0:01                                                 ` Michal Piotrowski
  0 siblings, 2 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-30  2:41 UTC (permalink / raw)
  To: Andrey Borzenkov, Andrew Morton
  Cc: Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[patch] PNP SMCf010 quirk: work around Toshiba Portege 4000 ACPI issues

When we enable the SMCf010 IR device, the Toshiba Portege 4000 BIOS claims
the device is working, but it really isn't configured correctly.  The BIOS
*will* configure it, but only if we call _SRS after (1) reversing the order
of the SIR and FIR I/O port regions and (2) changing the IRQ from active-high
to active-low.

This patch fixes the 2.6.22 regression:
    "no irda0 interface (2.6.21 was OK), smsc does not find chip"

I tested this on a Portege 4000.  The smsc-ircc2 driver correctly detects
the device, and "irattach irda0 -s && irdadump" shows transmitted and
received packets.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/pnp/quirks.c
===================================================================
--- w.orig/drivers/pnp/quirks.c	2007-06-27 20:07:45.000000000 -0600
+++ w/drivers/pnp/quirks.c	2007-06-29 19:28:02.000000000 -0600
@@ -136,11 +136,10 @@
 
 static void quirk_smc_enable(struct pnp_dev *dev)
 {
-	/*
-	 * If the BIOS left the device disabled, or it is enabled and
-	 * responding correctly, we're in good shape.
-	 */
-	if (!dev->active || quirk_smc_fir_enabled(dev))
+	struct resource fir, sir, irq;
+
+	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev))
 		return;
 
 	/*
@@ -152,16 +151,58 @@
 	 * this.  Fortunately, they do fix things up if we auto-configure
 	 * the device using its _PRS and _SRS methods.
 	 */
-	dev_err(&dev->dev, "%s device not responding, auto-configuring "
-		"resources\n", dev->id->id);
+	dev_err(&dev->dev, "%s not responding at SIR 0x%llx, FIR 0x%llx; "
+		"auto-configuring\n", dev->id->id,
+		pnp_port_start(dev, 0), pnp_port_start(dev, 1));
 
 	pnp_disable_dev(dev);
 	pnp_init_resource_table(&dev->res);
 	pnp_auto_config_dev(dev);
 	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev)) {
+		dev_err(&dev->dev, "responds at SIR 0x%llx, FIR 0x%llx\n",
+			pnp_port_start(dev, 0), pnp_port_start(dev, 1));
+		return;
+	}
+
+	/*
+	 * The Toshiba Portege 4000 _CRS reports the FIR region first,
+	 * followed by the SIR region.  The BIOS will configure the bridge,
+	 * but only if we call _SRS with SIR first, then FIR.  It also
+	 * reports the IRQ as active high, when it is really active low.
+	 */
+	dev_err(&dev->dev, "not responding at SIR 0x%llx, FIR 0x%llx; "
+		"swapping SIR/FIR and reconfiguring\n",
+		pnp_port_start(dev, 0), pnp_port_start(dev, 1));
+
+	/*
+	 * Clear IORESOURCE_AUTO so pnp_activate_dev() doesn't reassign
+	 * these resources any more.
+	 */
+	fir = dev->res.port_resource[0];
+	sir = dev->res.port_resource[1];
+	fir.flags &= ~IORESOURCE_AUTO;
+	sir.flags &= ~IORESOURCE_AUTO;
+
+	irq = dev->res.irq_resource[0];
+	irq.flags &= ~IORESOURCE_AUTO;
+	irq.flags &= ~IORESOURCE_BITS;
+	irq.flags |= IORESOURCE_IRQ_LOWEDGE;
+
+	pnp_disable_dev(dev);
+	dev->res.port_resource[0] = sir;
+	dev->res.port_resource[1] = fir;
+	dev->res.irq_resource[0] = irq;
+	pnp_activate_dev(dev);
+
+	if (quirk_smc_fir_enabled(dev)) {
+		dev_err(&dev->dev, "responds at SIR 0x%llx, FIR 0x%llx\n",
+			pnp_port_start(dev, 0), pnp_port_start(dev, 1));
+		return;
+	}
 
-	if (!quirk_smc_fir_enabled(dev))
-		dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\"\n");
+	dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\" and "
+		"email bjorn.helgaas@hp.com\n");
 }
 
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30  2:41                                               ` Bjorn Helgaas
@ 2007-06-30  7:16                                                 ` Andrey Borzenkov
  2007-06-30 11:45                                                   ` Bjorn Helgaas
  2007-07-01  0:01                                                 ` Michal Piotrowski
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-30  7:16 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 6351 bytes --]

On Saturday 30 June 2007, Bjorn Helgaas wrote:
> [patch] PNP SMCf010 quirk: work around Toshiba Portege 4000 ACPI issues
>
> When we enable the SMCf010 IR device, the Toshiba Portege 4000 BIOS claims
> the device is working, but it really isn't configured correctly.  The BIOS
> *will* configure it, but only if we call _SRS after (1) reversing the order
> of the SIR and FIR I/O port regions and (2) changing the IRQ from
> active-high to active-low.
>
> This patch fixes the 2.6.22 regression:
>     "no irda0 interface (2.6.21 was OK), smsc does not find chip"
>

does not work, sorry.

[  958.107142] ACPI: bus type pnp registered
[  958.125652] pnp: Device 00:0a activated.
[  958.125710]  00:0a: SMCf010 not responding at SIR 0x2e800000100, FIR 
0x2e8def5a6d4; auto-configuring
[  958.127243] pnp: Device 00:0a disabled.
[  958.132808] pnp: Device 00:0a activated.
[  958.132837]  00:0a: not responding at SIR 0x2e800000100, FIR 
0xded782bc000002e8; swapping SIR/FIR and reconfiguring
[  958.134350] pnp: Device 00:0a disabled.
[  958.140926] pnp: Device 00:0a activated.
[  958.140954]  00:0a: responds at SIR 0x100000002e8, FIR 0xded782bc000002e8
[  958.148707] pnp: PnP ACPI: found 12 devices

and loading smsc_ircc2

[  524.423280] pnp: Device 00:0a activated.
[  524.426614] smsc_ircc_present(), addr 0x0100 - no device found!
[  524.426614] pnp: Device 00:0a disabled.

as already mentioned, port 100 cannot work:

0100-013f : pcmcia_socket0
{pts/1}% sudo 
cat /sys/class/pcmcia_socket/pcmcia_socket0/available_resources_io
0x00000100 - 0x000003af
0x000003e0 - 0x000004ff
0x00000820 - 0x000008ff
0x00000a00 - 0x00000aff
0x00000c00 - 0x00000cf7

additinally I get these warnings during compile (and output is bogus):

/home/bor/src/linux-git/drivers/pnp/quirks.c: In function ‘quirk_smc_enable’:
/home/bor/src/linux-git/drivers/pnp/quirks.c:154: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 5 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:154: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 6 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:163: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 4 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:163: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 5 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:174: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 4 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:174: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 5 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:199: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 4 has 
type ‘resource_size_t’
/home/bor/src/linux-git/drivers/pnp/quirks.c:199: warning: format ‘%llx’ 
expects type ‘long long unsigned int’, but argument 5 has 
type ‘resource_size_t’       

-andrey

> I tested this on a Portege 4000.  The smsc-ircc2 driver correctly detects
> the device, and "irattach irda0 -s && irdadump" shows transmitted and
> received packets.
>
> Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
>
> Index: w/drivers/pnp/quirks.c
> ===================================================================
> --- w.orig/drivers/pnp/quirks.c	2007-06-27 20:07:45.000000000 -0600
> +++ w/drivers/pnp/quirks.c	2007-06-29 19:28:02.000000000 -0600
> @@ -136,11 +136,10 @@
>
>  static void quirk_smc_enable(struct pnp_dev *dev)
>  {
> -	/*
> -	 * If the BIOS left the device disabled, or it is enabled and
> -	 * responding correctly, we're in good shape.
> -	 */
> -	if (!dev->active || quirk_smc_fir_enabled(dev))
> +	struct resource fir, sir, irq;
> +
> +	pnp_activate_dev(dev);
> +	if (quirk_smc_fir_enabled(dev))
>  		return;
>
>  	/*
> @@ -152,16 +151,58 @@
>  	 * this.  Fortunately, they do fix things up if we auto-configure
>  	 * the device using its _PRS and _SRS methods.
>  	 */
> -	dev_err(&dev->dev, "%s device not responding, auto-configuring "
> -		"resources\n", dev->id->id);
> +	dev_err(&dev->dev, "%s not responding at SIR 0x%llx, FIR 0x%llx; "
> +		"auto-configuring\n", dev->id->id,
> +		pnp_port_start(dev, 0), pnp_port_start(dev, 1));
>
>  	pnp_disable_dev(dev);
>  	pnp_init_resource_table(&dev->res);
>  	pnp_auto_config_dev(dev);
>  	pnp_activate_dev(dev);
> +	if (quirk_smc_fir_enabled(dev)) {
> +		dev_err(&dev->dev, "responds at SIR 0x%llx, FIR 0x%llx\n",
> +			pnp_port_start(dev, 0), pnp_port_start(dev, 1));
> +		return;
> +	}
> +
> +	/*
> +	 * The Toshiba Portege 4000 _CRS reports the FIR region first,
> +	 * followed by the SIR region.  The BIOS will configure the bridge,
> +	 * but only if we call _SRS with SIR first, then FIR.  It also
> +	 * reports the IRQ as active high, when it is really active low.
> +	 */
> +	dev_err(&dev->dev, "not responding at SIR 0x%llx, FIR 0x%llx; "
> +		"swapping SIR/FIR and reconfiguring\n",
> +		pnp_port_start(dev, 0), pnp_port_start(dev, 1));
> +
> +	/*
> +	 * Clear IORESOURCE_AUTO so pnp_activate_dev() doesn't reassign
> +	 * these resources any more.
> +	 */
> +	fir = dev->res.port_resource[0];
> +	sir = dev->res.port_resource[1];
> +	fir.flags &= ~IORESOURCE_AUTO;
> +	sir.flags &= ~IORESOURCE_AUTO;
> +
> +	irq = dev->res.irq_resource[0];
> +	irq.flags &= ~IORESOURCE_AUTO;
> +	irq.flags &= ~IORESOURCE_BITS;
> +	irq.flags |= IORESOURCE_IRQ_LOWEDGE;
> +
> +	pnp_disable_dev(dev);
> +	dev->res.port_resource[0] = sir;
> +	dev->res.port_resource[1] = fir;
> +	dev->res.irq_resource[0] = irq;
> +	pnp_activate_dev(dev);
> +
> +	if (quirk_smc_fir_enabled(dev)) {
> +		dev_err(&dev->dev, "responds at SIR 0x%llx, FIR 0x%llx\n",
> +			pnp_port_start(dev, 0), pnp_port_start(dev, 1));
> +		return;
> +	}
>
> -	if (!quirk_smc_fir_enabled(dev))
> -		dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\"\n");
> +	dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\" and "
> +		"email bjorn.helgaas@hp.com\n");
>  }



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30  7:16                                                 ` Andrey Borzenkov
@ 2007-06-30 11:45                                                   ` Bjorn Helgaas
  2007-06-30 14:47                                                     ` Andrey Borzenkov
  2007-08-11 18:39                                                     ` Andrey Borzenkov
  0 siblings, 2 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-06-30 11:45 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

On Saturday 30 June 2007 01:16:18 am Andrey Borzenkov wrote:
> > This patch fixes the 2.6.22 regression:
> >     "no irda0 interface (2.6.21 was OK), smsc does not find chip"
> 
> does not work, sorry.

Sigh ;-)  Thanks for your patience in dealing with this.

> [  958.125710]  00:0a: SMCf010 not responding at SIR 0x2e800000100, FIR 0x2e8def5a6d4; auto-configuring
> [  958.132837]  00:0a: not responding at SIR 0x2e800000100, FIR 0xded782bc000002e8; swapping SIR/FIR and reconfiguring
> [  958.140954]  00:0a: responds at SIR 0x100000002e8, FIR 0xded782bc000002e8

This means that the SMCf010 device *did* respond, I think at the
FIR address 0x100.  (I can't figure out the "right" way to print
those resource_size_t things, so I added some casts in the appended
patch.)

> [  524.426614] smsc_ircc_present(), addr 0x0100 - no device found!

But by the time the smsc_ircc2 driver got loaded, the device stopped
responding.  That means something happened in between that messed it up.

> as already mentioned, port 100 cannot work:
> 
> 0100-013f : pcmcia_socket0
> {pts/1}% sudo 
> cat /sys/class/pcmcia_socket/pcmcia_socket0/available_resources_io
> 0x00000100 - 0x000003af
> 0x000003e0 - 0x000004ff
> 0x00000820 - 0x000008ff
> 0x00000a00 - 0x00000aff
> 0x00000c00 - 0x00000cf7

Well, the whole problem I'm trying to fix is that we aren't doing
resource allocation correctly.  The BIOS has configured the IR
device to use port 0x100, and then something else came along and
decided to also use port 0x100.

It looks like the something else is the wlags49_h1_cs driver for
the PCMCIA card you have inserted.  Can you temporarily remove that
card and driver and try the patch below?  If the IR device works
without the wlags49_h1_cs driver, then we'll have to look at
wlags49_h1_cs to see whether it's doing something wrong.

Bjorn


[patch] PNP SMCf010 quirk: work around Toshiba Portege 4000 ACPI issues

When we enable the SMCf010 IR device, the Toshiba Portege 4000 BIOS claims
the device is working, but it really isn't configured correctly.  The BIOS
*will* configure it, but only if we call _SRS after (1) reversing the order
of the SIR and FIR I/O port regions and (2) changing the IRQ from active-high
to active-low.

This patch addresses the 2.6.22 regression:
    "no irda0 interface (2.6.21 was OK), smsc does not find chip"

I tested this on a Portege 4000.  The smsc-ircc2 driver correctly detects
the device, and "irattach irda0 -s && irdadump" shows transmitted and
received packets.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/pnp/quirks.c
===================================================================
--- w.orig/drivers/pnp/quirks.c	2007-06-27 20:07:45.000000000 -0600
+++ w/drivers/pnp/quirks.c	2007-06-30 05:27:03.000000000 -0600
@@ -136,11 +136,10 @@
 
 static void quirk_smc_enable(struct pnp_dev *dev)
 {
-	/*
-	 * If the BIOS left the device disabled, or it is enabled and
-	 * responding correctly, we're in good shape.
-	 */
-	if (!dev->active || quirk_smc_fir_enabled(dev))
+	struct resource fir, sir, irq;
+
+	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev))
 		return;
 
 	/*
@@ -152,16 +151,62 @@
 	 * this.  Fortunately, they do fix things up if we auto-configure
 	 * the device using its _PRS and _SRS methods.
 	 */
-	dev_err(&dev->dev, "%s device not responding, auto-configuring "
-		"resources\n", dev->id->id);
+	dev_err(&dev->dev, "%s not responding at SIR 0x%lx, FIR 0x%lx; "
+		"auto-configuring\n", dev->id->id,
+		(unsigned long) pnp_port_start(dev, 0), 
+		(unsigned long) pnp_port_start(dev, 1));
 
 	pnp_disable_dev(dev);
 	pnp_init_resource_table(&dev->res);
 	pnp_auto_config_dev(dev);
 	pnp_activate_dev(dev);
+	if (quirk_smc_fir_enabled(dev)) {
+		dev_err(&dev->dev, "responds at SIR 0x%lx, FIR 0x%lx\n",
+			(unsigned long) pnp_port_start(dev, 0),
+			(unsigned long) pnp_port_start(dev, 1));
+		return;
+	}
+
+	/*
+	 * The Toshiba Portege 4000 _CRS reports the FIR region first,
+	 * followed by the SIR region.  The BIOS will configure the bridge,
+	 * but only if we call _SRS with SIR first, then FIR.  It also
+	 * reports the IRQ as active high, when it is really active low.
+	 */
+	dev_err(&dev->dev, "not responding at SIR 0x%lx, FIR 0x%lx; "
+		"swapping SIR/FIR and reconfiguring\n",
+		(unsigned long) pnp_port_start(dev, 0),
+		(unsigned long) pnp_port_start(dev, 1));
+
+	/*
+	 * Clear IORESOURCE_AUTO so pnp_activate_dev() doesn't reassign
+	 * these resources any more.
+	 */
+	fir = dev->res.port_resource[0];
+	sir = dev->res.port_resource[1];
+	fir.flags &= ~IORESOURCE_AUTO;
+	sir.flags &= ~IORESOURCE_AUTO;
+
+	irq = dev->res.irq_resource[0];
+	irq.flags &= ~IORESOURCE_AUTO;
+	irq.flags &= ~IORESOURCE_BITS;
+	irq.flags |= IORESOURCE_IRQ_LOWEDGE;
+
+	pnp_disable_dev(dev);
+	dev->res.port_resource[0] = sir;
+	dev->res.port_resource[1] = fir;
+	dev->res.irq_resource[0] = irq;
+	pnp_activate_dev(dev);
+
+	if (quirk_smc_fir_enabled(dev)) {
+		dev_err(&dev->dev, "responds at SIR 0x%lx, FIR 0x%lx\n",
+			(unsigned long) pnp_port_start(dev, 0),
+			(unsigned long) pnp_port_start(dev, 1));
+		return;
+	}
 
-	if (!quirk_smc_fir_enabled(dev))
-		dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\"\n");
+	dev_err(&dev->dev, "giving up; try \"smsc-ircc2.nopnp\" and "
+		"email bjorn.helgaas@hp.com\n");
 }
 
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30 11:45                                                   ` Bjorn Helgaas
@ 2007-06-30 14:47                                                     ` Andrey Borzenkov
  2007-06-30 21:13                                                       ` Andrey Borzenkov
  2007-08-11 18:39                                                     ` Andrey Borzenkov
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-30 14:47 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 4016 bytes --]

On Saturday 30 June 2007, Bjorn Helgaas wrote:
> This means that the SMCf010 device *did* respond, I think at the
> FIR address 0x100.  (I can't figure out the "right" way to print
> those resource_size_t things, so I added some casts in the appended
> patch.)
>

Those can be 64 bit if CONFIG_RESOURCE_64BIT is set; so you probably should 
cast to unsigned long long and use %llx. Or do it conditionally depending on 
above macro.

> Well, the whole problem I'm trying to fix is that we aren't doing
> resource allocation correctly.  The BIOS has configured the IR
> device to use port 0x100, and then something else came along and
> decided to also use port 0x100.
>

That I already asked - how should PCMCIA subsystem know that some device 
requires fixed io port? Or for that matter - how should PnP know that some 
resource it believes is free is actually used by PCMCIA?

> It looks like the something else is the wlags49_h1_cs driver for
> the PCMCIA card you have inserted.  Can you temporarily remove that
> card and driver and try the patch below?  If the IR device works
> without the wlags49_h1_cs driver, then we'll have to look at
> wlags49_h1_cs to see whether it's doing something wrong.
>


Yes, this works. I did not use patch below, because it works with original too 
of course. In this PCMCIA later sees that port range at 0x100 is already 
taken and selects another one:

[  693.694389] SMsC IrDA Controller found
[  693.694395]  IrCC version 2.0, firport 0x100, sirport 0x2e8 dma=1, irq=5
[  693.735620] No transceiver found. Defaulting to Fast pin select
[  693.757188] IrDA: Registered device irda0
[  840.397539] Yenta: CardBus bridge found at 0000:00:10.0 [12a3:ab01]
[  840.419345] Yenta: Using CSCINT to route CSC interrupts to PCI
[  840.441395] Yenta: Routing CardBus interrupts to PCI
[  840.463454] Yenta TI: socket 0000:00:10.0, mfunc 0x01000002, devctl 0x60
[  840.713821] Yenta: ISA IRQ mask 0x0000, PCI irq 11
[  840.736937] Socket status: 30000059
[  840.761016] Yenta: CardBus bridge found at 0000:00:11.0 [1179:0001]
[  840.910480] Yenta: ISA IRQ mask 0x04b8, PCI irq 11
[  840.934571] Socket status: 30000087
[  840.959527] Yenta: CardBus bridge found at 0000:00:11.1 [1179:0001]
[  841.110433] Yenta: ISA IRQ mask 0x04b8, PCI irq 11
[  841.135628] Socket status: 30000087
[  841.393023] pccard: PCMCIA card inserted into slot 0
[  970.189560] wlags49_h1_cs v7.18 for PCMCIA, 03/31/2004 14:31:00 by Agere 
Systems, http://www.agere.com
[  970.212434] *** Modified for kernel 2.6 by Andrey Borzenkov 
<arvidjaar@mail.ru> $Revision: 39 $
[  970.235874] *** Station Mode (STA) Support: YES
[  970.259328] *** Access Point Mode (AP) Support: YES
[ 1286.581694] cs: memory probe 0x0c0000-0x0fffff: excluding 0xc0000-0xcbfff 
0xe0000-0xfffff
[ 1286.608294] cs: memory probe 0x60000000-0x60ffffff: clean.
[ 1286.642101] cs: memory probe 0xa0000000-0xa0ffffff: clean.
[ 1286.676160] pcmcia: registering new device pcmcia0.0
[ 1287.186722] eth0: PRI 31 variant 2 version 9.48
[ 1287.208487] eth0: NIC 5 variant 2 version 1.02
[ 1287.234616] eth0: Wireless, io_addr 0x180, irq 11, mac_address 
00:02:2D:26:95:6C

is it interesting to look at ports:

0100-0107 : smsc-ircc2
0170-0177 : 0000:00:04.0
  0170-0177 : libata
0180-01bf : pcmcia_socket0

notice that pcmcia_socket available resources do not change at all in this 
case and still list port range 100 - 3af.

I do not think wlags driver has anything to do with it (directly). It just 
requests resource allocation from PCMCIA core. So either we have to mark 
resources of PnP devices reserved (even if devices are not active and no 
driver is loaded) or we need some way to force PnP to allocate different 
resources on device activation. Which means PCMCIA should somehow inform PnP 
that resources it allocated are in use. 

Anyway if you want to get a look - driver is available at 
http://arvidjaar.newmail.ru/wlags49.tar.bz2. 

-andrey

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30 14:47                                                     ` Andrey Borzenkov
@ 2007-06-30 21:13                                                       ` Andrey Borzenkov
  2007-07-01  3:30                                                         ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-06-30 21:13 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 1810 bytes --]

On Saturday 30 June 2007, Andrey Borzenkov wrote:
> On Saturday 30 June 2007, Bjorn Helgaas wrote:
> > This means that the SMCf010 device *did* respond, I think at the
> > FIR address 0x100.  (I can't figure out the "right" way to print
> > those resource_size_t things, so I added some casts in the appended
> > patch.)
>
> Those can be 64 bit if CONFIG_RESOURCE_64BIT is set; so you probably should
> cast to unsigned long long and use %llx. Or do it conditionally depending
> on above macro.
>
> > Well, the whole problem I'm trying to fix is that we aren't doing
> > resource allocation correctly.  The BIOS has configured the IR
> > device to use port 0x100, and then something else came along and
> > decided to also use port 0x100.
>

After some digging, it works now :) So the story:

PCMCIA includes code for checking for free IO range(s)
code is active only if CONFIG_ISA is defined
CONFIG_ISA has this excellent help text:
          Find out whether you have ISA slots on your motherboard. 
and I was stupid enough to take this literally (having notebook I obviously do 
not have any slots at all)

So after recompiling with CONFIG_ISA defined I now get

[ 2254.136611] cs: IO port probe 0x100-0x3af: excluding 0x100-0x107 
0x2e8-0x2ef 0x378-0x37f
[ 2254.166638] cs: IO port probe 0x3e0-0x4ff: excluding 0x3f8-0x3ff 
0x408-0x40f 0x480-0x48f 0x4d0-0x4d7
[ 2254.194838] cs: IO port probe 0x820-0x8ff: clean.
[ 2254.222401] cs: IO port probe 0xc00-0xcf7: clean.
[ 2254.250056] cs: IO port probe 0xa00-0xaff: clean.

(I wonder why this is repeated 3 times, but well ...) and smsc-ircc2 takes 
over ports 0x100 - 0x107 and is happy.

THANK YOU!

Bjorn, I believe last touch that is needed is to sort out printf issues, 
otherwise patch is fine here.

-andrey

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30  2:41                                               ` Bjorn Helgaas
  2007-06-30  7:16                                                 ` Andrey Borzenkov
@ 2007-07-01  0:01                                                 ` Michal Piotrowski
  2007-07-01  0:04                                                   ` Michal Piotrowski
  1 sibling, 1 reply; 48+ messages in thread
From: Michal Piotrowski @ 2007-07-01  0:01 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrey Borzenkov, Andrew Morton, Samuel Ortiz,
	Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia,
	Linus Torvalds

Hi,

Bjorn Helgaas pisze:
> [patch] PNP SMCf010 quirk: work around Toshiba Portege 4000 ACPI issues
> 
> When we enable the SMCf010 IR device, the Toshiba Portege 4000 BIOS claims
> the device is working, but it really isn't configured correctly.  The BIOS
> *will* configure it, but only if we call _SRS after (1) reversing the order
> of the SIR and FIR I/O port regions and (2) changing the IRQ from active-high
> to active-low.
> 
> This patch fixes the 2.6.22 regression:
>     "no irda0 interface (2.6.21 was OK), smsc does not find chip"

Hmmm...

375  	2007-06-29 14:24:47  	6921  	 	mkkp  	"no irda0 interface (2.6.21 was OK), smsc does not find chip" fixed, STATISTICS Bjorn Helgaas +1

Wasn't it fixed?

commit 172d0496cd22c98ee2e4238821fa309c01685f3a
Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
Date:   Wed Jun 27 14:09:52 2007 -0700
[..]
    This patch addresses part of the 2.6.22 regression:
        "no irda0 interface (2.6.21 was OK), smsc does not find chip"


> 
> I tested this on a Portege 4000.  The smsc-ircc2 driver correctly detects
> the device, and "irattach irda0 -s && irdadump" shows transmitted and
> received packets.
> 

Regards,
Michal

-- 
LOG
http://www.stardust.webpages.pl/log/

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-07-01  0:01                                                 ` Michal Piotrowski
@ 2007-07-01  0:04                                                   ` Michal Piotrowski
  0 siblings, 0 replies; 48+ messages in thread
From: Michal Piotrowski @ 2007-07-01  0:04 UTC (permalink / raw)
  To: Michal Piotrowski
  Cc: Bjorn Helgaas, Andrey Borzenkov, Andrew Morton, Samuel Ortiz,
	Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia,
	Linus Torvalds

Michal Piotrowski pisze:
> Hi,
> 
> Bjorn Helgaas pisze:
>> [patch] PNP SMCf010 quirk: work around Toshiba Portege 4000 ACPI issues
>>
>> When we enable the SMCf010 IR device, the Toshiba Portege 4000 BIOS claims
>> the device is working, but it really isn't configured correctly.  The BIOS
>> *will* configure it, but only if we call _SRS after (1) reversing the order
>> of the SIR and FIR I/O port regions and (2) changing the IRQ from active-high
>> to active-low.
>>
>> This patch fixes the 2.6.22 regression:
>>     "no irda0 interface (2.6.21 was OK), smsc does not find chip"
> 
> Hmmm...
> 
> 375  	2007-06-29 14:24:47  	6921  	 	mkkp  	"no irda0 interface (2.6.21 was OK), smsc does not find chip" fixed, STATISTICS Bjorn Helgaas +1
> 
> Wasn't it fixed?
> 
> commit 172d0496cd22c98ee2e4238821fa309c01685f3a
> Author: Bjorn Helgaas <bjorn.helgaas@hp.com>
> Date:   Wed Jun 27 14:09:52 2007 -0700
> [..]
>     This patch addresses part of the 2.6.22 regression:
                           ^^^^
                           yup, my fault.


Regards,
Michal

-- 
LOG
http://www.stardust.webpages.pl/log/

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30 21:13                                                       ` Andrey Borzenkov
@ 2007-07-01  3:30                                                         ` Bjorn Helgaas
  2007-07-01  7:08                                                           ` Andrey Borzenkov
  0 siblings, 1 reply; 48+ messages in thread
From: Bjorn Helgaas @ 2007-07-01  3:30 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

On Saturday 30 June 2007 03:13:24 pm Andrey Borzenkov wrote:
> After some digging, it works now :) So the story:
> 
> PCMCIA includes code for checking for free IO range(s)
> code is active only if CONFIG_ISA is defined
> CONFIG_ISA has this excellent help text:
>           Find out whether you have ISA slots on your motherboard. 
> and I was stupid enough to take this literally (having notebook I obviously do 
> not have any slots at all)

I'm sorry I don't have time at the moment to do digging of my own.
But I don't think you should have to define CONFIG_ISA.  I think
you hit the nail on the head in your last email -- PNP should be
reserving the resources of active devices.

The fact that PNP doesn't reserve them means PCMCIA is free to
claim them for itself.  So I think PNP is mostly at fault here.
(Of course, we'll still have to work around the Portege BIOS
issue as well.)

> So after recompiling with CONFIG_ISA defined I now get
> 
> [ 2254.136611] cs: IO port probe 0x100-0x3af: excluding 0x100-0x107 
> 0x2e8-0x2ef 0x378-0x37f
> [ 2254.166638] cs: IO port probe 0x3e0-0x4ff: excluding 0x3f8-0x3ff 
> 0x408-0x40f 0x480-0x48f 0x4d0-0x4d7
> [ 2254.194838] cs: IO port probe 0x820-0x8ff: clean.
> [ 2254.222401] cs: IO port probe 0xc00-0xcf7: clean.
> [ 2254.250056] cs: IO port probe 0xa00-0xaff: clean.

I suspect that things will mostly work if you load the drivers in
the (smsc-ircc2, wlags49_h1_cs) order.  Then smsc-ircc2 has a chance
to reserve the resources before yenta and wlags49 get involved.  But
of course, we can't rely on that workaround.

I think there's lots of work needed here -- make PNP reserve resources,
add smarter PNP quirk infrastructure so we can do things at _SRS-time,
add real Portege BIOS workaround, etc.  Way more than we can do for
2.6.22.

What do you think we need to get 2.6.22 out?  I was thinking of a
stop-gap patch like the one below.  I'm between trips and can't
really test it.  In my one quick boot, it did find the IR device,
but irdadump didn't seem to do anything.



[patch] smsc-ircc2: bypass PNP detection until we get the quirks worked out

Don't use PNP detection by default yet.  We have some PNP and BIOS issues
to work out first.

Sample problem on a Toshiba Portege 4000: the SMCf010 device is handed off
disabled.  We assign I/O ports originally assigned to the SMCf010 to a
PCMCIA device instead.  We enable the SMCf010, configuring it to use
disjoint ports, but _SRS doesn't work correctly, so the device doesn't
work.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/net/irda/smsc-ircc2.c
===================================================================
--- w.orig/drivers/net/irda/smsc-ircc2.c	2007-06-30 21:00:06.000000000 -0600
+++ w/drivers/net/irda/smsc-ircc2.c	2007-06-30 21:00:08.000000000 -0600
@@ -79,7 +79,7 @@
 MODULE_DESCRIPTION("SMC IrCC SIR/FIR controller driver");
 MODULE_LICENSE("GPL");
 
-static int smsc_nopnp;
+static int smsc_nopnp = 1;
 module_param_named(nopnp, smsc_nopnp, bool, 0);
 MODULE_PARM_DESC(nopnp, "Do not use PNP to detect controller settings");
 


^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-07-01  3:30                                                         ` Bjorn Helgaas
@ 2007-07-01  7:08                                                           ` Andrey Borzenkov
  2007-07-01 13:57                                                             ` Bjorn Helgaas
  0 siblings, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-07-01  7:08 UTC (permalink / raw)
  To: Bjorn Helgaas, linux-kernel, michal.k.k.piotrowski

Bjorn Helgaas wrote:

[...]
> 
> I suspect that things will mostly work if you load the drivers in
> the (smsc-ircc2, wlags49_h1_cs) order.

yes

> Then smsc-ircc2 has a chance 
> to reserve the resources before yenta and wlags49 get involved.  But
> of course, we can't rely on that workaround.
> 

yes :)

> I think there's lots of work needed here -- make PNP reserve resources,
> add smarter PNP quirk infrastructure so we can do things at _SRS-time,
> add real Portege BIOS workaround, etc.  Way more than we can do for
> 2.6.22.
> 

yes :)

> What do you think we need to get 2.6.22 out?  I was thinking of a
> stop-gap patch like the one below. 

I agree. I was about to suggest the same the very first time I have seen
this issue.

> I'm between trips and can't 
> really test it.  In my one quick boot, it did find the IR device,
> but irdadump didn't seem to do anything.
> 

I confirm that loading smsc-icc2 with nopnp (with your other two patches
applied) works, finds SIR/FIR and irdadump shows data flowing. 

-andrey

> 
> 
> [patch] smsc-ircc2: bypass PNP detection until we get the quirks worked
> [out
> 
> Don't use PNP detection by default yet.  We have some PNP and BIOS issues
> to work out first.
> 
> Sample problem on a Toshiba Portege 4000: the SMCf010 device is handed off
> disabled.  We assign I/O ports originally assigned to the SMCf010 to a
> PCMCIA device instead.  We enable the SMCf010, configuring it to use
> disjoint ports, but _SRS doesn't work correctly, so the device doesn't
> work.
> 
> Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>
> 
> Index: w/drivers/net/irda/smsc-ircc2.c
> ===================================================================
> --- w.orig/drivers/net/irda/smsc-ircc2.c      2007-06-30 21:00:06.000000000
> -0600
> +++ w/drivers/net/irda/smsc-ircc2.c   2007-06-30 21:00:08.000000000 -0600
> @@ -79,7 +79,7 @@
>  MODULE_DESCRIPTION("SMC IrCC SIR/FIR controller driver");
>  MODULE_LICENSE("GPL");
>  
> -static int smsc_nopnp;
> +static int smsc_nopnp = 1;
>  module_param_named(nopnp, smsc_nopnp, bool, 0);
>  MODULE_PARM_DESC(nopnp, "Do not use PNP to detect controller settings");



^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-07-01  7:08                                                           ` Andrey Borzenkov
@ 2007-07-01 13:57                                                             ` Bjorn Helgaas
  0 siblings, 0 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-07-01 13:57 UTC (permalink / raw)
  To: Andrey Borzenkov; +Cc: linux-kernel, michal.k.k.piotrowski, Andrew Morton

Andrew, can you apply the patch below for 2.6.22?  It reverts
smsc-ircc2 to the old blind probing behavior.  There's a lot of
infrastructure work I need to do before the PNP probe will be
reliable.

Thanks,
  Bjorn

On Sunday 01 July 2007 01:08:16 am Andrey Borzenkov wrote:
> Bjorn Helgaas wrote:
> > I suspect that things will mostly work if you load the drivers in
> > the (smsc-ircc2, wlags49_h1_cs) order.
> 
> yes
> 
> > Then smsc-ircc2 has a chance 
> > to reserve the resources before yenta and wlags49 get involved.  But
> > of course, we can't rely on that workaround.
> 
> yes :)
> 
> > I think there's lots of work needed here -- make PNP reserve resources,
> > add smarter PNP quirk infrastructure so we can do things at _SRS-time,
> > add real Portege BIOS workaround, etc.  Way more than we can do for
> > 2.6.22.
> 
> yes :)
> 
> > What do you think we need to get 2.6.22 out?  I was thinking of a
> > stop-gap patch like the one below. 
> 
> I agree. I was about to suggest the same the very first time I have seen
> this issue.
> 
> > I'm between trips and can't 
> > really test it.  In my one quick boot, it did find the IR device,
> > but irdadump didn't seem to do anything.
> 
> I confirm that loading smsc-icc2 with nopnp (with your other two patches
> applied) works, finds SIR/FIR and irdadump shows data flowing. 


[patch] smsc-ircc2: bypass PNP detection until we get the quirks worked out

Don't use PNP detection by default yet.  We have some PNP and BIOS issues
to work out first.

Sample problem on a Toshiba Portege 4000: the SMCf010 device is handed off
disabled.  We assign I/O ports originally assigned to the SMCf010 to a
PCMCIA device instead.  We enable the SMCf010, configuring it to use
disjoint ports, but _SRS doesn't work correctly, so the device doesn't
work.

Signed-off-by: Bjorn Helgaas <bjorn.helgaas@hp.com>

Index: w/drivers/net/irda/smsc-ircc2.c
===================================================================
--- w.orig/drivers/net/irda/smsc-ircc2.c	2007-06-30 21:00:06.000000000 -0600
+++ w/drivers/net/irda/smsc-ircc2.c	2007-06-30 21:00:08.000000000 -0600
@@ -79,7 +79,7 @@
 MODULE_DESCRIPTION("SMC IrCC SIR/FIR controller driver");
 MODULE_LICENSE("GPL");
 
-static int smsc_nopnp;
+static int smsc_nopnp = 1;
 module_param_named(nopnp, smsc_nopnp, bool, 0);
 MODULE_PARM_DESC(nopnp, "Do not use PNP to detect controller settings");
 

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-06-30 11:45                                                   ` Bjorn Helgaas
  2007-06-30 14:47                                                     ` Andrey Borzenkov
@ 2007-08-11 18:39                                                     ` Andrey Borzenkov
  2007-08-13 16:09                                                       ` Bjorn Helgaas
  1 sibling, 1 reply; 48+ messages in thread
From: Andrey Borzenkov @ 2007-08-11 18:39 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 1718 bytes --]

On Saturday 30 June 2007, Bjorn Helgaas wrote:
> On Saturday 30 June 2007 01:16:18 am Andrey Borzenkov wrote:
> > > This patch fixes the 2.6.22 regression:
> > >     "no irda0 interface (2.6.21 was OK), smsc does not find chip"
> >
> > does not work, sorry.
>
> Sigh ;-)  Thanks for your patience in dealing with this.
>

This stopped working again in 2.6.23-rc. In 2.6.22 we decided to disable PnP 
by default; it is apparently enabled now and fails to activte IrDA 
completely. So it moves to post-2.6.22 regressions :)

let me know which information you need

[ 2192.666450] pnp: PnP ACPI init
[ 2192.666589] ACPI: bus type pnp registered
[ 2192.686035] pnp: Device 00:0a activated.
[ 2192.686089]  00:0a: SMCf010 not responding at SIR 0x100, FIR 0x2e8; 
auto-configuring
[ 2192.687610] pnp: Device 00:0a disabled.
[ 2192.693179] pnp: Device 00:0a activated.
[ 2192.693210]  00:0a: not responding at SIR 0x100, FIR 0x2e8; swapping 
SIR/FIR and reconfiguring
[ 2192.694720] pnp: Device 00:0a disabled.
[ 2192.701232] pnp: Device 00:0a activated.
[ 2192.701259]  00:0a: responds at SIR 0x2e8, FIR 0x100
[ 2192.709309] pnp: PnP ACPI: found 12 devices
[ 2192.709351] ACPI: ACPI bus type pnp unregistered

....

[ 2207.986550] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
IrDA chip, pre-configuring device.
[ 2207.986587] Activated ALi 1533 ISA bridge port 0x02e8.
[ 2207.986602] Activated ALi 1533 ISA bridge port 0x02f8.
[ 2207.986817] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): 
LPC47N227
[ 2207.986851] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, 
mode: 0x0e
[ 2207.986873] smsc_ircc_present: can't get sir_base of 0x2e8



[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-08-11 18:39                                                     ` Andrey Borzenkov
@ 2007-08-13 16:09                                                       ` Bjorn Helgaas
  2007-08-13 17:39                                                         ` Peter Stuge
  2007-08-18  6:59                                                         ` Andrey Borzenkov
  0 siblings, 2 replies; 48+ messages in thread
From: Bjorn Helgaas @ 2007-08-13 16:09 UTC (permalink / raw)
  To: Andrey Borzenkov
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

On Saturday 11 August 2007 12:39:35 pm Andrey Borzenkov wrote:
> This stopped working again in 2.6.23-rc. In 2.6.22 we decided to disable PnP 
> by default; it is apparently enabled now and fails to activte IrDA 
> completely. So it moves to post-2.6.22 regressions :)
> 
> let me know which information you need
> 
> [ 2192.666450] pnp: PnP ACPI init
> [ 2192.666589] ACPI: bus type pnp registered
> [ 2192.686035] pnp: Device 00:0a activated.
> [ 2192.686089]  00:0a: SMCf010 not responding at SIR 0x100, FIR 0x2e8; 
> auto-configuring
> [ 2192.687610] pnp: Device 00:0a disabled.
> [ 2192.693179] pnp: Device 00:0a activated.
> [ 2192.693210]  00:0a: not responding at SIR 0x100, FIR 0x2e8; swapping 
> SIR/FIR and reconfiguring
> [ 2192.694720] pnp: Device 00:0a disabled.
> [ 2192.701232] pnp: Device 00:0a activated.
> [ 2192.701259]  00:0a: responds at SIR 0x2e8, FIR 0x100
> [ 2192.709309] pnp: PnP ACPI: found 12 devices
> [ 2192.709351] ACPI: ACPI bus type pnp unregistered
> 
> ....
> 
> [ 2207.986550] Detected unconfigured Toshiba laptop with ALi ISA bridge SMSC 
> IrDA chip, pre-configuring device.
> [ 2207.986587] Activated ALi 1533 ISA bridge port 0x02e8.
> [ 2207.986602] Activated ALi 1533 ISA bridge port 0x02f8.
> [ 2207.986817] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e): 
> LPC47N227
> [ 2207.986851] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq: 7, 
> mode: 0x0e
> [ 2207.986873] smsc_ircc_present: can't get sir_base of 0x2e8

As of 2.6.23-rc2, we should have:
  - probes for 8250 legacy devices (as in 2.6.21 and previous)
  - smsc PNP probes turned off by default (2.6.21 and previous had no
    PNP probes for smsc at all)
  - some complicated PNP quirks for SMCf010 devices

In other words, I think we're basically back where we started.  The 8250
driver should find a ttyS3 device at 0x2e8, and it should claim those
ports, which will prevent smsc from claiming them.

If you use "setserial /dev/ttyS3 none", the 8250 driver should release
the ports at 0x2e8, and then the smsc-ircc2 driver should be able to
load correctly.  I think this is what we always had to do in the past,
right?

If that doesn't work, try removing the body of quirk_smc_enable() in
drivers/pnp/quirks.c in addition.  It's possible that the quirk changes
the config in a way that messes up the smsc-ircc2 probe.

Bjorn

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-08-13 16:09                                                       ` Bjorn Helgaas
@ 2007-08-13 17:39                                                         ` Peter Stuge
  2007-08-18  6:59                                                         ` Andrey Borzenkov
  1 sibling, 0 replies; 48+ messages in thread
From: Peter Stuge @ 2007-08-13 17:39 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrey Borzenkov, Samuel Ortiz, Michal Piotrowski, linux-pcmcia,
	linux-kernel, Linus Walleij (LD/EAB),
	Andrew Morton

On Mon, Aug 13, 2007 at 10:09:46AM -0600, Bjorn Helgaas wrote:
> > [ 2207.986873] smsc_ircc_present: can't get sir_base of 0x2e8
> 
> As of 2.6.23-rc2, we should have:
>   - probes for 8250 legacy devices (as in 2.6.21 and previous)
>   - smsc PNP probes turned off by default (2.6.21 and previous had
>     no PNP probes for smsc at all)
>   - some complicated PNP quirks for SMCf010 devices
> 
> In other words, I think we're basically back where we started.  The
> 8250 driver should find a ttyS3 device at 0x2e8, and it should
> claim those ports, which will prevent smsc from claiming them.

I use 8250.nr_uarts=1 appended to my kernel parameters on my laptop.
Perfectly reliable workaround, but if it is possible to detect, then
all the better!


//Peter

^ permalink raw reply	[flat|nested] 48+ messages in thread

* Re: 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip
  2007-08-13 16:09                                                       ` Bjorn Helgaas
  2007-08-13 17:39                                                         ` Peter Stuge
@ 2007-08-18  6:59                                                         ` Andrey Borzenkov
  1 sibling, 0 replies; 48+ messages in thread
From: Andrey Borzenkov @ 2007-08-18  6:59 UTC (permalink / raw)
  To: Bjorn Helgaas
  Cc: Andrew Morton, Samuel Ortiz, Linus Walleij (LD/EAB),
	linux-kernel, Michal Piotrowski, ambx1, linux-pcmcia

[-- Attachment #1: Type: text/plain, Size: 2888 bytes --]

On Monday 13 August 2007, Bjorn Helgaas wrote:
> On Saturday 11 August 2007 12:39:35 pm Andrey Borzenkov wrote:
> > This stopped working again in 2.6.23-rc. In 2.6.22 we decided to disable
> > PnP by default; it is apparently enabled now and fails to activte IrDA
> > completely. So it moves to post-2.6.22 regressions :)
> >
> > let me know which information you need
> >
> > [ 2192.666450] pnp: PnP ACPI init
> > [ 2192.666589] ACPI: bus type pnp registered
> > [ 2192.686035] pnp: Device 00:0a activated.
> > [ 2192.686089]  00:0a: SMCf010 not responding at SIR 0x100, FIR 0x2e8;
> > auto-configuring
> > [ 2192.687610] pnp: Device 00:0a disabled.
> > [ 2192.693179] pnp: Device 00:0a activated.
> > [ 2192.693210]  00:0a: not responding at SIR 0x100, FIR 0x2e8; swapping
> > SIR/FIR and reconfiguring
> > [ 2192.694720] pnp: Device 00:0a disabled.
> > [ 2192.701232] pnp: Device 00:0a activated.
> > [ 2192.701259]  00:0a: responds at SIR 0x2e8, FIR 0x100
> > [ 2192.709309] pnp: PnP ACPI: found 12 devices
> > [ 2192.709351] ACPI: ACPI bus type pnp unregistered
> >
> > ....
> >
> > [ 2207.986550] Detected unconfigured Toshiba laptop with ALi ISA bridge
> > SMSC IrDA chip, pre-configuring device.
> > [ 2207.986587] Activated ALi 1533 ISA bridge port 0x02e8.
> > [ 2207.986602] Activated ALi 1533 ISA bridge port 0x02f8.
> > [ 2207.986817] found SMC SuperIO Chip (devid=0x5a rev=00 base=0x002e):
> > LPC47N227
> > [ 2207.986851] smsc_superio_flat(): fir: 0x2f8, sir: 0x2e8, dma: 03, irq:
> > 7, mode: 0x0e
> > [ 2207.986873] smsc_ircc_present: can't get sir_base of 0x2e8
>
> As of 2.6.23-rc2, we should have:
>   - probes for 8250 legacy devices (as in 2.6.21 and previous)
>   - smsc PNP probes turned off by default (2.6.21 and previous had no
>     PNP probes for smsc at all)
>   - some complicated PNP quirks for SMCf010 devices
>
> In other words, I think we're basically back where we started.

Nope, it is a regression.

> The 8250 
> driver should find a ttyS3 device at 0x2e8, and it should claim those
> ports, which will prevent smsc from claiming them.
>

This worked in 2.6.22 and does not work in 2.6.23. So something changed. I 
make a separate post about it because it is probably unrelated to smsc.

> If you use "setserial /dev/ttyS3 none", the 8250 driver should release
> the ports at 0x2e8, and then the smsc-ircc2 driver should be able to
> load correctly.  I think this is what we always had to do in the past,
> right?
>

No; it "just worked". I do not even have setserial command ... installed one 
but this does not support "none"

> If that doesn't work, try removing the body of quirk_smc_enable() in
> drivers/pnp/quirks.c in addition.  It's possible that the quirk changes
> the config in a way that messes up the smsc-ircc2 probe.
>

If I unload 8250 smsc-ircc2 loads just fine. 

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

^ permalink raw reply	[flat|nested] 48+ messages in thread

end of thread, other threads:[~2007-08-18  6:59 UTC | newest]

Thread overview: 48+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-03  8:00 2.6.22-rc: regression: no irda0 interface (2.6.21 was OK), smsc does not find chip Andrey Borzenkov
2007-06-03  8:16 ` Andrey Borzenkov
2007-06-03 23:10   ` Samuel Ortiz
2007-06-04  2:33     ` Andrey Borzenkov
2007-06-04 20:44       ` Samuel Ortiz
2007-06-05  3:10         ` Andrey Borzenkov
2007-06-05  7:18           ` Linus Walleij (LD/EAB)
2007-06-05  7:57             ` Samuel Ortiz
2007-06-05 11:57               ` Linus Walleij (LD/EAB)
2007-06-05 13:04                 ` Samuel Ortiz
2007-06-05 23:23                 ` Bjorn Helgaas
2007-06-06  3:29                   ` Andrey Borzenkov
2007-06-06 19:09                     ` Bjorn Helgaas
2007-06-06 20:45                       ` Andrey Borzenkov
2007-06-07 15:52                         ` Bjorn Helgaas
2007-06-07 20:47                           ` Samuel Ortiz
2007-06-10  6:47                             ` Andrey Borzenkov
2007-06-10 21:03                               ` Bjorn Helgaas
2007-06-11 14:04                                 ` Andrey Borzenkov
2007-06-14 21:30                                   ` Bjorn Helgaas
2007-06-15 13:44                                     ` Andrey Borzenkov
2007-06-15 15:19                                       ` Bjorn Helgaas
2007-06-16 16:38                                         ` Andrey Borzenkov
2007-06-19 23:31                                           ` Bjorn Helgaas
2007-06-28  3:56                                             ` Bjorn Helgaas
2007-06-30  2:41                                               ` Bjorn Helgaas
2007-06-30  7:16                                                 ` Andrey Borzenkov
2007-06-30 11:45                                                   ` Bjorn Helgaas
2007-06-30 14:47                                                     ` Andrey Borzenkov
2007-06-30 21:13                                                       ` Andrey Borzenkov
2007-07-01  3:30                                                         ` Bjorn Helgaas
2007-07-01  7:08                                                           ` Andrey Borzenkov
2007-07-01 13:57                                                             ` Bjorn Helgaas
2007-08-11 18:39                                                     ` Andrey Borzenkov
2007-08-13 16:09                                                       ` Bjorn Helgaas
2007-08-13 17:39                                                         ` Peter Stuge
2007-08-18  6:59                                                         ` Andrey Borzenkov
2007-07-01  0:01                                                 ` Michal Piotrowski
2007-07-01  0:04                                                   ` Michal Piotrowski
2007-06-07 18:34                         ` Bjorn Helgaas
2007-06-08  5:24                           ` Andrey Borzenkov
2007-06-10  8:03                           ` Andrey Borzenkov
2007-06-10 20:04                             ` Bjorn Helgaas
2007-06-07 12:23                   ` Linus Walleij (LD/EAB)
2007-06-07 15:44                     ` Bjorn Helgaas
2007-06-05 12:06         ` Linus Walleij (LD/EAB)
2007-06-04 16:34   ` Bjorn Helgaas
2007-06-05  3:08     ` Andrey Borzenkov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).