Message ID | 20240110185611.19723-1-rdunlap@infradead.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:2411:b0:101:2151:f287 with SMTP id m17csp989740dyi; Wed, 10 Jan 2024 10:56:37 -0800 (PST) X-Google-Smtp-Source: AGHT+IHcpgtDPzJDYMrGkTleWTBCjGl4+3PqO52YiT+Fx8x4oll+oEZKByN9TqGKUe426Tk+xPkw X-Received: by 2002:a2e:b70e:0:b0:2cd:d5a:7977 with SMTP id j14-20020a2eb70e000000b002cd0d5a7977mr16142ljo.17.1704912997256; Wed, 10 Jan 2024 10:56:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704912997; cv=none; d=google.com; s=arc-20160816; b=gHjzTWrtaA7BgdhIfE6rOjZ0r//xUOPquM+hFhfxvHjlhnwG9zB8B8fcwdhtZJT+Te XyMbdfue4kn/mJeEVTZLaHMEdmgcsGpinRtT9cApJUrPi2i5+/YuABH0Xa1F16VF8v7O 09sFxg/V1GKIqWAK4h2AVE4k0jaXFz3cHHPcl48/eE3IGRW42uALkTaPhIiKqxu0aMyG HBR3exJLvNSwd06d+Aegc/92qKJdWZ81nb6pmE6ok57q/OdBj0sGjNVhB6eapP01G0Cf CttGxiXITDdVWhwtZlmvSoULE5EbWAHnjUScGqujdtBodQf36BFrC52xPOwnjp0rHDyA eD4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:message-id:date:subject:cc:to :from:dkim-signature; bh=xgxK82QtW60isQ0g06af2qfohbauXwwDUoJgkScELIw=; fh=4/nZ6xufAmv7uIq5iFI1oqqt4W/u9YZxY0moxKUnSbo=; b=y+mHBVQdGQRfxbNBapKaaT1wiIQAv9C8cK4BUlslTbrvYXGtogU5Wk6WpyKsTzxxx5 GIw5FS73BTnE3hrLmcbGpdbsGGhacidtajNbZ8N5QqXs/fxXoqb5+2QE+3+VUcfIAtnU p83H45KZ3kgvqOUeSlBXqQi9zm1gIumj2ScPNPWPMtMppPQqXJJXn9a2u6Ro0JttfpVP tkMdS/2EWNeZdsgXbMWC5f1N01vUmcygsMayZI7S9uq6IKHekEmOqCg1ZpMREo16hp6U 6qS5/IELj3bGfwEzAU4z1KxmJnPya/kpTRtE7HWNSjuxhhgSB3uETKcONQn36Kb1eQoi nZug== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@infradead.org header.s=bombadil.20210309 header.b=ILk24ohP; spf=pass (google.com: domain of linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org" Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id da8-20020a056402176800b0055650576f78si1946851edb.14.2024.01.10.10.56.37 for <ouuuleilei@gmail.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 10 Jan 2024 10:56:37 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@infradead.org header.s=bombadil.20210309 header.b=ILk24ohP; spf=pass (google.com: domain of linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-22623-ouuuleilei=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id D7E1C1F21DA4 for <ouuuleilei@gmail.com>; Wed, 10 Jan 2024 18:56:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 740B34D5B0; Wed, 10 Jan 2024 18:56:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="ILk24ohP" Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A1D454D58A; Wed, 10 Jan 2024 18:56:15 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=Content-Transfer-Encoding: MIME-Version:Message-ID:Date:Subject:Cc:To:From:Sender:Reply-To:Content-Type: Content-ID:Content-Description:In-Reply-To:References; bh=tcX1TVBcvHCR/hSiJ/UO3rgtAKlxv9gVs4p6mnL27RM=; b=ILk24ohPtoKG+gbVdT5nsE/Wo8 GhgwgtFNF1/E+jts2pKwHubQGXp3sDrffo/i72goXPuWxABbK0WKAc5ZXd+Ri/ujdNQxBm9llttBZ 2Lnae0EnNtPgl9GZUKVKmy/OY8ip8xq8kWSHETmtPtY7c/RWZZQ2FNJi49uxQFNjQbcuOs5YPvhzd J6ObgEK0SC5Rd/EQQMqH9tHLkRlcG/4iEH+JBdtjlR8hAvEG4JBKWVcFIZgv5f72GTPVtkiEOJ1DC yKoqDLPZD+nnEyYY2YrqYIomYBx5VXig0vllJzJZ7FqTFQb2k2rFqI4GStiehwklKtSKhgR6jslCr dov/vfTA==; Received: from [50.53.46.231] (helo=bombadil.infradead.org) by bombadil.infradead.org with esmtpsa (Exim 4.96 #2 (Red Hat Linux)) id 1rNdkK-00DYXn-0r; Wed, 10 Jan 2024 18:56:12 +0000 From: Randy Dunlap <rdunlap@infradead.org> To: linux-kernel@vger.kernel.org Cc: Randy Dunlap <rdunlap@infradead.org>, Andrea Merello <andrea.merello@iit.it>, Jonathan Cameron <jic23@kernel.org>, Lars-Peter Clausen <lars@metafoo.de>, linux-iio@vger.kernel.org Subject: [PATCH] iio: imu: bno055: serdev requires REGMAP Date: Wed, 10 Jan 2024 10:56:11 -0800 Message-ID: <20240110185611.19723-1-rdunlap@infradead.org> X-Mailer: git-send-email 2.43.0 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: <linux-kernel.vger.kernel.org> List-Subscribe: <mailto:linux-kernel+subscribe@vger.kernel.org> List-Unsubscribe: <mailto:linux-kernel+unsubscribe@vger.kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1787730850829936996 X-GMAIL-MSGID: 1787730850829936996 |
Series |
iio: imu: bno055: serdev requires REGMAP
|
|
Commit Message
Randy Dunlap
Jan. 10, 2024, 6:56 p.m. UTC
There are a ton of build errors when REGMAP is not set, so select
REGMAP to fix all of them.
Examples (not all of them):
./drivers/iio/imu/bno055/bno055_ser_core.c:495:15: error: variable 'bno055_ser_regmap_bus' has initializer but incomplete type
495 | static struct regmap_bus bno055_ser_regmap_bus = {
./drivers/iio/imu/bno055/bno055_ser_core.c:496:10: error: 'struct regmap_bus' has no member named 'write'
496 | .write = bno055_ser_write_reg,
./drivers/iio/imu/bno055/bno055_ser_core.c:497:10: error: 'struct regmap_bus' has no member named 'read'
497 | .read = bno055_ser_read_reg,
./drivers/iio/imu/bno055/bno055_ser_core.c: In function 'bno055_ser_probe':
./drivers/iio/imu/bno055/bno055_ser_core.c:532:18: error: implicit declaration of function 'devm_regmap_init'; did you mean 'vmem_map_init'? [-Werror=implicit-function-declaration]
532 | regmap = devm_regmap_init(&serdev->dev, &bno055_ser_regmap_bus,
./drivers/iio/imu/bno055/bno055_ser_core.c:532:16: warning: assignment to 'struct regmap *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
532 | regmap = devm_regmap_init(&serdev->dev, &bno055_ser_regmap_bus,
./drivers/iio/imu/bno055/bno055_ser_core.c: At top level:
./drivers/iio/imu/bno055/bno055_ser_core.c:495:26: error: storage size of 'bno055_ser_regmap_bus' isn't known
495 | static struct regmap_bus bno055_ser_regmap_bus = {
Fixes: 2eef5a9cc643 ("iio: imu: add BNO055 serdev driver")
Signed-off-by: Randy Dunlap <rdunlap@infradead.org>
Cc: Andrea Merello <andrea.merello@iit.it>
Cc: Jonathan Cameron <jic23@kernel.org>
Cc: Lars-Peter Clausen <lars@metafoo.de>
Cc: linux-iio@vger.kernel.org
---
drivers/iio/imu/bno055/Kconfig | 1 +
1 file changed, 1 insertion(+)
Comments
On Wed, 10 Jan 2024 10:56:11 -0800 Randy Dunlap <rdunlap@infradead.org> wrote: > There are a ton of build errors when REGMAP is not set, so select > REGMAP to fix all of them. > > Examples (not all of them): > > ../drivers/iio/imu/bno055/bno055_ser_core.c:495:15: error: variable 'bno055_ser_regmap_bus' has initializer but incomplete type > 495 | static struct regmap_bus bno055_ser_regmap_bus = { > ../drivers/iio/imu/bno055/bno055_ser_core.c:496:10: error: 'struct regmap_bus' has no member named 'write' > 496 | .write = bno055_ser_write_reg, > ../drivers/iio/imu/bno055/bno055_ser_core.c:497:10: error: 'struct regmap_bus' has no member named 'read' > 497 | .read = bno055_ser_read_reg, > ../drivers/iio/imu/bno055/bno055_ser_core.c: In function 'bno055_ser_probe': > ../drivers/iio/imu/bno055/bno055_ser_core.c:532:18: error: implicit declaration of function 'devm_regmap_init'; did you mean 'vmem_map_init'? [-Werror=implicit-function-declaration] > 532 | regmap = devm_regmap_init(&serdev->dev, &bno055_ser_regmap_bus, > ../drivers/iio/imu/bno055/bno055_ser_core.c:532:16: warning: assignment to 'struct regmap *' from 'int' makes pointer from integer without a cast [-Wint-conversion] > 532 | regmap = devm_regmap_init(&serdev->dev, &bno055_ser_regmap_bus, > ../drivers/iio/imu/bno055/bno055_ser_core.c: At top level: > ../drivers/iio/imu/bno055/bno055_ser_core.c:495:26: error: storage size of 'bno055_ser_regmap_bus' isn't known > 495 | static struct regmap_bus bno055_ser_regmap_bus = { > > Fixes: 2eef5a9cc643 ("iio: imu: add BNO055 serdev driver") > Signed-off-by: Randy Dunlap <rdunlap@infradead.org> > Cc: Andrea Merello <andrea.merello@iit.it> > Cc: Jonathan Cameron <jic23@kernel.org> > Cc: Lars-Peter Clausen <lars@metafoo.de> > Cc: linux-iio@vger.kernel.org Applied to the fixes-togreg branch of iio.git and marked for stable. Thanks, Jonathan > --- > drivers/iio/imu/bno055/Kconfig | 1 + > 1 file changed, 1 insertion(+) > > diff -- a/drivers/iio/imu/bno055/Kconfig b/drivers/iio/imu/bno055/Kconfig > --- a/drivers/iio/imu/bno055/Kconfig > +++ b/drivers/iio/imu/bno055/Kconfig > @@ -8,6 +8,7 @@ config BOSCH_BNO055 > config BOSCH_BNO055_SERIAL > tristate "Bosch BNO055 attached via UART" > depends on SERIAL_DEV_BUS > + select REGMAP > select BOSCH_BNO055 > help > Enable this to support Bosch BNO055 IMUs attached via UART.
diff -- a/drivers/iio/imu/bno055/Kconfig b/drivers/iio/imu/bno055/Kconfig --- a/drivers/iio/imu/bno055/Kconfig +++ b/drivers/iio/imu/bno055/Kconfig @@ -8,6 +8,7 @@ config BOSCH_BNO055 config BOSCH_BNO055_SERIAL tristate "Bosch BNO055 attached via UART" depends on SERIAL_DEV_BUS + select REGMAP select BOSCH_BNO055 help Enable this to support Bosch BNO055 IMUs attached via UART.