Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-08 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 08.12.2014 01:00, Charles Devereaux wrote:
 Sorry, but if it is like the X60 it can not be made the work.
 
 Just like in the WWAN slot, but in reverse, the USB lines are not wired
 on the WLAN slot.
 
 IIRC this is not the case on the X201 (a very nice machine, but coreboot
 support may not be as good for the moment. However the ACPI tables look
 more complete.)
 
Please provide problem descriptions when doubting the quality of my
work. Otherwise you're empty-talking.



signature.asc
Description: OpenPGP digital signature
-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-08 Thread Charles Devereaux
Hello

On Mon, Dec 8, 2014 at 3:17 AM, Vladimir 'φ-coder/phcoder' Serbinenko 
phco...@gmail.com wrote:

  IIRC this is not the case on the X201 (a very nice machine, but coreboot
  support may not be as good for the moment. However the ACPI tables look
  more complete.)
 
 Please provide problem descriptions when doubting the quality of my
 work. Otherwise you're empty-talking.


I did not mean that, I should have answered differently.

I meant what he wants to do is not possible on the X60, which is generally
regarded as the non-chromebook laptop with the best coreboot support. If he
really needs that functionality, the next best bet is the X201, a machine
with better specs, and promising coreboot support.

Based on http://www.coreboot.org/Board:lenovo/x201, I can say that the ACPI
tables look more complete since it can boot windows which is very touchy,
while the X60 can't.

To me, That indicate *high quality* work, as I am still exploring several
X60 issues.

But since I do not have a X201, I can not say how it compares to the X60 in
terms of coreboot support (you seem to have one, so please tell me. For
example, is native video init working? I could move to the X201 if it was
not so expansive :-)

