From owner-svn-src-head@freebsd.org Sat Jun 6 18:56:41 2020 Return-Path: Delivered-To: svn-src-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 179F233BA98; Sat, 6 Jun 2020 18:56:41 +0000 (UTC) (envelope-from jhibbits@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49fTJS6sb8z4c0s; Sat, 6 Jun 2020 18:56:40 +0000 (UTC) (envelope-from jhibbits@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id E106626A4E; Sat, 6 Jun 2020 18:56:40 +0000 (UTC) (envelope-from jhibbits@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 056Iuel0005592; Sat, 6 Jun 2020 18:56:40 GMT (envelope-from jhibbits@FreeBSD.org) Received: (from jhibbits@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 056IueKG005591; Sat, 6 Jun 2020 18:56:40 GMT (envelope-from jhibbits@FreeBSD.org) Message-Id: <202006061856.056IueKG005591@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhibbits set sender to jhibbits@FreeBSD.org using -f From: Justin Hibbits Date: Sat, 6 Jun 2020 18:56:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r361874 - head/sys/powerpc/powerpc X-SVN-Group: head X-SVN-Commit-Author: jhibbits X-SVN-Commit-Paths: head/sys/powerpc/powerpc X-SVN-Commit-Revision: 361874 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 Jun 2020 18:56:41 -0000 Author: jhibbits Date: Sat Jun 6 18:56:40 2020 New Revision: 361874 URL: https://svnweb.freebsd.org/changeset/base/361874 Log: powerpc: Fix nits in copyinout comments from r361861 Also, remove useless nested #ifdefs in the IFUNC block. Reported by: bdragon@ Modified: head/sys/powerpc/powerpc/copyinout.c Modified: head/sys/powerpc/powerpc/copyinout.c ============================================================================== --- head/sys/powerpc/powerpc/copyinout.c Sat Jun 6 18:43:08 2020 (r361873) +++ head/sys/powerpc/powerpc/copyinout.c Sat Jun 6 18:56:40 2020 (r361874) @@ -75,7 +75,7 @@ __FBSDID("$FreeBSD$"); #include /* - * On powerpc64 (AIM only) the copy functions are IFUNcs, selecting the best + * On powerpc64 (AIM only) the copy functions are IFUNCs, selecting the best * option based on the PMAP in use. * * There are two options for copy functions on powerpc64: @@ -85,10 +85,10 @@ __FBSDID("$FreeBSD$"); * remapping user segments into kernel. This is used by the 'radix' pmap for * performance. * - * Book-E does not use the C functions, opting instead to use the 'direct' - * copies, directly, avoiding the IFUNC overhead. + * Book-E does not use the C 'remap' functions, opting instead to use the + * 'direct' copies, directly, avoiding the IFUNC overhead. * - * On 32-bit AIM these functions are direct, not IFUNCs, for performance. + * On 32-bit AIM these functions bypass the IFUNC machinery for performance. */ #ifdef __powerpc64__ int subyte_remap(volatile void *addr, int byte); @@ -125,8 +125,8 @@ int casueword_direct(volatile u_long *addr, u_long old u_long new); /* - * The IFUNC resolver determines the copy based on if the PMAP implementation - * includes a pmap_map_user_ptr function. + * The IFUNC resolver determines the copy based on whether the PMAP + * implementation includes a pmap_map_user_ptr function. */ #define DEFINE_COPY_FUNC(ret, func, args) \ DEFINE_IFUNC(, ret, func, args) \ @@ -140,15 +140,11 @@ DEFINE_COPY_FUNC(int, copyin, (const void *, void *, s DEFINE_COPY_FUNC(int, copyout, (const void *, void *, size_t)) DEFINE_COPY_FUNC(int, suword, (volatile void *, long)) DEFINE_COPY_FUNC(int, suword32, (volatile void *, int)) -#ifdef __powerpc64__ DEFINE_COPY_FUNC(int, suword64, (volatile void *, int64_t)) -#endif DEFINE_COPY_FUNC(int, fubyte, (volatile const void *)) DEFINE_COPY_FUNC(int, fuword16, (volatile const void *)) DEFINE_COPY_FUNC(int, fueword32, (volatile const void *, int32_t *)) -#ifdef __powerpc64__ DEFINE_COPY_FUNC(int, fueword64, (volatile const void *, int64_t *)) -#endif DEFINE_COPY_FUNC(int, fueword, (volatile const void *, long *)) DEFINE_COPY_FUNC(int, casueword32, (volatile uint32_t *, uint32_t, uint32_t *, uint32_t))