[ltp] Re: Gen 2 (Haswell) X1 Carbon suspend to RAM hang

Nikos Alexandris linux-thinkpad@linux-thinkpad.org
Mon, 22 Sep 2014 13:40:45 +0300


On 22.09.2014 13:27, Bj=C3=B8rn Mork wrote:
> Nikos Alexandris <nik@nikosalexandris.net> writes:
>
>> ..
>>
>> Bj=C3=B8rn:
>>
>>>> Maybe it's conflicting with some other unrelated change?
>>
>> Nikos:
>>
>>> So, I should simply try to force
>>> applying the patch? And even then, the "old" method of `rmmdod
>>> thinkpad_acpi` responds always with "rmmod: ERROR: Module
>>> thinkpad_acpi is in use".
>>
>>> I have the source and the headers of linux-3.14.19 beforehand.
>>> Though, I am running on
>>>
>>>=20
>>> <https://github.com/fearedbliss/bliss-overlay/blob/master/sys-kernel/=
bliss-kernel/bliss-kernel-3.14.19.ebuild>.
>>
>> So, here is some attempt:
>>
>> --%<---
>> tpx1c2g linux-3.14.19 # patch -p1 < /tmp/foo
>> patching file drivers/platform/x86/thinkpad_acpi.c
>> Reversed (or previously applied) patch detected!  Assume -R? [n] n
>> Apply anyway? [n] y
>> Hunk #1 succeeded at 3537 with fuzz 1 (offset 100 lines).
>> Hunk #2 FAILED at 3556.
>> 1 out of 2 hunks FAILED -- saving rejects to file
>> drivers/platform/x86/thinkpad_acpi.c.rej
>> patch unexpectedly ends in middle of line
>> --->%--
>>
>> and
>>
>> --%<---
>> cat drivers/platform/x86/thinkpad_acpi.c.rej
>> --- drivers/platform/x86/thinkpad_acpi.c
>> +++ drivers/platform/x86/thinkpad_acpi.c
>> @@ -3556,6 +3656,8 @@
>>                         *ignore_acpi_ev =3D true;
>>                 }
>>                 return true;
>> +       } else {
>> +               return
>> adaptive_keyboard_hotkey_notify_hotkey(scancode);
>>         }
>>         return false;
>>  }
>> --->%--
>
> So this failed hunk looks like something that should be fairly easy=20
> to
> add by hand.  Just open the drivers/platform/x86/thinkpad_acpi.c=20
> file,
> go look for whatever is there around line 3556 and add that
> "else return ..." block at the right spot.  Finding that might need a
> little more context than you have here.  I'd take a look at the=20
> original
> patch and/or v3.15 version of the driver to make sure I got it right.

Hmm, thank you.


> But it seems easier to just go for a v3.15 or v3.16 kernel...
> Considered that?

Yes, considered. But I use zfs for which the bliss-kernel mentioned=20
above has integrated support. Don't know if it's going to be=20
straitforward using another kernel right now -- not too much time to=20
investigate. Maybe it's as easy as it sounds, just add zfs support and=20
compile :-).

Nikos