From owner-svn-src-all@freebsd.org Tue Feb 27 04:38:28 2018 Return-Path: Delivered-To: svn-src-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 806A2F223F9; Tue, 27 Feb 2018 04:38:28 +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.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 3377081023; Tue, 27 Feb 2018 04:38:28 +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 2E69D258AB; Tue, 27 Feb 2018 04:38:28 +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 w1R4cSxk009942; Tue, 27 Feb 2018 04:38:28 GMT (envelope-from jhibbits@FreeBSD.org) Received: (from jhibbits@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w1R4cR9a009940; Tue, 27 Feb 2018 04:38:27 GMT (envelope-from jhibbits@FreeBSD.org) Message-Id: <201802270438.w1R4cR9a009940@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jhibbits set sender to jhibbits@FreeBSD.org using -f From: Justin Hibbits Date: Tue, 27 Feb 2018 04:38:27 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r330052 - head/sys/powerpc/booke X-SVN-Group: head X-SVN-Commit-Author: jhibbits X-SVN-Commit-Paths: head/sys/powerpc/booke X-SVN-Commit-Revision: 330052 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Feb 2018 04:38:28 -0000 Author: jhibbits Date: Tue Feb 27 04:38:27 2018 New Revision: 330052 URL: https://svnweb.freebsd.org/changeset/base/330052 Log: Increase the size of a reservation granule for TLB locks A reservation granule on PowerPC is a cache line. On e500mc and derivatives a cacheline size is 64 bytes, not 32. Allocate the maximum size permitted, but only utilize the size that is needed. On e500v1 and e500v2 the reservation granule will still be 32 bytes. Modified: head/sys/powerpc/booke/booke_machdep.c head/sys/powerpc/booke/trap_subr.S Modified: head/sys/powerpc/booke/booke_machdep.c ============================================================================== --- head/sys/powerpc/booke/booke_machdep.c Tue Feb 27 04:23:03 2018 (r330051) +++ head/sys/powerpc/booke/booke_machdep.c Tue Feb 27 04:38:27 2018 (r330052) @@ -372,7 +372,7 @@ booke_init(u_long arg1, u_long arg2) return (ret); } -#define RES_GRANULE 32 +#define RES_GRANULE cacheline_size extern uintptr_t tlb0_miss_locks[]; /* Initialise a struct pcpu. */ Modified: head/sys/powerpc/booke/trap_subr.S ============================================================================== --- head/sys/powerpc/booke/trap_subr.S Tue Feb 27 04:23:03 2018 (r330051) +++ head/sys/powerpc/booke/trap_subr.S Tue Feb 27 04:38:27 2018 (r330052) @@ -82,7 +82,7 @@ /* Get the per-CPU data structure */ #define GET_CPUINFO(r) mfsprg0 r -#define RES_GRANULE 32 +#define RES_GRANULE 64 #define RES_LOCK 0 /* offset to the 'lock' word */ #ifdef __powerpc64__ #define RES_RECURSE 8 /* offset to the 'recurse' word */