Page MenuHomeFreeBSD

snd_hda(4): Add quirks for Lenovo ThinkBooks and ASUS TUFs
Needs ReviewPublic

Authored by wulf on Fri, Feb 14, 9:57 AM.

Details

Reviewers
christos
Summary

Includes pin configuration and generic quirks for ALC255 - ALC257
codecs initialization.

Sponsored by: Future Crew, LLC
MFC after: 1 month

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 62483
Build 59367: arc lint + arc unit

Event Timeline

wulf requested review of this revision.Fri, Feb 14, 9:57 AM

The commit message says "ALC257 codecs initialization", but in hdaa_patch_direct() and in pin_patch_realtek.h we seem to be affecting other codecs as well. Shouldn't the commit message reflect that?

My HDA card also is ALC257, so I will make sure to test the patch ASAP.

sys/dev/sound/pci/hda/hdaa_patches.c
330

According to snd_hda.4:

loc      Connector physical location.  Can be specified as a number
         from 0 to 63.  This is a reference only value.  It is
         ignored by the snd_hda driver.

So I suppose these are not a functional changes, right?

716

I think we could simply call hdaa_read_coef() here.

720

And hdaa_write_coef() here. Or did you intentionally duplicate them?

770

Just out of curiosity, what does this do exactly? :-)

793

Stray newline.

The commit message says "ALC257 codecs initialization", but in hdaa_patch_direct() and in pin_patch_realtek.h we seem to be affecting other codecs as well. Shouldn't the commit message reflect that?

It is a typo. Must be ALC255 - ALC257. Fixed

wulf marked an inline comment as done.

Fix description and stray newline

wulf marked an inline comment as done.Mon, Feb 17, 8:04 AM
wulf added inline comments.
sys/dev/sound/pci/hda/hdaa_patches.c
330

It is a cosmetic change only

720

Yes it is duplicated intentionally to be distinct from Linux where this function originated.

770

It is required to dig through the bunch of Realtek commits to alc256_init() function in Linux kernel.
The only thing I need is a patch to enable jack's mic on ASUS TUF. But I ported more tweaks while was here.

sys/dev/sound/pci/hda/hdaa_patches.c
720

Right. Is there a reason we wouldn't want to use them here though? Maybe I'm missing something.

770

Are any of these tweaks worth noting either in a comment or in the commit message?