Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp7115263rwr; Wed, 10 May 2023 04:14:04 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4RljSgAX+xU744ljy/d84G0QgRS/C/XPaU2UiSmll6jSkQCbGURRUmf5051WNTkCVUZJW6 X-Received: by 2002:a17:902:f547:b0:1ab:bfb:4b6e with SMTP id h7-20020a170902f54700b001ab0bfb4b6emr23495558plf.31.1683717243773; Wed, 10 May 2023 04:14:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683717243; cv=none; d=google.com; s=arc-20160816; b=zHPmSjaxeXCt5H9qr7s004V2RNdw9I+O/E1AGDxOXxpaQ/O8Dq15IQonxd5ieD6ETx TRK3UbKiUo4yqYv+YoTwpL3rMMBNzJa8pmLiSiGukWZs6YTdj3SLfcg4WTtqNwmLGXZT GgPc3NXRQ8oQCeX51+4v4T0hyiAB9z4FT0ZIV42RmyUaoucxdTeA0MPU/EY8Ps+5foRm WtzVO6lP9VyqT2gSm9anV8acf4I1BnX3LX/hPbH3LxAq1ogocxRsjfc/Cw5qCrtkHUFF Jy6nfKrrC2Fd1/S+X8iDG1SjsSCl0WVweWmCC82KcNZ1gQTlEJWf805k1ihR+UEN5xuX EW6A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature:dkim-signature; bh=8W+Q+r0g3mw6ipQ9VB8oBVPwJD25yg38F3zvEI0QrWI=; b=0JEb3sZvOPj1xVpzDlnqerNwKgW6lHSmFWnY8esqUoJ5JGKhxe1QmaazAiS0YkWidl dVhtaEjWyfUgDYJeqBsJ5opCIX/vwqbUHuf1NCGGbNMKmRaBvwZdGh8JJNjeh+ln7SEO 6tMYs4MDbatCNNJPa1dATrCdCCHdT9hv4fPG9Pvtv4df0EH3A0BkKrH1fLCqa4n2it35 qIz4APDA43Zj5MZ7sWqpB9bbG/hjR+xCgrb4i+LDrtjOgLc8g1J2Tiq1ox8qS+00Du70 vAOBfxaFDD1sAPkNxV8cf/87sUXImKMu/iYaJZ+9fpmYTf1rnGUHhRnHbDAu1Crs4jGA sybQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=xsqTAyRU; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n8-20020a170903110800b001a98c0d3a9esi3753976plh.557.2023.05.10.04.13.52; Wed, 10 May 2023 04:14:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.de header.s=susede2_rsa header.b=xsqTAyRU; dkim=neutral (no key) header.i=@suse.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=suse.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236647AbjEJLGL (ORCPT + 99 others); Wed, 10 May 2023 07:06:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34850 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230205AbjEJLGJ (ORCPT ); Wed, 10 May 2023 07:06:09 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4880719B; Wed, 10 May 2023 04:06:07 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id B2BA11F388; Wed, 10 May 2023 11:06:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_rsa; t=1683716765; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=8W+Q+r0g3mw6ipQ9VB8oBVPwJD25yg38F3zvEI0QrWI=; b=xsqTAyRUUHiT1tcTopM9KBzj2+MMqQbkJhsuxa0/vyp3il1j+EufLJjTLSNhmwY736dymt beipLzXFzi2x06B170786gLMc00/aufz0q+zQ9JJ2aR9U29J6fLzaZ3ENrPtnxG+X7OjKg NqFl67xrzCTyQ/5vVpXGiOsoNWbZsL4= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.de; s=susede2_ed25519; t=1683716765; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=8W+Q+r0g3mw6ipQ9VB8oBVPwJD25yg38F3zvEI0QrWI=; b=S3VjVYLm7fDDz6TEUjM2HUYJgPdTN/ojk7o3k5n/zTMAV6d6H21pXszVtOT1O1zccafNDB +4CWx0QCUD0RTCCQ== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 42DE713519; Wed, 10 May 2023 11:06:05 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id bC02D516W2QfRAAAMHmgww (envelope-from ); Wed, 10 May 2023 11:06:05 +0000 From: Thomas Zimmermann To: deller@gmx.de, geert@linux-m68k.org, javierm@redhat.com, daniel@ffwll.ch, vgupta@kernel.org, chenhuacai@kernel.org, kernel@xen0n.name, davem@davemloft.net, James.Bottomley@HansenPartnership.com, arnd@arndb.de, sam@ravnborg.org, suijingfeng@loongson.cn Cc: linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-arch@vger.kernel.org, linux-snps-arc@lists.infradead.org, linux-kernel@vger.kernel.org, linux-ia64@vger.kernel.org, loongarch@lists.linux.dev, linux-m68k@lists.linux-m68k.org, sparclinux@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-parisc@vger.kernel.org, Thomas Zimmermann Subject: [PATCH v6 0/6] fbdev: Move framebuffer I/O helpers to Date: Wed, 10 May 2023 13:05:51 +0200 Message-Id: <20230510110557.14343-1-tzimmermann@suse.de> X-Mailer: git-send-email 2.40.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fbdev provides helpers for framebuffer I/O, such as fb_readl(), fb_writel() or fb_memcpy_to_fb(). The implementation of each helper depends on the architecture, but they are all equivalent to regular I/O functions of similar names. So use regular functions instead and move all helpers into The first patch a simple whitespace cleanup. Until now, contained an include of . As this will go away, patches 2 to 4 prepare include statements in the various drivers. Source files that use regular I/O helpers, such as readl(), now include . Source files that use framebuffer I/O helpers, such as fb_readl(), now include . Patch 5 replaces the architecture-based if-else branching in by helpers in . All helpers use Linux' existing I/O functions. Patch 6 harmonizes naming among fbdev and existing I/O functions. The patchset has been built for a variety of platforms, such as x86-64, arm, aarch64, ppc64, parisc, m64k, mips and sparc. v6: * fix build on 64-bit mips (kernel test robot) * update fb_io_fops.c v5: * fix build on s390 v4: * keep fb_mem*() as-is on ia64, loongarch, sparc64 (Arnd) * don't include (Sam) v3: * add the new helpers in * support reordering and native byte order (Geert, Arnd) v2: * use Linux I/O helpers (Sam, Arnd) Thomas Zimmermann (6): fbdev/matrox: Remove trailing whitespaces ipu-v3: Include fbdev: Include in various drivers fbdev: Include instead of fbdev: Move framebuffer I/O helpers into fbdev: Rename fb_mem*() helpers arch/ia64/include/asm/fb.h | 20 ++++ arch/loongarch/include/asm/fb.h | 21 ++++ arch/mips/include/asm/fb.h | 22 +++++ arch/parisc/video/fbdev.c | 3 +- arch/sparc/include/asm/fb.h | 20 ++++ arch/sparc/video/fbdev.c | 1 - arch/x86/video/fbdev.c | 2 - drivers/gpu/ipu-v3/ipu-prv.h | 1 + drivers/staging/sm750fb/sm750.c | 2 +- drivers/video/fbdev/arcfb.c | 1 + drivers/video/fbdev/aty/atyfb.h | 2 + drivers/video/fbdev/aty/mach64_cursor.c | 2 +- drivers/video/fbdev/chipsfb.c | 2 +- drivers/video/fbdev/core/fb_io_fops.c | 4 +- drivers/video/fbdev/core/fbcon.c | 1 - drivers/video/fbdev/core/fbmem.c | 2 - drivers/video/fbdev/kyro/fbdev.c | 2 +- drivers/video/fbdev/matrox/matroxfb_accel.c | 6 +- drivers/video/fbdev/matrox/matroxfb_base.h | 4 +- drivers/video/fbdev/pvr2fb.c | 2 +- drivers/video/fbdev/sstfb.c | 2 +- drivers/video/fbdev/stifb.c | 4 +- drivers/video/fbdev/tdfxfb.c | 2 +- drivers/video/fbdev/wmt_ge_rops.c | 2 + include/asm-generic/fb.h | 102 ++++++++++++++++++++ include/linux/fb.h | 55 +---------- 26 files changed, 210 insertions(+), 77 deletions(-) -- 2.40.1