PS: I read you did not test the modem. Unless it is a one of the few ALSA
supported modems like the 3054, it won't work The latest versions of
Coreboot have AZALIA support, which will initialise the codec for
snd-hda-intel. If you replace the modem by a ML 3054 (drop it replacement,
ex:
http://www.ebay.com/itm/Asus-F6E-Fax-Modem-w-Cable-ML3054-/380880135505?pt=US_Laptop_Modem_Cards)
it should work with slmodemd (ex:
https://freemor.wordpress.com/2008/05/07/getting-a-si3054-modem-working-on-hardy-heron/).
It does on the X60.
-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-07 Thread Carl-Daniel Hailfinger
On 07.12.2014 04:31, Charles Devereaux wrote:
 It can be powered, since in the X60 the WWAN port only has the USB lines
 wired, so it's not much of a security problem for the PCI bus as long as it
 is not connected to the USB bus where it could wake up from suspend and
 pretend to be many different things.

 The hardware swich properly disconnects the bluetooth module from USB. It
 would be nice to do the same for wwan, but I guess ec_access and echo -n
 suspend are better than nothing. I plan to try and create a rfkill-wwan
 kernel module doing just that. I tried to find some code example for the RCBA
 but couldn't.

Has anyone ever managed to get the USB lines on the T60 WLAN slot to
work? I plugged in an Intel 7260 802.11ac + Bluetooth card, and it is
reportedly using USB for bluetooth and PCIe for WLAN. My problem is that
the Bluetooth part of the card doesn't even show up in lsusb.

This thread made me wonder whether this is just an issue with broken rfkill.

Regards,
Carl-Daniel

-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot


Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-07 Thread Charles Devereaux
Sorry, but if it is like the X60 it can not be made the work.

Just like in the WWAN slot, but in reverse, the USB lines are not wired on
the WLAN slot.

IIRC this is not the case on the X201 (a very nice machine, but coreboot
support may not be as good for the moment. However the ACPI tables look
more complete.)

Most dual (wifi+bt) mini PCIe cards use the PCIe lines for wifi and the USB
lines for bt, which is why you see the wifi in lspci but no bt in lsusb.


On Sun, Dec 7, 2014 at 5:57 PM, Carl-Daniel Hailfinger 
c-d.hailfinger.devel.2...@gmx.net wrote:

 On 07.12.2014 04:31, Charles Devereaux wrote:
  It can be powered, since in the X60 the WWAN port only has the USB lines
  wired, so it's not much of a security problem for the PCI bus as long as
 it
  is not connected to the USB bus where it could wake up from suspend and
  pretend to be many different things.
 
  The hardware swich properly disconnects the bluetooth module from USB. It
  would be nice to do the same for wwan, but I guess ec_access and echo -n
  suspend are better than nothing. I plan to try and create a rfkill-wwan
  kernel module doing just that. I tried to find some code example for the
 RCBA
  but couldn't.

 Has anyone ever managed to get the USB lines on the T60 WLAN slot to
 work? I plugged in an Intel 7260 802.11ac + Bluetooth card, and it is
 reportedly using USB for bluetooth and PCIe for WLAN. My problem is that
 the Bluetooth part of the card doesn't even show up in lsusb.

 This thread made me wonder whether this is just an issue with broken
 rfkill.

 Regards,
 Carl-Daniel

-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-06 Thread Vladimir 'φ-coder/phcoder' Serbinenko
On 03.12.2014 23:32, Charles Devereaux wrote:
 Hello
 
 As explained before, thinkpad-acpi can't control the non-wifi radio like
 bluetooth or wwan, because it expects some ACPI entries that aren't
 there - so there is no rfkill control for these, even if some
 non-working entries are shown with 'rfkill list'
 
You have a hardware button to do an rfkill. I don't see why software
should mess more with this.
 To emulate rfkill functionality, just write directly to the ec, for ex
 to turn on wwan and wifi:
 ./ec_access -w 0x3a -v 0x60
 
Usecase?
 It works great for bluetooth, basically physically unplugging the
 device so that if you have uhci_hcd as a module, an rmmod/modprobe will
 no longer show the device on lsusb.
 
RCBA registers can disable any USB ports. But again: usecase?




signature.asc
Description: OpenPGP digital signature
-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-06 Thread Vladimir 'φ-coder/phcoder' Serbinenko

  To emulate rfkill functionality, just write directly to the ec, for ex
  to turn on wwan and wifi:
  ./ec_access -w 0x3a -v 0x60
 
 Usecase?
 
 
 Example: I have a wwan card, but I mostly use it for GPS. I can save
 some power by turning it off without rebooting, while keeping wifi on with:
I'd like to see some real figures on power saved between idle wwan and
disabled wwan, I really doubt it's anything noticeable
 The hardware button is not safe enough : register 0x3A hasthe H/W
 Override bitto enable to control wireless devices even if the global
 WAN disable switch is ON. Disabling the USB ports through the RCBA
 registers (nice idea!) would prevent such an override.
 
 Also, it would save more power on the wwan that the hardware button :
 the wwan module is not fully desactivated since it replies to AT commands
 
 Several persons do not fully trust a wwan module. Physically removing it
 is the solution suggested. Disabling the usb port would be a simpler
 solution for those than do not want to physically open their laptop yet
 do not trust the hardware button due to the override bit.
 
wwan module is powered unconditionally. So if you don't trust it -
remove it. Also none of disables discussed here is irreversible if
you're concerned about rogue software.
 It seems to have several usecase.
None of them looks valid



signature.asc
Description: OpenPGP digital signature
-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot

Re: [coreboot] rfkill equivalent on the X60 - first partial success

2014-12-06 Thread Charles Devereaux
Hello

On Sat, Dec 6, 2014 at 9:09 PM, Vladimir 'φ-coder/phcoder' Serbinenko 
phco...@gmail.com wrote:

  Example: I have a wwan card, but I mostly use it for GPS. I can save
  some power by turning it off without rebooting, while keeping wifi on
 with:
 I'd like to see some real figures on power saved between idle wwan and
 disabled wwan, I really doubt it's anything noticeable


Correct.

I don't have a x60 with an official wwan module, so can't test how it
works with lenovo bios (saving more or less power?), but from the datasheet
of a Huawei 770, with idle meaning usb connected, and disabled meaning
rfkill (hardware switch or using ec_access to write to the H8) :
 - in idle mode it goes from ~92 mA when it's disabled to about ~100mA when
it's not (I'm using an average of 3G and 2G power consumption, but they
only differ by about 4 mA)
 - when it's suspended, between 3 and 4mA
(tell me if you want a copy of the datasheet. I guess it's similar to other
modules)

So basically, the hardware switch or the ec_access command disable
currently saves 8 mA, about 0.026W at 3.3.V, ie almost nothing, while
properly suspending wwan and not letting it come back in idle mode (or even
disconnecting it from the USB bus) would save 90 mA so 0.330 W, which
starts becoming interesting.

The latter can be already be done with ec_access and echo -n suspend 
/sys/bus/usb/drivers/whatever/power/level, but that's not very user
friendly, and I don't know if the module won't try to wake-up from suspend.

wwan module is powered unconditionally. So if you don't trust it - remove
 it.


It can be powered, since in the X60 the WWAN port only has the USB lines
wired, so it's not much of a security problem for the PCI bus as long as it
is not connected to the USB bus where it could wake up from suspend and
pretend to be many different things.

The hardware swich properly disconnects the bluetooth module from USB. It
would be nice to do the same for wwan, but I guess ec_access and echo -n
suspend are better than nothing. I plan to try and create a rfkill-wwan
kernel module doing just that. I tried to find some code example for the RCBA
but couldn't.
-- 
coreboot mailing list: coreboot@coreboot.org
http://www.coreboot.org/mailman/listinfo/coreboot