aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/ichsmb
Commit message (Collapse)AuthorAgeFilesLines
* ichsmb: defer smbus attach until interrupts are availableYuri Pankov2019-08-291-5/+2
| | | | | | | | | | | | This fixes a "timed sleep before timers are working" panic seen while attaching jedec_dimm(4) instances too early in the boot. Submitted by: ian Reviewed by: hselasky Differential Revision: https://reviews.freebsd.org/D21452 Notes: svn path=/head/; revision=351604
* Add some Cannon Lake chipset IDs.Alexander Motin2019-03-201-0/+2
| | | | | | | | Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com> MFC after: 2 weeks Notes: svn path=/head/; revision=345333
* Add IDs for several missing Intel SMBus controllers.Gavin Atkinson2017-04-021-0/+18
| | | | | | | | Obtained from: Data sheets, Linux defines, local hardware MFH: 2 weeks Notes: svn path=/head/; revision=316413
* ichsmb: switch device_probe() from a large case statement to a lookup table.Gavin Atkinson2017-03-291-113/+75
| | | | | | | | | | The case statement was getting unmanageably large, and I'm about to add several more devices to it. MFC after: 2 weeks Notes: svn path=/head/; revision=316184
* Remove #define PCIS_SERIALBUS_SMBUS_PROGIF, unused since r200091Gavin Atkinson2017-03-281-2/+0
| | | | Notes: svn path=/head/; revision=316113
* Add some device IDs found in my new laptop.Alexander Motin2016-11-091-0/+4
| | | | Notes: svn path=/head/; revision=308464
* Migrate many bus_alloc_resource() calls to bus_alloc_resource_anywhere().Justin Hibbits2016-02-271-4/+4
| | | | | | | | | | | Most calls to bus_alloc_resource() use "anywhere" as the range, with a given count. Migrate these to use the new bus_alloc_resource_anywhere() API. Reviewed by: jhb Differential Revision: https://reviews.freebsd.org/D5370 Notes: svn path=/head/; revision=296137
* ichsmb: add PCI device ID for Intel Sunrise Point-H SMBus controllerEric van Gyzen2016-02-161-0/+4
| | | | | | | | MFC after: 3 days Sponsored by: Dell Inc. Notes: svn path=/head/; revision=295651
* ichsmb: add Intel Wellsburg device ID.Rui Paulo2015-06-101-0/+4
| | | | | | | | | Submitted by: Michael Allen <mallen pi-coral.com> MFC after: 1 week Sponsored by: Pi-Coral, Inc. Notes: svn path=/head/; revision=284248
* ichsmb: remove whitespace.Rui Paulo2015-06-101-2/+2
| | | | Notes: svn path=/head/; revision=284247
* Add Lynx-Point LP smbus controller ID.Takanori Watanabe2015-04-241-0/+4
| | | | Notes: svn path=/head/; revision=281920
* ichsmb: add a device id for the Wildcat Point-LP.Rui Paulo2015-04-061-1/+5
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=281136
* Add bunch of PCI IDs of Intel Wildcat Point (9 Series) chipsets.Alexander Motin2014-11-261-0/+4
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=275101
* Add ID for Intel Avoton SMBus controller.Alexander Motin2013-11-151-0/+4
| | | | Notes: svn path=/head/; revision=258169
* Add new Coleto Creek device support: SATA, SMBus, and Watchdog devices.Jack F Vogel2013-07-191-0/+4
| | | | | | | MFC after: 1 week Notes: svn path=/head/; revision=253475
* Add Intel Lynx Point PCH SMBus Device IDsJack F Vogel2013-01-021-0/+4
| | | | Notes: svn path=/head/; revision=244981
* - There's no need to overwrite the default device method with the defaultMarius Strobl2011-11-221-4/+2
| | | | | | | | | | | | | one. Interestingly, these are actually the default for quite some time (bus_generic_driver_added(9) since r52045 and bus_generic_print_child(9) since r52045) but even recently added device drivers do this unnecessarily. Discussed with: jhb, marcel - While at it, use DEVMETHOD_END. Discussed with: jhb - Also while at it, use __FBSDID. Notes: svn path=/head/; revision=227843
* Revert r224736 as the introduced value was already present.Attilio Rao2011-08-091-2/+0
| | | | | | | | Reported by: tinderbox, pluknet Approved by: re (kib) Notes: svn path=/head/; revision=224745
* Add the PCI ID for the PCH DH89xxCC on ichsmb as got from Linux counterpart.Attilio Rao2011-08-091-0/+2
| | | | | | | | | | Sponsored by: Sandvine Incorporated Reviewed by: emaste, rstone Approved by: re (bz) MFC after: 3 days Notes: svn path=/head/; revision=224736
* Chipset support for the new Intel Panther Point PCH, thanksJack F Vogel2011-05-111-0/+4
| | | | | | | to Seth Heasley for preparing the changes. Notes: svn path=/head/; revision=221789
* Support for the new Patsburg PCH chipset:Jack F Vogel2011-02-011-0/+4
| | | | | | | | | | | | | | - SMBus Controller - SATA Controller - HD Audio Controller - Watchdog Controller Thanks to Seth Heasley (seth.heasley@intel.com) for providing us code. MFC after 3 days Notes: svn path=/head/; revision=218149
* Support for the new DH89xxCC PCH chipset including:Jack F Vogel2011-01-311-0/+4
| | | | | | | | | - SATA controller - Watchdog timer - SMBus controller Notes: svn path=/head/; revision=218140
* Add support for Intel Cougar Point SMBus controller.Jack F Vogel2010-08-271-0/+4
| | | | | | | MFC afer 1 week Notes: svn path=/head/; revision=211905
* ichsmb: add another pci idAndriy Gapon2009-12-161-0/+4
| | | | | | | | | | | | This is SMBus controller found in Intel Platform Controller Hub (PCH), which is a general name that refers to Intel 5 Series chipsets and 3400 Series chipsets. Submitted by: Dmitry S. Luhtionov <mitya@cabletv.dp.ua> MFC after: 3 days Notes: svn path=/head/; revision=200602
* ichsmb: drop default attachment to generic smbus hardwareAndriy Gapon2009-12-041-8/+0
| | | | | | | | | | | Attach only to devices known to be supported. This change overrided and undoes r200053. Suggested by: jhb MFC after: 2 weeks (only to stable/8) Notes: svn path=/head/; revision=200091
* ichsmb: try attaching only to intel hardware in the default caseAndriy Gapon2009-12-031-2/+4
| | | | | | | | | | | | | Ideally we should attempt attaching only to known supported devices. But I am not sure that we have all supported PCI IDs already listed, and I am too young to die, err, I don't want to take the heat from causing a trouble to someone. MFC after: 1 week X-ToDo: drop the default case Notes: svn path=/head/; revision=200053
* ichsmb: add pci ids for some newer supported hardwareAndriy Gapon2009-12-031-0/+12
| | | | | | | | Submitted by: Dmitry S. Luhtionov <mitya@cabletv.dp.ua> MFC after: 5 days Notes: svn path=/head/; revision=200052
* - Change ichsmb(4) to follow the format of all the other smbus controllersJohn Baldwin2009-02-031-10/+10
| | | | | | | | | | | | | | | | for slave addressing by using left-adjusted slave addresses (i.e. xxxxxxx0b). - Require the low bit of the slave address to always be zero in smb(4) to help catch broken applications. - Adjust some code in the IPMI driver to not convert the slave address for SSIF to a right-adjusted address. I (or possibly ambrisko@) added this in the past to (unknowingly) work around the bug in ichsmb(4). Submitted by: Andriy Gapon <avg of icyb.net.ua> (1,2) MFC after: 1 month Notes: svn path=/head/; revision=188077
* - Use bus_foo() rather than bus_space_foo() and remove bus space tag/handleJohn Baldwin2008-06-063-67/+63
| | | | | | | | | from softc. - Mark interrupt handlers MPSAFE as these drivers have been locked for a while. Notes: svn path=/head/; revision=179622
* Add the Intel 82801FB (ICH6) SMBus controller and theRemko Lodder2007-11-261-0/+8
| | | | | | | | | | | | | | | Intel 82801GB (ICH7) SMBus controller. PR: 85106 [1] PR: 99663 [2] Approved by: imp (mentor), jhb Submitted by: Oliver Fromme <olli at lurza.secnetix dot de>, [1] Arthur Hartwig <arthur dot hartwig at nokia dot com>, [1] Lowell Gilbert <lgfbsd at be-well dot ilk dot org> [2]@ MFC After: 3 days Notes: svn path=/head/; revision=173953
* o break newbus api: add a new argument of type driver_filter_t toPaolo Pisati2007-02-231-1/+1
| | | | | | | | | | | | | | | | bus_setup_intr() o add an int return code to all fast handlers o retire INTR_FAST/IH_FAST For more info: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=465712+0+current/freebsd-current Reviewed by: many Approved by: re@ Notes: svn path=/head/; revision=166901
* Add a device ID for the 631xESB/6321ESB SMBus controller.John Baldwin2007-01-111-0/+4
| | | | | | | Submitted by: Reed A. Cartwright <reed scit.us> Notes: svn path=/head/; revision=165958
* Various updates to most of the smbus(4) drivers:John Baldwin2007-01-112-45/+35
| | | | | | | | | | | | | | | | | | | | | - Use printf() and device_printf() instead of log() in ichsmb(4). - Create the mutex sooner during ichsmb(4) attach. - Attach the interrupt handler later during ichsmb(4) attach to avoid races. - Don't try to set PCIM_CMD_PORTEN in ichsmb(4) attach as the PCI bus driver does this already. - Add locking to alpm(4), amdpm(4), amdsmb(4), intsmb(4), nfsmb(4), and viapm(4). - Axe ALPM_SMBIO_BASE_ADDR, it's not really safe to write arbitrary values into BARs, and the PCI bus layer will allocate resources now if needed. - Merge intpm(4) and intsmb(4) into just intsmb(4). Previously, intpm(4) attached to the PCI device and created an intsmb(4) child. Now, intsmb(4) just attaches to PCI directly. - Change several intsmb functions to take a softc instead of a device_t to make things simpler. Notes: svn path=/head/; revision=165951
* Minor overhaul of SMBus support:John Baldwin2006-09-111-12/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Change smbus_callback() to pass a void * rather than caddr_t. - Change smbus_bread() to pass a pointer to the count and have it be an in/out parameter. The input is the size of the buffer (same as before), but on return it will contain the actual amount of data read back from the bus. Note that this value may be larger than the input value. It is up to the caller to treat this as an error if desired. - Change the SMB_BREAD ioctl to write out the updated struct smbcmd which will contain the actual number of bytes read in the 'count' field. To preserve the previous ABI, the old ioctl value is mapped to SMB_OLD_BREAD which doesn't copy the updated smbcmd back out to userland. I doubt anyone actually used the old BREAD anyway as it was rediculous to do a bulk-read but not tell the using program how much data was actually read. - Make the smbus driver and devclass public in the smbus module and push all the DRIVER_MODULE()'s for attaching the smbus driver to various foosmb drivers out into the foosmb modules. This makes all the foosmb logic centralized and allows new foosmb modules to be self-contained w/o having to hack smbus.c everytime a new smbus driver is added. - Add a new SMB_EINVAL error bit and use it in place of EINVAL to return an error for bad arguments (such as invalid counts for bread and bwrite). - Map SMB bus error bits to EIO in smbus_error(). - Make the smbus driver call bus_generic_probe() and require child drivers such as smb(4) to create device_t's via identify routines. Previously, smbus just created one anonymous device during attach, and if you had multiple drivers that could attach it was just random chance as to which driver got to probe for the sole device_t first. - Add a mutex to the smbus(4) softc and use it in place of dummy splhigh() to protect the 'owner' field and perform necessary synchronization for smbus_request_bus() and smbus_release_bus(). - Change the bread() and bwrite() methods of alpm(4), amdpm(4), and viapm(4) to only perform a single transaction and not try to use a loop of multiple transactions for a large request. The framing and commands to use for a large transaction depend on the upper-layer protocol (such as SSIF for IPMI over SMBus) from what I can tell, and the smb(4) driver never allowed bulk read/writes of more than 32-bytes anyway. The other smb drivers only performed single transactions. - Fix buffer overflows in the bread() methods of ichsmb(4), alpm(4), amdpm(4), amdsmb(4), intpm(4), and nfsmb(4). - Use SMB_xxx errors in viapm(4). - Destroy ichsmb(4)'s mutex after bus_generic_detach() to avoid problems from child devices making smb upcalls that would use the mutex during their detach methods. MFC after: 1 week Reviewed by: jmg (mostly) Notes: svn path=/head/; revision=162234
* This signal handling code is worse than a no-op. If aBrian Somers2006-01-031-6/+1
| | | | | | | | | | | | | signal is received during the msleep, the msleep is retried indefinitely as it just keeps returning ERESTART because of the pending signal. Instead, just don't PCATCH - the signal can wait. Sponsored by: Sophos/ActiveState Notes: svn path=/head/; revision=153993
* Make ichsmb unloadable.Brian Somers2005-07-292-8/+3
| | | | | | | | | | | It seems that the unload problems were due to a dodgy sc->smb usage and a missing mtx_destroy(). Sponsored by: ActiveState/Sophos MFC after: 3 weeks Notes: svn path=/head/; revision=148497
* Make ichsmb(4) child device handling properly.Takanori Watanabe2005-06-103-8/+31
| | | | Notes: svn path=/head/; revision=147253
* Make ichsmb loadable.Takanori Watanabe2005-06-051-0/+3
| | | | | | | | PR: kern/81912 Submitted by: nork Notes: svn path=/head/; revision=146996
* Use BUS_PROBE_DEFAULT for pci probe return valueWarner Losh2005-03-052-2/+2
| | | | Notes: svn path=/head/; revision=143160
* netchild's mega-patch to isolate compiler dependencies into a centralJoerg Wunsch2005-03-021-1/+1
| | | | | | | | | | | | | | | | | | | place. This moves the dependency on GCC's and other compiler's features into the central sys/cdefs.h file, while the individual source files can then refer to #ifdef __COMPILER_FEATURE_FOO where they by now used to refer to #if __GNUC__ > 3.1415 && __BARC__ <= 42. By now, GCC and ICC (the Intel compiler) have been actively tested on IA32 platforms by netchild. Extension to other compilers is supposed to be possible, of course. Submitted by: netchild Reviewed by: various developers on arch@, some time ago Notes: svn path=/head/; revision=143063
* Start each of the license/copyright comments with /*-, minor shuffle of linesWarner Losh2005-01-063-6/+3
| | | | Notes: svn path=/head/; revision=139749
* Add PCI Device ID for 6300ESB ICH. If allocating 16 bytes fails then try 32.Doug Ambrisko2004-06-241-0/+7
| | | | | | | This is also require for 6300ESB. Notes: svn path=/head/; revision=131070
* Add missing <sys/module.h> includesPoul-Henning Kamp2004-05-301-0/+1
| | | | Notes: svn path=/head/; revision=129879
* Convert callers to the new bus_alloc_resource_any(9) API.Nate Lawson2004-03-171-2/+2
| | | | | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde Notes: svn path=/head/; revision=127135
* These are changes to allow to use the Intel C/C++ compiler (lang/icc)Tom Rhodes2004-03-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | to build the kernel. It doesn't affect the operation if gcc. Most of the changes are just adding __INTEL_COMPILER to #ifdef's, as icc v8 may define __GNUC__ some parts may look strange but are necessary. Additional changes: - in_cksum.[ch]: * use a generic C version instead of the assembly version in the !gcc case (ASM code breaks with the optimizations icc does) -> no bad checksums with an icc compiled kernel Help from: andre, grehan, das Stolen from: alpha version via ppc version The entire checksum code should IMHO be replaced with the DragonFly version (because it isn't guaranteed future revisions of gcc will include similar optimizations) as in: ---snip--- Revision Changes Path 1.12 +1 -0 src/sys/conf/files.i386 1.4 +142 -558 src/sys/i386/i386/in_cksum.c 1.5 +33 -69 src/sys/i386/include/in_cksum.h 1.5 +2 -0 src/sys/netinet/igmp.c 1.6 +0 -1 src/sys/netinet/in.h 1.6 +2 -0 src/sys/netinet/ip_icmp.c 1.4 +3 -4 src/contrib/ipfilter/ip_compat.h 1.3 +1 -2 src/sbin/natd/icmp.c 1.4 +0 -1 src/sbin/natd/natd.c 1.48 +1 -0 src/sys/conf/files 1.2 +0 -1 src/sys/conf/files.amd64 1.13 +0 -1 src/sys/conf/files.i386 1.5 +0 -1 src/sys/conf/files.pc98 1.7 +1 -1 src/sys/contrib/ipfilter/netinet/fil.c 1.10 +2 -3 src/sys/contrib/ipfilter/netinet/ip_compat.h 1.10 +1 -1 src/sys/contrib/ipfilter/netinet/ip_fil.c 1.7 +1 -1 src/sys/dev/netif/txp/if_txp.c 1.7 +1 -1 src/sys/net/ip_mroute/ip_mroute.c 1.7 +1 -2 src/sys/net/ipfw/ip_fw2.c 1.6 +1 -2 src/sys/netinet/igmp.c 1.4 +158 -116 src/sys/netinet/in_cksum.c 1.6 +1 -1 src/sys/netinet/ip_gre.c 1.7 +1 -2 src/sys/netinet/ip_icmp.c 1.10 +1 -1 src/sys/netinet/ip_input.c 1.10 +1 -2 src/sys/netinet/ip_output.c 1.13 +1 -2 src/sys/netinet/tcp_input.c 1.9 +1 -2 src/sys/netinet/tcp_output.c 1.10 +1 -1 src/sys/netinet/tcp_subr.c 1.10 +1 -1 src/sys/netinet/tcp_syncache.c 1.9 +1 -2 src/sys/netinet/udp_usrreq.c 1.5 +1 -2 src/sys/netinet6/ipsec.c 1.5 +1 -2 src/sys/netproto/ipsec/ipsec.c 1.5 +1 -1 src/sys/netproto/ipsec/ipsec_input.c 1.4 +1 -2 src/sys/netproto/ipsec/ipsec_output.c and finally remove sys/i386/i386 in_cksum.c sys/i386/include in_cksum.h ---snip--- - endian.h: * DTRT in C++ mode - quad.h: * we don't use gcc v1 anymore, remove support for it Suggested by: bde (long ago) - assym.h: * avoid zero-length arrays (remove dependency on a gcc specific feature) This change changes the contents of the object file, but as it's only used to generate some values for a header, and the generator knows how to handle this, there's no impact in the gcc case. Explained by: bde Submitted by: Marius Strobl <marius@alchemy.franken.de> - aicasm.c: * minor change to teach it about the way icc spells "-nostdinc" Not approved by: gibbs (no reply to my mail) - bump __FreeBSD_version (lang/icc needs to know about the changes) Incarnations of this patch survive gcc compiles since a loooong time, I use it on my desktop. An icc compiled kernel works since Nov. 2003 (exceptions: snd_* if used as modules), it survives a build of the entire ports collection with icc. Parts of this commit contains suggestions or submissions from Marius Strobl <marius@alchemy.franken.de>. Reviewed by: -arch Submitted by: netchild Notes: svn path=/head/; revision=126891
* Update the comment to indicate ICH5 supportNate Lawson2003-08-311-1/+1
| | | | Notes: svn path=/head/; revision=119618
* Add support for the 82801EB (ICH5) SMBus controller.Nate Lawson2003-08-311-0/+4
| | | | | | | | | PR: kern/55485 Submitted by: Shin-ichi Yoshimoto <yosimoto@waishi.jp> MFC after: 1 day Notes: svn path=/head/; revision=119600
* Use __FBSDID().David E. O'Brien2003-08-242-10/+10
| | | | | | | Also some minor style cleanups. Notes: svn path=/head/; revision=119418
* Prefer new location of pci include files (which have only been in theWarner Losh2003-08-221-2/+2
| | | | | | | | tree for two or more years now), except in a few places where there's code to be compatible with older versions of FreeBSD. Notes: svn path=/head/; revision=119280
* typo.Yoshihiro Takahashi2002-10-181-4/+4
| | | | | | | | Submitted by: SAWADA Hodaka <hoda@tail.gr.jp> MFC after: 1 day Notes: svn path=/head/; revision=105394