Received: by 2002:ac0:8845:0:0:0:0:0 with SMTP id g63csp1345img; Thu, 28 Feb 2019 13:53:08 -0800 (PST) X-Google-Smtp-Source: APXvYqyuqzQFdE/11ApZfCo5tkrtwKciM2f6WLj9741lO2WiB/ktUI6Usp+jBsbhJaKTJlzT/7lV X-Received: by 2002:a63:9dc3:: with SMTP id i186mr1312628pgd.305.1551390788544; Thu, 28 Feb 2019 13:53:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551390788; cv=none; d=google.com; s=arc-20160816; b=LfHZE94wVlHaKEnU/b7SVsQY/UNvgYeFM1FudsjykJkTbHJISy6p56wbIU+4GuGGVv c8f7empHIUgutaHInHKXjxeatAv0EbOpO2xCGzdKvNnaQE6zVtZv0i77cD5MgFEITsbG OI3ELnyaBNUpEqUCS5UM3IY8kZxDBn39Cbjsz01ZHqtdc44RE3MX4JqBROHG/XF3cS7R Jwe4PjEuZ7TwqYpu+Sqf+vBEh1H+NFfi2XW3th+8u3ntC/OxwJJqORzV71GCLaTJONBX KyXVzdGZqtC48NXFvJHE1RMIpYeaNRLpnj9Jk/djvhcRojrX8mn+6NEVGh+gSXbx3paR Bfag== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=leNRNY5PA6g1RqFbwlrVxKbLw9rvvy5ngWIY3AMUiI8=; b=sFsUzd7S/W4Ol5mtIRSr2AShGALB9y/eBqYtgD9hKpVA9oFDLdCdVD8X5ivniv85ub Jj/MoTHyE8uePcRTUA1ZlMd+QvHjm+Mr/WLvatQ85iCS5b3s3gqNbnegwzKUT3sr9115 Wy/O8KEdcNI6+Juh0/BKtd8/rLM2rmcFiJAPhQpjJ9Lqnyy24FIC2ELw65VfwYThz+WQ I+ryXqxISemeDnV+5qdtCiHH+2EaiTF4Zc0kQO2+1WliwM81Tio+UhvLIewqfNITXc4R ftvOf29WpgqKpHGA3EWCJP63AdscaifPkebW45MDJQVxYrWU6cm09soDc8OvPgze/Xh/ n+XA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=WTpI9fRx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n16si19445346pgj.27.2019.02.28.13.52.52; Thu, 28 Feb 2019 13:53:08 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=WTpI9fRx; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387904AbfB1US1 (ORCPT + 99 others); Thu, 28 Feb 2019 15:18:27 -0500 Received: from mail-it1-f196.google.com ([209.85.166.196]:38871 "EHLO mail-it1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387858AbfB1USY (ORCPT ); Thu, 28 Feb 2019 15:18:24 -0500 Received: by mail-it1-f196.google.com with SMTP id l66so17775761itg.3; Thu, 28 Feb 2019 12:18:24 -0800 (PST) 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=leNRNY5PA6g1RqFbwlrVxKbLw9rvvy5ngWIY3AMUiI8=; b=WTpI9fRxafw4c6SnpmRogSHfP7KO1ZH2pd83VSn+1rT8xPZeAfJHk05ezwasI7kG1q J26gWARTIg3MazOsxYCU7l2pIHHg+J4HaJuEVudX/7/ekGEDjgMQBX58rzky2njmsEmi idM4jVxXcguZH+3f0kv+c7v2HqteuzkTuk+Ilid7MnfVJvj8CX61ig2KmRvzTKZfVstM Ss566pyGP6nRGlL1+2wkhNQHdzSb8SQYl145QGy8C5ZF6qU3yfP2xQ3oSQxvEUnrcl3f xtyXy7GJycxjtEtwlG+D1IAIZDCeJwa+v2esw6GTAfWiNEVvepo73+ucJYQm9RDgpoFo qtpw== 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=leNRNY5PA6g1RqFbwlrVxKbLw9rvvy5ngWIY3AMUiI8=; b=FozG7QJXsxz8yQ7Et2gNQtP2oTQ2eh5wEzQR0VWKHgOJstXVpxb4tYKdAd/kneVR88 xAU4h8whJRpLS5dQOS9i18nSNTQN/UBJ8a7I9UPgNmRoPgWpEHQGK4hZRi0bFWkULWIs U+z9/IOwdBTCS0lQ5XMOtViK5zlQr3hUbmwcV/ZDh/gHCBy/ZWITBIVkFmf6bOeuIfgK +dwyF0aeImJToAIQNBmWDiO2CoaKiq/d5t96dfo1MxIL7k+S51YJoubjq6TiesRFqz2E bGaZ4KrSMSoynsJFnUeWbqB09gRDACrIcJ3572v76y5n7XyKYUkzLlfKYehCwnD19YiD b76A== X-Gm-Message-State: AHQUAuZq83a/mCgmHbJ7ewVJvVWRO7imxj4gprtYChLz8WOO2fhwhnla MklNehh21gsO52eY8jT2Qw== X-Received: by 2002:a24:3c94:: with SMTP id m142mr1066052ita.36.1551385102476; Thu, 28 Feb 2019 12:18:22 -0800 (PST) Received: from localhost.localdomain (CPE1cabc0918a93-CM1cabc0918a90.cpe.net.cable.rogers.com. [99.229.26.117]) by smtp.gmail.com with ESMTPSA id l131sm3388808itc.17.2019.02.28.12.18.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 28 Feb 2019 12:18:21 -0800 (PST) From: Robert Yang To: Jonathan Cameron , Rob Herring , Mark Rutland Cc: linux-iio@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Robert Yang Subject: [PATCH 3/3] iio: accel: kxcjk1013: Add device tree support Date: Thu, 28 Feb 2019 15:18:11 -0500 Message-Id: <20190228201811.7582-4-decatf@gmail.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190228201811.7582-1-decatf@gmail.com> References: <20190228201811.7582-1-decatf@gmail.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add device tree support for kxcjk-1013 accelerometer sensors. Signed-off-by: Robert Yang --- drivers/iio/accel/kxcjk-1013.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/drivers/iio/accel/kxcjk-1013.c b/drivers/iio/accel/kxcjk-1013.c index 7096e577b23f..e7a00743cdcb 100644 --- a/drivers/iio/accel/kxcjk-1013.c +++ b/drivers/iio/accel/kxcjk-1013.c @@ -1510,10 +1510,21 @@ static const struct i2c_device_id kxcjk1013_id[] = { MODULE_DEVICE_TABLE(i2c, kxcjk1013_id); +static const struct of_device_id kxcjk1013_of_match[] = { + { .compatible = "kionix,kxcjk1013", }, + { .compatible = "kionix,kxcj91008", }, + { .compatible = "kionix,kxtj21009", }, + { .compatible = "kionix,kxtf9", }, + { .compatible = "kionix,SMO8500", }, + { } +}; +MODULE_DEVICE_TABLE(of, kxcjk1013_of_match); + static struct i2c_driver kxcjk1013_driver = { .driver = { .name = KXCJK1013_DRV_NAME, .acpi_match_table = ACPI_PTR(kx_acpi_match), + .of_match_table = of_match_ptr(kxcjk1013_of_match), .pm = &kxcjk1013_pm_ops, }, .probe = kxcjk1013_probe, -- 2.17.1