From dd4a7cf20feec1bbb99d219305e9757bff444c81 Mon Sep 17 00:00:00 2001 From: martin Date: Wed, 5 Jul 2023 16:15:37 +0000 Subject: [PATCH] Pull up following revision(s) (requested by riastradh in ticket #1849): lib/libc/dlfcn/dlfcn_elf.c: revision 1.17 libc: Fix missing membar_consumer in dl_iterate_phdr. Pairs with the existing membar_producer. --- lib/libc/dlfcn/dlfcn_elf.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/libc/dlfcn/dlfcn_elf.c b/lib/libc/dlfcn/dlfcn_elf.c index 9951157c58d7..5a1f360e6cf0 100644 --- a/lib/libc/dlfcn/dlfcn_elf.c +++ b/lib/libc/dlfcn/dlfcn_elf.c @@ -1,4 +1,4 @@ -/* $NetBSD: dlfcn_elf.c,v 1.13.24.1 2017/08/29 09:43:18 bouyer Exp $ */ +/* $NetBSD: dlfcn_elf.c,v 1.13.24.2 2023/07/05 16:15:37 martin Exp $ */ /* * Copyright (c) 2000 Takuya SHIOZAKI @@ -27,7 +27,7 @@ #include #if defined(LIBC_SCCS) && !defined(lint) -__RCSID("$NetBSD: dlfcn_elf.c,v 1.13.24.1 2017/08/29 09:43:18 bouyer Exp $"); +__RCSID("$NetBSD: dlfcn_elf.c,v 1.13.24.2 2023/07/05 16:15:37 martin Exp $"); #endif /* LIBC_SCCS and not lint */ #include "namespace.h" @@ -195,6 +195,7 @@ dl_iterate_phdr(int (*callback)(struct dl_phdr_info *, size_t, void *), membar_producer(); setup_done = true; } + membar_consumer(); memset(&phdr_info, 0, sizeof(phdr_info)); phdr_info.dlpi_addr = dlpi_addr;