Re: Fix tuchpad wakeup on ASUS laptops (was [PATCH] Input: /input/mouse/elan_i2c_core.c)

2016-08-02 Thread Vlad Glagolev
>  {
> > int error;
> >  
> > @@ -252,17 +273,24 @@ static int elan_query_device_info(struct elan_tp_data 
> > *data)
> > if (error)
> > return error;
> >  
> > -   error = data->ops->get_version(data->client, false, &data->fw_version);
> > +   error = data->ops->get_sm_version(data->client, &data->ic_type,
> > + &data->sm_version);
> > if (error)
> > return error;
> >  
> > -   error = data->ops->get_checksum(data->client, false,
> > -   &data->fw_checksum);
> > +   return 0;
> > +}
> > +
> > +static int elan_query_device_info(struct elan_tp_data *data)
> > +{
> > +   int error;
> > +
> > +   error = data->ops->get_version(data->client, false, &data->fw_version);
> > if (error)
> > return error;
> >  
> > -   error = data->ops->get_sm_version(data->client, &data->ic_type,
> > - &data->sm_version);
> > +   error = data->ops->get_checksum(data->client, false,
> > +   &data->fw_checksum);
> > if (error)
> > return error;
> >  
> > @@ -419,6 +447,7 @@ static int elan_update_firmware(struct elan_tp_data 
> > *data,
> > data->ops->iap_reset(client);
> > } else {
> > /* Reinitialize TP after fw is updated */
> > +   elan_query_device_pid_smver(data);
> > elan_initialize(data);
> > elan_query_device_info(data);
> > }
> > @@ -757,6 +786,22 @@ out:
> > return retval;
> >  }
> >  
> > +static int check_ASUS_special_fw(struct elan_tp_data *data)
> > +{
> > +   if (data->ic_type != 0x0E)
> > +   return false;
> > +
> > +   switch (data->product_id) {
> > +   case 0x05:
> > +   case 0x06:
> > +   case 0x07:
> > +   case 0x09:
> > +   case 0x013:
> > +   return true;
> > +   default:
> > +   return false;
> > +   }
> > +}
> >  
> >  static DEVICE_ATTR_WO(acquire);
> >  static DEVICE_ATTR_RO(min);
> > @@ -1033,6 +1078,10 @@ static int elan_probe(struct i2c_client *client,
> > return error;
> > }
> >  
> > +   error = elan_query_device_pid_smver(data);
> > +   if (error)
> > +   return error;
> 
> The original code was fetching product ID and IC type after calling the
> transport "initialize" function; I'd prefer if we kept this order.
> 
> Could you tell me if the following version of the patch looks OK to you?
> 
> Vlad, Chris, Jonathan, could you please tell me if this version of the
> patch fixes your touchpad issue?
> 
> Thanks!
> 
> -- 
> Dmitry
> 
> 
> Input: elan_i2c - properly wake up touchpad on ASUS laptops
> 
> From: KT Liao 
> 
> Some ASUS laptops were shipped with touchpads that require to be woken up
> first, before trying to switch them into absolute reporting mode, otherwise
> touchpad would fail to work while flooding the logs with:
> 
>   elan_i2c i2c-ELAN1000:00: invalid report id data (1)
> 
> Among affected devices are Asus E202SA, N552VW, X456UF, UX305CA, and
> others. We detect such devices by checking the IC type and product ID
> numbers and adjusting order of operations accordingly.
> 
> Signed-off-by: KT Liao 
> Reported-by: Chris Chiu 
> Reported-by: Vlad Glagolev 
> Cc: sta...@vger.kernel.org
> Signed-off-by: Dmitry Torokhov 
> ---
>  drivers/input/mouse/elan_i2c_core.c |   79 
> ---
>  1 file changed, 63 insertions(+), 16 deletions(-)
> 
> diff --git a/drivers/input/mouse/elan_i2c_core.c 
> b/drivers/input/mouse/elan_i2c_core.c
> index 2f58985..d15b338 100644
> --- a/drivers/input/mouse/elan_i2c_core.c
> +++ b/drivers/input/mouse/elan_i2c_core.c
> @@ -4,7 +4,8 @@
>   * Copyright (c) 2013 ELAN Microelectronics Corp.
>   *
>   * Author: 林政維 (Duson Lin) 
> - * Version: 1.6.0
> + * Author: KT Liao 
> + * Version: 1.6.2
>   *
>   * Based on cyapa driver:
>   * copyright (c) 2011-2012 Cypress Semiconductor, Inc.
> @@ -40,7 +41,7 @@
>  #include "elan_i2c.h"
>  
>  #define DRIVER_NAME  "elan_i2c"
> -#define ELAN_DRIVER_VERSION  "1.6.1"
> +#define ELAN_DRIVER_VERSION  "1.6.2"
>  #define ELAN_VENDOR_ID   0x04f3
>  #define ETP_MAX_PRESSUR

Re: OT: Open letter to the Linux World

2014-08-15 Thread Vlad Glagolev
 aggressively want
> to change the core of Linux away from it's true philosophy? Let them go
> off and create their own 'competitor' to Windows and Mac. If they did,
> it would be the same opaque, backdoored, user-tracking bullshit that
> Windows and Mac have become. They DO NOT speak for me, and you should
> not passively allow them to speak for you either.
> 
> systemd is a trojan. systemd is a medusa. systemd is Substance D.
> systemd is scary - not just because it's tools suck, or because it's
> a massive fucking hairball - but because architecturally it has way
> too much concentrated power. We all need to collectively expel it from
> our midst because it will own Linux, and by extension us and our
> freedoms. systemd will *be* Linux. Sit idly by and ignore this fact at
> all of our collective peril.
> 
> OneLinux == zero-choice
> 
> 
> --
> Regards,
> Christopher Barry
> 
> Random geeky fortune:
> BOFH excuse #202:
> 
> kernel panic: write-only-memory (/dev/wom0) capacity exceeded.

--
Vlad Glagolev
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/