Mon Feb 20 13:30:23 2023 UTC ()
sparc64: Add missing LoadStore ordering for mutex_enter stub.

XXX pullup-8
XXX pullup-9
XXX pullup-10


(riastradh)
diff -r1.11 -r1.12 src/sys/arch/sparc64/sparc64/lock_stubs.s

cvs diff -r1.11 -r1.12 src/sys/arch/sparc64/sparc64/lock_stubs.s (expand / switch to unified diff)

--- src/sys/arch/sparc64/sparc64/lock_stubs.s 2022/04/06 22:47:57 1.11
+++ src/sys/arch/sparc64/sparc64/lock_stubs.s 2023/02/20 13:30:22 1.12
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: lock_stubs.s,v 1.11 2022/04/06 22:47:57 riastradh Exp $ */ 1/* $NetBSD: lock_stubs.s,v 1.12 2023/02/20 13:30:22 riastradh Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 2002, 2006 The NetBSD Foundation, Inc. 4 * Copyright (c) 2002, 2006 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Jason R. Thorpe and Andrew Doran. 8 * by Jason R. Thorpe and Andrew Doran.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -31,27 +31,27 @@ @@ -31,27 +31,27 @@
31 31
32#include "opt_multiprocessor.h" 32#include "opt_multiprocessor.h"
33#include "opt_lockdebug.h" 33#include "opt_lockdebug.h"
34 34
35#include <machine/param.h> 35#include <machine/param.h>
36#include <machine/asm.h> 36#include <machine/asm.h>
37 37
38#include "assym.h" 38#include "assym.h"
39 39
40#undef CURLWP 40#undef CURLWP
41#define CURLWP (CPUINFO_VA+CI_CURLWP) 41#define CURLWP (CPUINFO_VA+CI_CURLWP)
42 42
43#if defined(MULTIPROCESSOR) 43#if defined(MULTIPROCESSOR)
44#define MB_READ membar #LoadLoad 44#define MB_READ membar #LoadLoad | #LoadStore
45#define MB_MEM membar #LoadStore | #StoreStore 45#define MB_MEM membar #LoadStore | #StoreStore
46#else 46#else
47#define MB_READ /* nothing */ 47#define MB_READ /* nothing */
48#define MB_MEM /* nothing */ 48#define MB_MEM /* nothing */
49#endif 49#endif
50 50
51#if !defined(LOCKDEBUG) 51#if !defined(LOCKDEBUG)
52 52
53/* 53/*
54 * void mutex_enter(kmutex_t *); 54 * void mutex_enter(kmutex_t *);
55 */ 55 */
56.align 32 56.align 32
57ENTRY(mutex_enter) 57ENTRY(mutex_enter)