summaryrefslogtreecommitdiff
path: root/sys/dev/pci
AgeCommit message (Collapse)Author
2008-10-29dlg says "well, that is embarassing"Theo de Raadt
2008-10-28make DRM_INFO() a bit less gross, though getting all the grossness out at ↵Theo de Raadt
once is impossible; ok oga
2008-10-28#if NVLAN > 0 in one more spot.Brad Smith
2008-10-28Add the MacBookPro4,1 to the list of systems with GPIO quirks andBrad Smith
needs adjustment. Allows the integrated speakers to work. from Alexey Suslikov
2008-10-28#include sensorsMarco Peereboom
2008-10-28Major overhaul of bio.Marco Peereboom
Fix set hotspare that didn't always work. Fix several very subtle bugs because of firmware lies Fix disk size that sometimes was incorrect Only poke drives if something changed so it makes bio way faster on subsequent calls Tested by several folks, thanks Ok dlg
2008-10-28Add beginings of bio. Disabled for now.Marco Peereboom
dlg "go go go"
2008-10-28Implement a workaround for stupid hw when using VLAN stripping. FramesBrad Smith
that are 64 bytes with a VLAN header appended like ARP frames or ICMP echos are flagged as runts when the tag is stripped. Issue mentioned by yongari@FreeBSD, info gleaned from the Linux driver.
2008-10-28Remove #if NVLAN.Brad Smith
2008-10-28Some tweaks for the usage of NVLAN > 0 checks in the code.Brad Smith
2008-10-28Fix up some of the code for VLAN tagging/stripping and checksum offloadBrad Smith
support.
2008-10-28Re-add support for RX VLAN tag stripping.Brad Smith
2008-10-28Don't need NVLAN > 0 checks around this code.Brad Smith
2008-10-28Re-add support TX VLAN tag insertion and RX VLAN tag stripping.Brad Smith
2008-10-28SiS 7012 uses different multichannel control bits (data from linux).Jacob Meuser
makes 4 channel output work for Anathae Townsend. thanks for testing. ok ratchov@
2008-10-28regenBrad Smith
2008-10-28More MCP79 Host bridge PCI ids.Brad Smith
2008-10-28regenBrad Smith
2008-10-28Correct MCP79 SMBus PCI id and add missing MCP79 PCI ids.Brad Smith
2008-10-27Move some include stuff aroundMarco Peereboom
2008-10-27for the AD1984 codec, connect headphones to a proper DAC.Jacob Meuser
tested by danh@ and Aaron Stellman on Thinkpad T61. from Alexey Suslikov, thanks
2008-10-25audio(9) says low level drivers are allowed to change the requestedJacob Meuser
values of the audio_params structure during AUDIO_SETINFO if the hardware cannot be set to exactly the requested mode. some drivers do this sometimes. others always return EINVAL if there isn't an exact match. be more consistent. only return EINVAL if an absurd parameter was requested, otherwise return a supported set of parameters, as close as possible to what was requested. with/ok ratchov@
2008-10-25Add proper DAC/ADC grouping for AD1984 (from NetBSD).Jacob Meuser
This fixes fallout for AD1984 revealed by recent azalia.c changes and reported on misc@. While here: * move gpio_unmute to more logical place, * remove code ifdef'ed and unused for ages. from Alexey Suslikov, thanks Index: sys/dev/pci/azalia_codec.c =================================================================== RCS file: /cvs/src/sys/dev/pci/azalia_codec.c,v retrieving revision 1.52 diff -u -r1.52 azalia_codec.c --- sys/dev/pci/azalia_codec.c 23 Oct 2008 02:23:04 -0000 1.52 +++ sys/dev/pci/azalia_codec.c 24 Oct 2008 17:29:36 -0000 @@ -98,6 +98,7 @@ (const codec_t *, nid_t, int, u_char); int azalia_generic_set_port(codec_t *, mixer_ctrl_t *); int azalia_generic_get_port(codec_t *, mixer_ctrl_t *); +int azalia_gpio_unmute(codec_t *, int); int azalia_alc260_init_dacgroup(codec_t *); int azalia_alc260_mixer_init(codec_t *); @@ -127,7 +128,6 @@ int azalia_stac9221_set_port(codec_t *, mixer_ctrl_t *); int azalia_stac9221_get_port(codec_t *, mixer_ctrl_t *); int azalia_stac9221_apple_unsol_event(codec_t *, int); -int azalia_gpio_unmute(codec_t *, int); int azalia_stac7661_init_dacgroup(codec_t *); int azalia_stac7661_mixer_init(codec_t *); int azalia_stac7661_set_port(codec_t *, mixer_ctrl_t *); @@ -1708,6 +1708,26 @@ return azalia_generic_mixer_get(this, m->nid, m->target, mc); } +int +azalia_gpio_unmute(codec_t *this, int pin) +{ + uint32_t data, mask, dir; + + this->comresp(this, this->audiofunc, CORB_GET_GPIO_DATA, 0, &data); + this->comresp(this, this->audiofunc, CORB_GET_GPIO_ENABLE_MASK, 0, &mask); + this->comresp(this, this->audiofunc, CORB_GET_GPIO_DIRECTION, 0, &dir); + + data |= 1 << pin; + mask |= 1 << pin; + dir |= 1 << pin; + + this->comresp(this, this->audiofunc, CORB_SET_GPIO_ENABLE_MASK, mask, NULL); + this->comresp(this, this->audiofunc, CORB_SET_GPIO_DIRECTION, dir, NULL); + DELAY(1000); + this->comresp(this, this->audiofunc, CORB_SET_GPIO_DATA, data, NULL); + + return 0; +} /* ---------------------------------------------------------------- * Realtek ALC260 @@ -2181,18 +2201,11 @@ int azalia_alc882_init_dacgroup(codec_t *this) { -#if 0 - static const convgroupset_t dacs = { - -1, 3, - {{4, {0x02, 0x03, 0x04, 0x05}}, /* analog 8ch */ - {1, {0x06}}, /* digital */ - {1, {0x25}}}}; /* another analog */ -#else static const convgroupset_t dacs = { -1, 2, {{4, {0x02, 0x03, 0x04, 0x05}}, /* analog 8ch */ {1, {0x06}}}}; /* digital */ -#endif + /* don't support for 0x25 dac */ static const convgroupset_t adcs = { -1, 2, {{3, {0x07, 0x08, 0x09}}, /* analog 6ch */ @@ -2484,13 +2497,14 @@ azalia_ad1984_init_dacgroup(codec_t *this) { static const convgroupset_t dacs = { - -1, 1, - {{2, {0x03, 0x04}}}}; - + -1, 2, + {{2, {0x04, 0x03}}, /* analog 4ch */ + {1, {0x02}}}}; /* digital */ static const convgroupset_t adcs = { - -1, 1, - {{1, {0x08}}}}; - + -1, 3, + {{2, {0x08, 0x09}}, /* analog 4ch */ + {1, {0x06}}, /* digital */ + {1, {0x05}}}}; /* digital */ this->dacs = dacs; this->adcs = adcs; return 0; @@ -3006,27 +3020,6 @@ DPRINTF(("%s: unknown tag: %d\n", __func__, tag)); } return 0; -} - -int -azalia_gpio_unmute(codec_t *this, int pin) -{ - uint32_t data, mask, dir; - - this->comresp(this, this->audiofunc, CORB_GET_GPIO_DATA, 0, &data); - this->comresp(this, this->audiofunc, CORB_GET_GPIO_ENABLE_MASK, 0, &mask); - this->comresp(this, this->audiofunc, CORB_GET_GPIO_DIRECTION, 0, &dir); - - data |= 1 << pin; - mask |= 1 << pin; - dir |= 1 << pin; - - this->comresp(this, this->audiofunc, CORB_SET_GPIO_ENABLE_MASK, mask, NULL); - this->comresp(this, this->audiofunc, CORB_SET_GPIO_DIRECTION, dir, NULL); - DELAY(1000); - this->comresp(this, this->audiofunc, CORB_SET_GPIO_DATA, data, NULL); - - return 0; } /* ----------------------------------------------------------------
2008-10-23S/PDIF output support in ac97(4), auich(4) and auvia(4)Jacob Meuser
from NetBSD tested by a few with no regressions. optical works for jsg@. ok ratchov@
2008-10-23enable 4 and 6 channel support.Jacob Meuser
tested by a few. no regressions, but 4 and 6 channel playback is not working with all codecs yet. ok ratchov@
2008-10-23Don't print redundant information in dmesg.Owain Ainsworth
Prompted by deraadt, kettenis@.
2008-10-23remove some funky charactersjoshua stein
ok oga@
2008-10-23- new function azalia_generic_mixer_pin_sense - configures pin direction,Jacob Meuser
enables EAPD when needed - new function azalia_generic_mixer_create_virtual - creates some well known mixer controls, such as outputs.master - use the two new functions when setting up a codec with the generic codec support - remove explicit pindir manipulations (azalia_generic_mixer_pin_sense does this automatically now) - add some GPIO quirks (from FreeBSD's snd_hda) - move all GPIO quirks into one place - add DAC/ADC groupings and support for several more codecs using the generic codec support - correct Sigmatel STAC9872AK name - initialize unsol_event to NULL by default DAC/ADC grouping and create_virtual/pin_sense code from NetBSD. GPIO quirks from FreeBSD. from Alexey Suslikov, thanks
2008-10-23Sve power. Power down codec if it has no audio function groups.Jacob Meuser
from Alexey Suslikov, thanks
2008-10-22Fix a typo with the VLAN code.Brad Smith
2008-10-22lot of cleanup, small fixes.Damien Bergamini
prepare for future enhancements.
2008-10-22Re-add support TX VLAN tag insertion and RX VLAN tag stripping.Brad Smith
Tested by Dawe <dawedawe at gmx dot de>
2008-10-22Add support TX VLAN tag insertion and RX VLAN tag stripping.Brad Smith
2008-10-22Fix a typo.Brad Smith
2008-10-21Make sure to read the last byte of EEPROM descriptor. PreviouslyBrad Smith
the last byte of the Ethernet address was not read which in turn resulted in getting 5 out of the 6 bytes of Ethernet address and always returning ENOENT. From FreeBSD ok jsg@
2008-10-21Don't bounce transmitted packets up to the BPF listeners twice.Brad Smith
ok jsg@
2008-10-21remove unused variable 'v', unbreaks the treeFelix Kronlage
asked by jsg@
2008-10-21Re-add support for RX VLAN tag stripping.Brad Smith
2008-10-21Re-add support TX VLAN tag insertion and RX VLAN tag stripping.Brad Smith
2008-10-20- Remove sys/cdefs.h header.Brad Smith
- Make use of pci_matchbyid(). - Replace magic number with PCI_MAPREG_START for the PCI BAR. - Remove redundant code to enable PCI bus mastering which is already dealt with by pci_mapreg_map(). ok mikeb@
2008-10-20oops, testing printf shouldn't have been commited.Brad Smith
2008-10-20Enable support for RX checksum offload, RX VLAN tag stripping and TXBrad Smith
VLAN tag insertion. ok jsg@
2008-10-20Remove ioctl handlers for MTU changing and multicast, they're alreadyBrad Smith
handled by ether_ioctl() and simplify the interface flags handler. ok jsg@
2008-10-20typo, regisrers -> registersBrad Smith
2008-10-20- Remove tmp variable sumflags in ti_rxeof() and just stick the csumBrad Smith
Ok flag into the header field, like every other driver. - Move the sanity checks in the packet encapsulation routines up above the for loop since the number of DMA segments is already known and there is no need to count the iterations through the loop. - If the encapsulation routine fails after calling bus_dmamap_load_mbuf() then make sure to unload the DMA map.
2008-10-19Re-add support for RX VLAN tag stripping.Brad Smith
2008-10-19Re-add support for RX VLAN tag stripping.Brad Smith
2008-10-19Re-add support TX VLAN tag insertion and RX VLAN tag stripping.Brad Smith
Tested by naddy@
2008-10-19Re-add support for RX VLAN tag stripping.Brad Smith
Tested by naddy@
2008-10-17Fix permissions on the DRM_I915_HWS_ADDR ioctl, should be master only.Owain Ainsworth
Pointed out by Olaf Kirch, this has been in snaps for two weeks, no problems. ok millert@, deraadt@