From patchwork Tue Jun 4 09:08:32 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Max Kellermann X-Patchwork-Id: 13684914 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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 29737C25B7E for ; Tue, 4 Jun 2024 09:09:15 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 253CF6B008C; Tue, 4 Jun 2024 05:09:12 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 2034B6B0092; Tue, 4 Jun 2024 05:09:12 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 004EE6B0095; Tue, 4 Jun 2024 05:09:11 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id D4FDE6B008C for ; Tue, 4 Jun 2024 05:09:11 -0400 (EDT) Received: from smtpin08.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 7A1CA80A8A for ; Tue, 4 Jun 2024 09:09:11 +0000 (UTC) X-FDA: 82192632102.08.FC3620C Received: from mail-ej1-f49.google.com (mail-ej1-f49.google.com [209.85.218.49]) by imf03.hostedemail.com (Postfix) with ESMTP id 815C920006 for ; Tue, 4 Jun 2024 09:09:09 +0000 (UTC) Authentication-Results: imf03.hostedemail.com; dkim=pass header.d=ionos.com header.s=google header.b=NVJxf3l6; spf=pass (imf03.hostedemail.com: domain of max.kellermann@ionos.com designates 209.85.218.49 as permitted sender) smtp.mailfrom=max.kellermann@ionos.com; dmarc=pass (policy=quarantine) header.from=ionos.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1717492149; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=BL1pmIo7s1MX4N9LU8kIbt0i/wU5mZK2rTJkOzRk4Zc=; b=LlXhAb6Csry4Ia7cwQzLEdiL0z2xN7vpR8bnh3cQwlPp4V2uZATsz627sJKwolFU8DBUvG jxhBHOUBevPOI/C9bl4ByA95KdrxgzuxbPcBKHNf1TB6rY5qmyuuHLg7GFrPpO42lIHKmz wlh3Oy7SSGqR/HSik4kpN/CXudXMnpo= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1717492149; a=rsa-sha256; cv=none; b=eZe4/L0gm7OkZkAbArliOluVdHlZ75hR86pN97Q5qHoom4r64GDe9viRO9UkE1lf+3oUvk EtZ+9yPC/FtqhWAvMfmLehm6XX/XN6C/D6B3a9gd9VHH++OZOROyeUCsFPnSyPkHx++5Dr Rau3ctO1d0I2zBYORWMGblQgIWqNb0I= ARC-Authentication-Results: i=1; imf03.hostedemail.com; dkim=pass header.d=ionos.com header.s=google header.b=NVJxf3l6; spf=pass (imf03.hostedemail.com: domain of max.kellermann@ionos.com designates 209.85.218.49 as permitted sender) smtp.mailfrom=max.kellermann@ionos.com; dmarc=pass (policy=quarantine) header.from=ionos.com Received: by mail-ej1-f49.google.com with SMTP id a640c23a62f3a-a69607c6ccaso53866866b.2 for ; Tue, 04 Jun 2024 02:09:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ionos.com; s=google; t=1717492148; x=1718096948; darn=kvack.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=BL1pmIo7s1MX4N9LU8kIbt0i/wU5mZK2rTJkOzRk4Zc=; b=NVJxf3l6CE/n9RMCk7tuP56B4zUekS8WCyNvA42sus1m68p1W7bUdcXjMVUFxTvLqU W9dyUBHvkWzxvp3nvVcxcObZ8cvqOso8f+8IuH+ONT7k4uQX5ZIcwXAGC1qm8KbUHIx6 UMSX5PlBjp3Mp+wUvCkxN4KraCZTmSp9rlIUFXSsYw46Ro59lo6/aGDo/i3uvvx8DuuH J/rr4u8Oscc38wOujiMXaIcyTcGkcPv3NcxnjcPiOZyjNSu+9dyTsPBhuY/LXHNv6B47 nRtm2dLcmWVAxHfO/0VjC2GmWSKPZjxnkFH9O++sZS0yUEigvWfBJVJ2XQrQgDgQXVQC tqkQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717492148; x=1718096948; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=BL1pmIo7s1MX4N9LU8kIbt0i/wU5mZK2rTJkOzRk4Zc=; b=OrU0Ggw455/vFFVzbubmsIULlfXnRUjZAssvPseXyyYHrULxg/aSTc0g/eganRYVYe 1mSXjN1seMq1uND5dFFrXOP89R/Ky6munUb2flsvetP4MC+O8jVbIjsaWuK02ccnyvX4 GPvxNlG8tClvx0+C5D3GcsQ2f8KhMgsXXWWl72wyxSuTR+7ia1hMuX3LXzfjBteYp6S8 mv6MiLQhJ+4uuK+8h9ZyDPL48oX+6TMUcf085/i43NHbZhXWvPv/aORf6E08lZA4B9qw X1hvnnHh4fN6RwsEYjM2/pXWkO7UCw2JYBRNz9yGH9GVW9z3fEjnnRjHov73JCxWKaOF PO0A== X-Forwarded-Encrypted: i=1; AJvYcCUtim93WDrhHk2BF2nepqZPyHb7RYgJp2c5cVFboTDwZjL7vOjIECsByhzkhrDPTfgO3RIt96saP4qA3GoiSpXgQ/8= X-Gm-Message-State: AOJu0Yxq8CDnqb0ze8yKoszkbHFIbg8tW8r0/o3FQx7HZao4N9uFSb1X Gw+oTsz0a/8EHVA0KVMcxYHxQ16f2SPCXXQQqlMSbN8V+eel4Ms/MUyzGmsZ71g= X-Google-Smtp-Source: AGHT+IFF9eijKFo0jcGZn+um4NEghvBvIsaStj/BEJsY3lBQq9sQLzDiRHTklTVApw9KdQGhS/rGUw== X-Received: by 2002:a17:906:3b47:b0:a68:e429:1d96 with SMTP id a640c23a62f3a-a68e4291f3dmr482446466b.75.1717492148072; Tue, 04 Jun 2024 02:09:08 -0700 (PDT) Received: from raven.blarg.de (p200300dc6f4f9200023064fffe740809.dip0.t-ipconnect.de. [2003:dc:6f4f:9200:230:64ff:fe74:809]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a68fa49e66fsm328376766b.129.2024.06.04.02.09.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 04 Jun 2024 02:09:07 -0700 (PDT) From: Max Kellermann To: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: willy@infradead.org, sfr@canb.auug.org.au, david@redhat.com, Max Kellermann Subject: [PATCH v6 02/15] include/drm/drm_gem.h: add poll_table_struct forward declaration Date: Tue, 4 Jun 2024 11:08:32 +0200 Message-Id: <20240604090845.2182265-3-max.kellermann@ionos.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240604090845.2182265-1-max.kellermann@ionos.com> References: <20240604090845.2182265-1-max.kellermann@ionos.com> MIME-Version: 1.0 X-Rspamd-Server: rspam03 X-Rspamd-Queue-Id: 815C920006 X-Rspam-User: X-Stat-Signature: pnn5pga43isdawycsg4tcx1j1ehft3qz X-HE-Tag: 1717492149-280090 X-HE-Meta: U2FsdGVkX1/mg1npwefHCA6GluBwYTOpsuJTKqPo17YERv2Tt3HedpFL+hZT9m2g3Q9tQVb1rZh3lV75/Vdj9SGIdrmJWrdiNcI7B9z93ikhW/0SIkG2JYDz4zWICW1sH2/4PiHVnKYr3Fe1y1QwYjSgSHKb7XM//LWvzC4TPV5W5qZLW1q1jHafz3Ed8tYbd91HzaX8mFYSxMptjil07wiXx0YU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VpNV5D4hCsbjRrMzz/aJm0FZq0smcIb5CES9nUfjm4Xrbw9VsN21D0DhRRXBSUJFs6HfMu6qHFF3s6zSf4TYsVYjPyTgvf6oTVDz2ic2Jhhs66Yoh14x9Qw2Oxv2hKCTsULg= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: After eliminating includes of linux/mm.h, the following build failure occurred: ./include/drm/drm_file.h:443:45: warning: ‘struct poll_table_struct’ declared inside parameter list will not be visible outside of this definition or declaration 443 | __poll_t drm_poll(struct file *filp, struct poll_table_struct *wait); | ^~~~~~~~~~~~~~~~~ In file included from drivers/gpu/drm/imagination/pvr_gem.h:12, from drivers/gpu/drm/imagination/pvr_fw.h:9: ./include/drm/drm_gem.h:447:27: error: initialization of ‘__poll_t (*)(struct file *, struct poll_table_struct *)’ {aka ‘unsigned int (*)(struct file *, struct poll_table_struct *)’} from incompatible pointer type ‘__poll_t (*)(struct file *, struct poll_table_struct *)’ {aka ‘unsigned int (*)(struct file *, struct poll_table_struct *)’} [-Werror=incompatible-pointer-types] 447 | .poll = drm_poll,\ | ^~~~~~~~ The compiler is confused, and that can be fixed easily by forward-declaring the struct expicitly. Signed-off-by: Max Kellermann --- include/drm/drm_file.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/drm/drm_file.h b/include/drm/drm_file.h index ab230d3af138..f24ade9f766f 100644 --- a/include/drm/drm_file.h +++ b/include/drm/drm_file.h @@ -44,6 +44,7 @@ struct drm_device; struct drm_printer; struct device; struct file; +struct poll_table_struct; /* * FIXME: Not sure we want to have drm_minor here in the end, but to avoid