From: Paulo Sergio <pstglia@gmail.com>
To: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Cc: alsa-devel@alsa-project.org, vinod.koul@intel.com,
broonie@opensource.wolfsonmicro.com,
Android-x86 development <android-x86-devel@googlegroups.com>,
Chih-Wei Huang <cwhuang@android-x86.org>,
Charles Keepax <ckeepax@opensource.wolfsonmicro.com>,
mika.westerberg@linux.intel.com
Subject: Re: WM5102 - Help to make baytrail machine driver work
Date: Thu, 18 May 2017 09:49:53 -0300 [thread overview]
Message-ID: <CAJcYhpb+cdC-Cro41qA0aTgEk4prrOGo0=xEuDCDsq+ksdPs+A@mail.gmail.com> (raw)
In-Reply-To: <CAJcYhpYwo0g3+xwSbVo6QWQVH9iGCvO-aLWUOphX4H3gVWZHRw@mail.gmail.com>
Hi Pierre / List, how are you?
2017-05-15 10:10 GMT-03:00 Paulo Sergio <pstglia@gmail.com>:
> Hi Pierre
>
>
> Em 15/05/2017 09:44, "Pierre-Louis Bossart"
> <pierre-louis.bossart@linux.intel.com> escreveu:
>
> On 5/13/17 12:11 AM, Paulo Sergio wrote:
>>>
>>> * This device (Lenovo Yoga 2 1051F) is a bytcr device. However bios
>>> status returned by iosf_mbi_read is
>>> 1000000001000000000000101000000 (bits 26:27 disabled).
>>> Had to force bytcr flag to be true in order to apply correct MCLK
>>> frequency (25Mhz) and use SSP0
>
>
>> Are you sure it's Baytrail-CR? where does this information come from?
>> Those fields are tied to which PMIC is used and it would be extremely
>> surprising to have a disconnect.
>
>
> Sorry, I should have said that I assumed it is a Baytrail CR device because
> these features:
>
> * it's a Z3745 soc
> * acpi_ipc_irq_index used is 0 (0x1D is the 1st index listed on dsdt, just
> like other bytcr devices)
> * ssp0 is being used on this device, not ssp2
> * it has a 25mhz clk
>
> But these are not enough to state it is a bytcr right?
I tried to find some info/document on web that shows if Z3745 is a CR
device or not, but I couldn't (comparing the launch price with other
BYT released at the same date, like Z3735G/F, it is not - however,
features match the criteria of bytcr like ssp0, acpi_ipc_irq_index,
etc )
In any case, in order to use &bytcr_rvp_platform_data, I was thinking
to add a quirk to this device. Do you think something like this would
be accepted as a patch?
--- a/sound/soc/intel/atom/sst/sst_acpi.c
+++ b/sound/soc/intel/atom/sst/sst_acpi.c
@@ -404,6 +404,7 @@ static unsigned long cht_machine_id;
#define CHT_SURFACE_MACH 1
#define BYT_THINKPAD_10 2
+#define BYT_LENOVO_YOGA2 3
static int cht_surface_quirk_cb(const struct dmi_system_id *id)
{
@@ -404,6 +404,7 @@ static unsigned long cht_machine_id;
#define CHT_SURFACE_MACH 1
#define BYT_THINKPAD_10 2
+#define BYT_LENOVO_YOGA2 3
static int cht_surface_quirk_cb(const struct dmi_system_id *id)
{
{
@@ -417,6 +418,12 @@ static int byt_thinkpad10_quirk_cb(const struct
dmi_system_id *id)
return 1;
}
+static int byt_yoga2_quirk_cb(const struct dmi_system_id *id)
+{
+ cht_machine_id = BYT_LENOVO_YOGA2;
+ return 1;
+}
+
static const struct dmi_system_id byt_table[] = {
{
@@ -426,6 +433,13 @@ static const struct dmi_system_id byt_table[] = {
DMI_MATCH(DMI_PRODUCT_NAME, "20C3001VHH"),
},
},
+ {
+ .callback = byt_yoga2_quirk_cb,
+ .matches = {
+ DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
+ DMI_MATCH(DMI_CHASSIS_VERSION, "1051F"),
+ },
+ },
{ }
};
@@ -440,7 +454,6 @@ static const struct dmi_system_id cht_table[] = {
{ }
};
-
static struct sst_acpi_mach cht_surface_mach = {
"10EC5640", "cht-bsw-rt5645", "intel/fw_sst_22a8.bin", "cht-bsw", NULL,
&chv_platform_data };
@@ -449,6 +462,14 @@ static struct sst_acpi_mach byt_thinkpad_10 = {
"10EC5640", "cht-bsw-rt5672", "intel/fw_sst_0f28.bin", "cht-bsw", NULL,
&byt_rvp_platform_data };
+static struct sst_acpi_mach byt_thinkpad_10 = {
+ "10EC5640", "cht-bsw-rt5672", "intel/fw_sst_0f28.bin", "cht-bsw", NULL,
+
&byt_rvp_platform_data };
+
+static struct sst_acpi_mach byt_lenovo_yoga2 = {
+ {"WM510204", "bytcr_wm5102", "intel/fw_sst_0f28.bin",
"bytcr_wm5102", NULL,
+
&bytcr_rvp_platform_data };
+
static struct sst_acpi_mach *cht_quirk(void *arg)
{
struct sst_acpi_mach *mach = arg;
@@ -469,6 +490,8 @@ static struct sst_acpi_mach *byt_quirk(void *arg)
if (cht_machine_id == BYT_THINKPAD_10)
return &byt_thinkpad_10;
+ else if (cht_machine_id == BYT_LENOVO_YOGA2)
+ return &byt_lenovo_yoga2;
else
return mach;
next prev parent reply other threads:[~2017-05-18 12:49 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CAJcYhpZU-6_AO_Gye1VttuvOP0Z2=wLuWGCOP7tBWc6DsuLU1g@mail.gmail.com>
2016-05-05 3:15 ` WM5102 - Help to make baytrail machine driver work Pierre-Louis Bossart
2016-05-07 3:40 ` Paulo Sergio
2016-05-05 9:11 ` Charles Keepax
2016-05-07 3:19 ` Paulo Sergio
2016-05-08 11:44 ` Paulo Sergio
2016-05-09 14:22 ` Charles Keepax
2016-05-13 2:54 ` Paulo Sergio
2016-05-13 11:41 ` Charles Keepax
2016-05-14 23:14 ` Paulo Sergio
2016-05-15 10:13 ` Charles Keepax
[not found] ` <CAJcYhpaFiDrMYmbS1cUWL=ix-L2crjnNekpCXjjdHVThwp2Xag@mail.gmail.com>
[not found] ` <20170508082422.GJ1594@localhost.localdomain>
2017-05-09 0:57 ` Paulo Sergio
2017-05-09 3:15 ` Pierre-Louis Bossart
2017-05-09 14:45 ` Paulo Sergio
2017-05-09 14:57 ` Pierre-Louis Bossart
2017-05-10 8:21 ` Charles Keepax
2017-05-13 5:11 ` Paulo Sergio
2017-05-15 12:02 ` Charles Keepax
2017-05-15 12:44 ` Pierre-Louis Bossart
2017-05-15 13:10 ` Paulo Sergio
2017-05-18 12:49 ` Paulo Sergio [this message]
2017-05-18 14:58 ` Pierre-Louis Bossart
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJcYhpb+cdC-Cro41qA0aTgEk4prrOGo0=xEuDCDsq+ksdPs+A@mail.gmail.com' \
--to=pstglia@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=android-x86-devel@googlegroups.com \
--cc=broonie@opensource.wolfsonmicro.com \
--cc=ckeepax@opensource.wolfsonmicro.com \
--cc=cwhuang@android-x86.org \
--cc=mika.westerberg@linux.intel.com \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=vinod.koul@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).