From patchwork Mon Apr 6 10:52:04 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lorenzo Bianconi X-Patchwork-Id: 11475245 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 17A7C912 for ; Mon, 6 Apr 2020 10:52:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DD3E62075E for ; Mon, 6 Apr 2020 10:52:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1586170331; bh=3f/z30GDAjXES5vKOll/au3NwvgViFBR7vima5KZxzA=; h=From:To:Cc:Subject:Date:List-ID:From; b=mjqJoo/JnzB61gFF6PCyjtLJ9XVgV4sSowLsljXEYQaicVVtS7yxlUjjn1YscR++C fpwccvV0aZwfZlNZpy4+9Ys8wbIMfPiZYp3SisBxYkH0xkdUVB2j1MXfUuET1TEMtI EG5oTX8BSIWdrATtQP5d9qvYhmrx4yHr6o9LPpYs= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727080AbgDFKwK (ORCPT ); Mon, 6 Apr 2020 06:52:10 -0400 Received: from mail.kernel.org ([198.145.29.99]:36406 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726841AbgDFKwK (ORCPT ); Mon, 6 Apr 2020 06:52:10 -0400 Received: from lore-desk-wlan.redhat.com (unknown [151.48.151.50]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9797F20678; Mon, 6 Apr 2020 10:52:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1586170329; bh=3f/z30GDAjXES5vKOll/au3NwvgViFBR7vima5KZxzA=; h=From:To:Cc:Subject:Date:From; b=SK6sk4iltVoUBqXRKFJs2zsVtO9GLEufBQ4opG/t4XRkQNly7kYNLZkFtvcCBrlXC 2uciEEtw5ixAGqTUXWPilyhNrX9Hp8wqprzaMwIdfr9I+yrijVM/DozYexNAmBX0Lk VjoYbxv8sCQnWPLEacK2bIEO5KK2IqNJVytox2uQ= From: Lorenzo Bianconi To: jic23@kernel.org Cc: linux-iio@vger.kernel.org, lorenzo.bianconi@redhat.com, jimmyassarsson@gmail.com, andy.shevchenko@gmail.com Subject: [PATCH v2] iio: imu: st_lsm6dsx: drop huge include in sensor-hub driver Date: Mon, 6 Apr 2020 12:52:04 +0200 Message-Id: <8593125b207045797adb9406aa2d3d2f43c30153.1586170271.git.lorenzo@kernel.org> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Sender: linux-iio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-iio@vger.kernel.org st_sensors.h contains common stm sensor definitions but in st_lsm6dsx_shub driver it is used just to introduce the default wai address for LIS3MDL sensor. Drop this largely unconnected include and introduce the default wai address in st_lsm6dsx_ext_dev_settings register map Reviewed-by: Andy Shevchenko Signed-off-by: Lorenzo Bianconi --- Changes since v1: - improve commit message --- drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c index 280925dd8edb..947ca3a7dcaf 100644 --- a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c +++ b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_shub.c @@ -28,7 +28,6 @@ #include #include -#include #include "st_lsm6dsx.h" #define ST_LSM6DSX_SLV_ADDR(n, base) ((base) + (n) * 3) @@ -93,7 +92,7 @@ static const struct st_lsm6dsx_ext_dev_settings st_lsm6dsx_ext_dev_table[] = { { .i2c_addr = { 0x1e }, .wai = { - .addr = ST_SENSORS_DEFAULT_WAI_ADDRESS, + .addr = 0x0f, .val = 0x3d, }, .id = ST_LSM6DSX_ID_MAGN,