From patchwork Wed Oct 23 14:37:00 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Charles Keepax X-Patchwork-Id: 13847173 Received: from mx0b-001ae601.pphosted.com (mx0a-001ae601.pphosted.com [67.231.149.25]) (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 763AA1C8306; Wed, 23 Oct 2024 14:37:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=67.231.149.25 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729694238; cv=none; b=AaKLZ+IDpix6ngI9/YqpqduETLcUVaFp0vVO6pprfTADxSh8Mk8tYSyfGLJhAIj2x4FGX7Y7nM4GY3ICe38ufJz3PlGUjpPMKdQ1g4IyhPEMd9nVbnlicD4MRkkA9ZbmRMohQ7QOZiNCeNWqXGORMpDOoUbVaNfN0pheriMfq+0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729694238; c=relaxed/simple; bh=Xp74AfCJ9mcYmGZEx+1354soVXppvVymKqxr3OsJX8M=; h=From:To:CC:Subject:Date:Message-ID:MIME-Version:Content-Type; b=uNnG+5eyVMldaDI0MS/VcP/ahwylXNnbPEh+drhL3nUqvEF/as9raSEwXBV7GkURx8+xlddgvw8BjRPkb+4CcohL0y3EiKfFc9QYREgTuqv/qHYBptEEYXjv5Z/3IYrZ8ogIskMxIcah8u8Nj9h/Dc6Dg4lgy958V033B8xmqF8= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=opensource.cirrus.com; spf=pass smtp.mailfrom=opensource.cirrus.com; dkim=pass (2048-bit key) header.d=cirrus.com header.i=@cirrus.com header.b=kONNABTK; arc=none smtp.client-ip=67.231.149.25 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=opensource.cirrus.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=opensource.cirrus.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=cirrus.com header.i=@cirrus.com header.b="kONNABTK" Received: from pps.filterd (m0077473.ppops.net [127.0.0.1]) by mx0a-001ae601.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 49N4ToPI026682; Wed, 23 Oct 2024 09:37:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cirrus.com; h=cc :content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to; s=PODMain02222019; bh=cPDa+ujxwy6nOSQy EihqjpjDHa0YdriBf9HgK3+XAgA=; b=kONNABTKRM7MiDCPkpheEMa66j8YfoxZ zZP6BoljtohLUc/FcVei8PQu/9r7uhjr5uSda7XWdkHe9N0kqwjEyXWSM1lZLLEI TCYIS3saKkctYL/qLbjB+i0JHCo+qwI3F66irmIUn5r6kgAiPLcUcd2kp+3BObYM yPGss+/rNfNG/WEEYwDMARkHjHxXpDqY5JCCVKBrsKLIwNOOLU/AVom0SOZJ6uux X4xQo3/tHFa9oRFt7qhDciW/dWNUWPi2NLc0pHmqyx0hgFtXjJL5X1z0ErBJKLQC kxjQmFpat7tIpJa4ykIz+mQxBLIXU3YblQLeNW5VpMaOD90ySFjNHg== Received: from ediex01.ad.cirrus.com ([84.19.233.68]) by mx0a-001ae601.pphosted.com (PPS) with ESMTPS id 42ca5x56st-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 23 Oct 2024 09:37:03 -0500 (CDT) Received: from ediex02.ad.cirrus.com (198.61.84.81) by ediex01.ad.cirrus.com (198.61.84.80) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Wed, 23 Oct 2024 15:37:01 +0100 Received: from ediswmail9.ad.cirrus.com (198.61.86.93) by anon-ediex02.ad.cirrus.com (198.61.84.81) with Microsoft SMTP Server id 15.2.1544.9 via Frontend Transport; Wed, 23 Oct 2024 15:37:01 +0100 Received: from ediswws07.ad.cirrus.com (ediswws07.ad.cirrus.com [198.90.208.14]) by ediswmail9.ad.cirrus.com (Postfix) with ESMTP id BA284822562; Wed, 23 Oct 2024 14:37:01 +0000 (UTC) From: Charles Keepax To: CC: , , , , , Subject: [PATCH 1/2] soundwire: Update the includes on the sdw.h header Date: Wed, 23 Oct 2024 15:37:00 +0100 Message-ID: <20241023143701.3700714-1-ckeepax@opensource.cirrus.com> X-Mailer: git-send-email 2.39.5 Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Proofpoint-GUID: YA8MHKYNw0Gng7YatA5Np3oTQPovqy8Z X-Proofpoint-ORIG-GUID: YA8MHKYNw0Gng7YatA5Np3oTQPovqy8Z X-Proofpoint-Spam-Reason: safe There are quite a few things used in the sdw.h header that it relies on the consumer to include. If something is used directly in the header it should be included by the header. Update the includes to cover the missing items, or add forward declarations for things that are only used as pointers. Whilst making the change also alphabetise the list of includes. Signed-off-by: Charles Keepax --- include/linux/soundwire/sdw.h | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/include/linux/soundwire/sdw.h b/include/linux/soundwire/sdw.h index 73f655334fe9..1fd4b126287f 100644 --- a/include/linux/soundwire/sdw.h +++ b/include/linux/soundwire/sdw.h @@ -4,12 +4,19 @@ #ifndef __SOUNDWIRE_H #define __SOUNDWIRE_H +#include #include -#include +#include +#include #include #include +#include #include -#include +#include +#include + +struct dentry; +struct fwnode_handle; struct sdw_bus; struct sdw_slave; From patchwork Wed Oct 23 14:37:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Charles Keepax X-Patchwork-Id: 13847174 Received: from mx0b-001ae601.pphosted.com (mx0a-001ae601.pphosted.com [67.231.149.25]) (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 764021C9DDB; Wed, 23 Oct 2024 14:37:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=67.231.149.25 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729694238; cv=none; b=hB+vXigjjYNWne60NNuy0wrakr7kTaeStaLJO2BzwTLcZo1/dwieRpTbf7B9pZgPVWcluU8mmuQOS/a35uMevY+Mo8i43cd1jNbY8E7kSFid23XI7aL7A3HJ0j4E+WAdItE7nsbL/eu+CYI0t1nFywftRsSs2+GMbA4XL56LhIQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1729694238; c=relaxed/simple; bh=GHWe9fi4EZBqjJfRmgg5CZkJb4egb0ZlU+qzkS/tRJo=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=sHY5OjLvTq2qllmF8MEwG6msaXO9jHiMhwmsH85sWCM1a3b79PoWlJEz7/1LVjooMAvxKLZ6yQOf3xSdzrdzxwvD9hskbw8N6Rpzl7kAsw2onFdXaE4aUwZzHs7bg8es4F5xG5d7oDTi0OxHYlVZ2VFydh7QCBELzhrynRknzvA= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=opensource.cirrus.com; spf=pass smtp.mailfrom=opensource.cirrus.com; dkim=pass (2048-bit key) header.d=cirrus.com header.i=@cirrus.com header.b=T267l7Al; arc=none smtp.client-ip=67.231.149.25 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=opensource.cirrus.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=opensource.cirrus.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=cirrus.com header.i=@cirrus.com header.b="T267l7Al" Received: from pps.filterd (m0077473.ppops.net [127.0.0.1]) by mx0a-001ae601.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 49N5Og5o005492; Wed, 23 Oct 2024 09:37:04 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cirrus.com; h=cc :content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to; s= PODMain02222019; bh=paQiDuQuMxmy8BxNih+2mxQ+SHMnq23tYtT9VmPMPik=; b= T267l7Alxqct+JvMRoRyHgT77dphADRDwA08XdTeHI60f+Yrd+EpiHO6ho3bwto4 MpegCDYQRkmC13y7VOwEtvKm0z3U+C4MDJoHCyDge5wTM5RCg7LH7TY/xP8ody8f LUMFwKJPXAsH16wCYbdDrKpyHt0ss42/ouYzplquQ0gzTpZt61ZTHo6KjGNDwN0A nlxZ5E2xiuiqquO2UCBgCIUaj1Hh6UG4YHKffRJsMfcIYLUG6Yk4S5nuyAuCZQz2 zqA0CCwjCuEW1er8WsPsCtGZF3aFSXB3YWhcPKeo9kxO49YCzps3v2XwxpSGlu8s Mbuxdo/F9mS9PyKoEWOX8A== Received: from ediex02.ad.cirrus.com ([84.19.233.68]) by mx0a-001ae601.pphosted.com (PPS) with ESMTPS id 42ca5x56su-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 23 Oct 2024 09:37:03 -0500 (CDT) Received: from ediex02.ad.cirrus.com (198.61.84.81) by ediex02.ad.cirrus.com (198.61.84.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.9; Wed, 23 Oct 2024 15:37:01 +0100 Received: from ediswmail9.ad.cirrus.com (198.61.86.93) by anon-ediex02.ad.cirrus.com (198.61.84.81) with Microsoft SMTP Server id 15.2.1544.9 via Frontend Transport; Wed, 23 Oct 2024 15:37:01 +0100 Received: from ediswws07.ad.cirrus.com (ediswws07.ad.cirrus.com [198.90.208.14]) by ediswmail9.ad.cirrus.com (Postfix) with ESMTP id C8FD0822563; Wed, 23 Oct 2024 14:37:01 +0000 (UTC) From: Charles Keepax To: CC: , , , , , Subject: [PATCH 2/2] soundwire: Minor formatting fixups in sdw.h header Date: Wed, 23 Oct 2024 15:37:01 +0100 Message-ID: <20241023143701.3700714-2-ckeepax@opensource.cirrus.com> X-Mailer: git-send-email 2.39.5 In-Reply-To: <20241023143701.3700714-1-ckeepax@opensource.cirrus.com> References: <20241023143701.3700714-1-ckeepax@opensource.cirrus.com> Precedence: bulk X-Mailing-List: linux-sound@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Proofpoint-GUID: mW23lCTssN128zrnKzcMqkUc2WG4ZWkL X-Proofpoint-ORIG-GUID: mW23lCTssN128zrnKzcMqkUc2WG4ZWkL X-Proofpoint-Spam-Reason: safe Fixup some minor formatting and whitespace in the sdw.h header file. Signed-off-by: Charles Keepax --- include/linux/soundwire/sdw.h | 40 +++++++++++++++-------------------- 1 file changed, 17 insertions(+), 23 deletions(-) diff --git a/include/linux/soundwire/sdw.h b/include/linux/soundwire/sdw.h index 1fd4b126287f..784656f740f6 100644 --- a/include/linux/soundwire/sdw.h +++ b/include/linux/soundwire/sdw.h @@ -616,7 +616,6 @@ struct sdw_slave_ops { int (*clk_stop)(struct sdw_slave *slave, enum sdw_clk_stop_mode mode, enum sdw_clk_stop_type type); - }; /** @@ -690,8 +689,7 @@ struct sdw_master_device { container_of(d, struct sdw_master_device, dev) struct sdw_driver { - int (*probe)(struct sdw_slave *sdw, - const struct sdw_device_id *id); + int (*probe)(struct sdw_slave *sdw, const struct sdw_device_id *id); int (*remove)(struct sdw_slave *sdw); void (*shutdown)(struct sdw_slave *sdw); @@ -710,7 +708,7 @@ struct sdw_driver { SDW_SLAVE_ENTRY_EXT((_mfg_id), (_part_id), 0, 0, (_drv_data)) int sdw_handle_slave_status(struct sdw_bus *bus, - enum sdw_slave_status status[]); + enum sdw_slave_status status[]); /* * SDW master structures and APIs @@ -792,15 +790,14 @@ struct sdw_enable_ch { */ struct sdw_master_port_ops { int (*dpn_set_port_params)(struct sdw_bus *bus, - struct sdw_port_params *port_params, - unsigned int bank); + struct sdw_port_params *port_params, + unsigned int bank); int (*dpn_set_port_transport_params)(struct sdw_bus *bus, - struct sdw_transport_params *transport_params, - enum sdw_reg_bank bank); - int (*dpn_port_prep)(struct sdw_bus *bus, - struct sdw_prepare_ch *prepare_ch); + struct sdw_transport_params *transport_params, + enum sdw_reg_bank bank); + int (*dpn_port_prep)(struct sdw_bus *bus, struct sdw_prepare_ch *prepare_ch); int (*dpn_port_enable_ch)(struct sdw_bus *bus, - struct sdw_enable_ch *enable_ch, unsigned int bank); + struct sdw_enable_ch *enable_ch, unsigned int bank); }; struct sdw_msg; @@ -835,14 +832,11 @@ struct sdw_defer { */ struct sdw_master_ops { int (*read_prop)(struct sdw_bus *bus); - u64 (*override_adr) - (struct sdw_bus *bus, u64 addr); - enum sdw_command_response (*xfer_msg) - (struct sdw_bus *bus, struct sdw_msg *msg); - enum sdw_command_response (*xfer_msg_defer) - (struct sdw_bus *bus); + u64 (*override_adr)(struct sdw_bus *bus, u64 addr); + enum sdw_command_response (*xfer_msg)(struct sdw_bus *bus, struct sdw_msg *msg); + enum sdw_command_response (*xfer_msg_defer)(struct sdw_bus *bus); int (*set_bus_conf)(struct sdw_bus *bus, - struct sdw_bus_params *params); + struct sdw_bus_params *params); int (*pre_bank_switch)(struct sdw_bus *bus); int (*post_bank_switch)(struct sdw_bus *bus); u32 (*read_ping_status)(struct sdw_bus *bus); @@ -1019,12 +1013,12 @@ void sdw_release_stream(struct sdw_stream_runtime *stream); int sdw_compute_params(struct sdw_bus *bus); int sdw_stream_add_master(struct sdw_bus *bus, - struct sdw_stream_config *stream_config, - const struct sdw_port_config *port_config, - unsigned int num_ports, - struct sdw_stream_runtime *stream); + struct sdw_stream_config *stream_config, + const struct sdw_port_config *port_config, + unsigned int num_ports, + struct sdw_stream_runtime *stream); int sdw_stream_remove_master(struct sdw_bus *bus, - struct sdw_stream_runtime *stream); + struct sdw_stream_runtime *stream); int sdw_startup_stream(void *sdw_substream); int sdw_prepare_stream(struct sdw_stream_runtime *stream); int sdw_enable_stream(struct sdw_stream_runtime *stream);