From patchwork Mon Mar 12 19:09:05 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 10277107 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id A324C603B5 for ; Mon, 12 Mar 2018 19:09:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 95C5A28E13 for ; Mon, 12 Mar 2018 19:09:33 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 89A4C28E2F; Mon, 12 Mar 2018 19:09:33 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 229FE28E13 for ; Mon, 12 Mar 2018 19:09:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932576AbeCLTJb (ORCPT ); Mon, 12 Mar 2018 15:09:31 -0400 Received: from mail-pl0-f68.google.com ([209.85.160.68]:32848 "EHLO mail-pl0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932522AbeCLTJ1 (ORCPT ); Mon, 12 Mar 2018 15:09:27 -0400 Received: by mail-pl0-f68.google.com with SMTP id c11-v6so9888513plo.0; Mon, 12 Mar 2018 12:09:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=HEDxia2hxJrVdQMhX/7BZm1Qn6NBVZ1e6HoCI8mBOSU=; b=sQqdysY1670aAi7eptytmT+DbOvA4yukHfHRXllacACxSs0cPYvVeph9nbQFq4s5d7 IqNogMZkvZ6spTr755C8GHwmPmP/pSxDads067TLkyPpJgGoH3xmMl28z4EvkxtvcIhP SDqYHWCMmnvalkrbep5DmLxHiXu+b5M94jzwnfKq/bdb0ZzI538EwpkFAqKVxYF0orG2 7pplcIeM9SDWzaGNMUMN02WlhBekfKh+ZTmE8tx1xrWmPWUTiVcdOeozQWHqMMbseiLM HTLhe8OP7T3L9NVSeIZKw2NrPKOloDNZHEACwgM2bkq2hyCQEWWIsbSMOj2hGhwbYeAF HoQA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=HEDxia2hxJrVdQMhX/7BZm1Qn6NBVZ1e6HoCI8mBOSU=; b=NiCdpA79rHyl5GdkObyRk2QqVWpQ2eiY6mAILkU0lVLKtn4HqvvUn7ANPDOYKQJMrv wu1idz9C362lXwK4vaJZwsaoHfZa3eW0Fi3Ok4FL+WVsICgLLidRGpKvwfMPgDoG4jwN aTu7mxc8bBIiQzc6XfH0BfVnffpo7vZuqTzGkzY1PDRclc5r0AAXYcloMpMZb/n6OdhM t+bC++1Sk4HIgpYqLrqICvihls7YjuvTeNinDW3xHpOLEs0IaulkbeB0yc4G/t8k7eXh wF/xGzpJB+z5ipqAQb+2MJQrkdwH56VGmYlzODv4bn2i8ebNtv0zfHJFwJpQRVdkMRQW E2cQ== X-Gm-Message-State: AElRT7GtGUgdzlB2xgVyCdGACpZawHmyOR0DRLmyDZiBwPaUJVNmcryu pXk1VQJVRL8RrHgvQ6lOOzunY9bY X-Google-Smtp-Source: AG47ELsVE+B1NCRndPg226sP6KXJk7Gm0Oe8YVnc3A568OC8VVKaxX1/8e6u8sYKdKn5mM9LnWXOTg== X-Received: by 2002:a17:902:900b:: with SMTP id a11-v6mr9019221plp.366.1520881765769; Mon, 12 Mar 2018 12:09:25 -0700 (PDT) Received: from dtor-ws.mtv.corp.google.com ([2620:0:1000:1511:8de6:27a8:ed13:2ef5]) by smtp.gmail.com with ESMTPSA id s67sm18038477pfg.104.2018.03.12.12.09.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Mar 2018 12:09:25 -0700 (PDT) From: Dmitry Torokhov To: linux-input@vger.kernel.org, Benson Leung Cc: Nick Dyer , Olof Johansson , linux-kernel@vger.kernel.org Subject: [PATCH 12/14] platform/chrome: chromeos_laptop - use device properties for Pixel Date: Mon, 12 Mar 2018 12:09:05 -0700 Message-Id: <20180312190907.174301-13-dmitry.torokhov@gmail.com> X-Mailer: git-send-email 2.16.2.660.g709887971b-goog In-Reply-To: <20180312190907.174301-1-dmitry.torokhov@gmail.com> References: <20180312190907.174301-1-dmitry.torokhov@gmail.com> Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now that Atmel driver uses generic device properties we can use them instead of platform data when setting up touchpad on the original Google Pixel. Signed-off-by: Dmitry Torokhov --- drivers/platform/chrome/chromeos_laptop.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/platform/chrome/chromeos_laptop.c b/drivers/platform/chrome/chromeos_laptop.c index 1191c1a3a0cd1..fe83a2a4900e4 100644 --- a/drivers/platform/chrome/chromeos_laptop.c +++ b/drivers/platform/chrome/chromeos_laptop.c @@ -8,13 +8,13 @@ #include #include -#include #include #include #include #include #include #include +#include #define ATMEL_TP_I2C_ADDR 0x4b #define ATMEL_TP_I2C_BL_ADDR 0x25 @@ -229,9 +229,9 @@ static int chromebook_pixel_tp_keys[] = { BTN_LEFT }; -static struct mxt_platform_data chromebook_pixel_tp_platform_data = { - .t19_num_keys = ARRAY_SIZE(chromebook_pixel_tp_keys), - .t19_keymap = chromebook_pixel_tp_keys, +static const struct property_entry chromebook_pixel_trackpad_props[] = { + PROPERTY_ENTRY_U32_ARRAY("linux,gpio-keymap", chromebook_pixel_tp_keys), + { } }; static struct chromeos_laptop chromebook_pixel = { @@ -253,8 +253,8 @@ static struct chromeos_laptop chromebook_pixel = { .board_info = { I2C_BOARD_INFO("atmel_mxt_tp", ATMEL_TP_I2C_ADDR), - .platform_data = - &chromebook_pixel_tp_platform_data, + .properties = + chromebook_pixel_trackpad_props, .flags = I2C_CLIENT_WAKE, }, .dmi_name = "trackpad",