From nobody Mon Feb 9 07:19:17 2026 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 253B3C001DF for ; Tue, 1 Aug 2023 11:05:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232869AbjHALFZ (ORCPT ); Tue, 1 Aug 2023 07:05:25 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44300 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230086AbjHALEy (ORCPT ); Tue, 1 Aug 2023 07:04:54 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DE391526E for ; Tue, 1 Aug 2023 03:58:55 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 729016150F for ; Tue, 1 Aug 2023 10:58:55 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 48116C433C8; Tue, 1 Aug 2023 10:58:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1690887534; bh=5JszLrVl14NYpDg2t9eZAPFv3d27caE8ile05br6iwY=; h=From:To:Cc:Subject:Date:From; b=BsLJsuBkZ7IsGXvQVTLM0rvXkIdYf1Us6CNONmRdUlJjziGHzVaKyaNjcmw6UrTGw NvVBbySJItFMnTZtVTjTbG7WKmEz1o7RJOtjZJ2E2KsnsYXG9T4wgtNrqMi4s7M3il 5THtfTQy6xZo0vvD5XU7kP3l/F7TpPqL6CN2uxkPbnYTRNha0UqHkusRWVTbAILmmj 5R/OEz8vVDSD7qkJjYDZp6nra2WnSxiLGomD5CHZhtu8mFDeWg3u/46sV+laiw+/zm 3ZI5sGQts4BitwYQdEIGX//WGQhwy81EoShB481+Sys17qA42K8wEZZ5yM9GhoEbYD 3liyT1RnICCnQ== From: Arnd Bergmann To: Andi Shyti Cc: Arnd Bergmann , "Michael S. Tsirkin" , Jason Wang , Xuan Zhuo , Stefano Garzarella , Christophe JAILLET , Feng Liu , Viresh Kumar , Paul Cercueil , Jonathan Cameron , virtualization@lists.linux-foundation.org, linux-kernel@vger.kernel.org Subject: [PATCH] virtio: Remove PM #ifdef guards to fix i2c driver Date: Tue, 1 Aug 2023 12:58:15 +0200 Message-Id: <20230801105846.3708252-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" From: Arnd Bergmann A cleanup in the virtio i2c caused a build failure: drivers/i2c/busses/i2c-virtio.c:270:10: error: 'struct virtio_driver' has n= o member named 'freeze' drivers/i2c/busses/i2c-virtio.c:271:10: error: 'struct virtio_driver' has n= o member named 'restore' Change the structure definition to allow this cleanup to be applied everywhere. Fixes: 73d546c76235b ("i2c: virtio: Remove #ifdef guards for PM related fun= ctions") Signed-off-by: Arnd Bergmann Reviewed-by: Andi Shyti =20 Reviewed-by: Paul Cercueil --- include/linux/virtio.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/linux/virtio.h b/include/linux/virtio.h index 0f3b9017dff40..9b94e2c9bbb81 100644 --- a/include/linux/virtio.h +++ b/include/linux/virtio.h @@ -218,10 +218,8 @@ struct virtio_driver { void (*scan)(struct virtio_device *dev); void (*remove)(struct virtio_device *dev); void (*config_changed)(struct virtio_device *dev); -#ifdef CONFIG_PM int (*freeze)(struct virtio_device *dev); int (*restore)(struct virtio_device *dev); -#endif }; =20 static inline struct virtio_driver *drv_to_virtio(struct device_driver *dr= v) --=20 2.39.2