From owner-freebsd-hackers@freebsd.org Mon Aug 27 14:25:41 2018 Return-Path: Delivered-To: freebsd-hackers@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 665E3108BB8C; Mon, 27 Aug 2018 14:25:41 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: from mail-wm0-x236.google.com (mail-wm0-x236.google.com [IPv6:2a00:1450:400c:c09::236]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id D215572DCA; Mon, 27 Aug 2018 14:25:40 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: by mail-wm0-x236.google.com with SMTP id c14-v6so8295594wmb.4; Mon, 27 Aug 2018 07:25:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references:reply-to :mime-version:content-transfer-encoding; bh=gUAwE9OkPs4raYQQb/+DcgilMSgaOFRqz73uFgYKp+s=; b=tSE6AG7bOAt98N7Mal8yoZFna0uXsYgOuel6n3e9EKAdpszGHwP7HRlto+IgLLsaPb sUrgJeuYKvZ5sIqE1pP222LQ4ECY1zkjkoSzYD5SlYk20BkgO9JpyAp+xvVzQ1qT6oZk BGvWwNNJ2wO0RmGS9L7I5Ii8yFLTL1sKG5TEt9Ussav9kKOf+8tYA+AB10QkC61eEX7J oKTMVkbOB2XzBjd+WkRDyZrkTM1p0yj/rwWeE7WEukBU/RgcT0bY7tDB/z3mmvLKrBvu rLcFhScWf1rELt+eWDaofieq378rhBAXgwRtTiSBXN19nOIEeEvQZhy7LZlB7Ze2pYtV iHJQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:reply-to:mime-version:content-transfer-encoding; bh=gUAwE9OkPs4raYQQb/+DcgilMSgaOFRqz73uFgYKp+s=; b=OoR9D5+WY/uBltgFu/WLkY6CcbFGI3HeeA1LvcVucjoVuknmp+lGNF1omhfVJmyLSw JXtgbdcF+mWYMbDgkmWpxRG0DxObyoElXjYZ0WdxImNPkf/XxH3NDsmJD6YJ8m0US6HE Mghi8Q+GFDZ72Y0r7O2JGmKfBhGxBSXn7CFyPWu5aHpndeaJRAOwVEaRORZad8kqllbX AOrWH5Setw3lfStbhPffW9vHBDKcqxbPPG/Eg17hO793T50/RCVJpJR6Npe3fR9G3bNz BLE8L/4uS/zlluPx3feOVJ97kAyzWLXZcKgTBXjkYE2XfcCePlC83h0awOcvNaVxMPjj qe1A== X-Gm-Message-State: APzg51Di1b0zD5ZpaGOTxTTxAyAy+D6mqCtGQzn6HsxBEYrQGn0zc4si QFI/gBYJIRCwANSnFQzv8GI= X-Google-Smtp-Source: ANB0VdZBgxRFMy8Pv97mnox9UuR0cbOH8JhMK8fZZZMbHFj2T8AdKBVKK3arfkVKldlBZFity+0c6Q== X-Received: by 2002:a1c:87c9:: with SMTP id j192-v6mr5413177wmd.71.1535379939877; Mon, 27 Aug 2018 07:25:39 -0700 (PDT) Received: from ernst.home (pD9E23C49.dip0.t-ipconnect.de. [217.226.60.73]) by smtp.gmail.com with ESMTPSA id v6-v6sm10953787wro.66.2018.08.27.07.25.38 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 27 Aug 2018 07:25:39 -0700 (PDT) Date: Mon, 27 Aug 2018 16:25:37 +0200 From: Gary Jennejohn To: "karu.pruun" Cc: meowthink@gmail.com, freebsd-hackers@freebsd.org, freebsd-stable@freebsd.org Subject: Re: Help diagnose my Ryzen build problem Message-ID: <20180827162537.05f9b576@ernst.home> In-Reply-To: References: <20180827132905.191dbd8c@ernst.home> Reply-To: gljennjohn@gmail.com X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; amd64-portbld-freebsd12.0) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Aug 2018 14:25:41 -0000 On Mon, 27 Aug 2018 16:16:47 +0300 "karu.pruun" wrote: > On Mon, Aug 27, 2018 at 3:21 PM Meowthink wrote: > > That's kib, who has committed things in that script to both 12 [1] and > > stable/11 [2]. > > > > Unfortunately, that's for Ryzens family 17h model 00h-0fh, whereas my > > Ryzen 5 2400G's model is 11h. > > > > On the microcode. It shall be updated through UEFI/BIOS updates. I > > think mine is now PinnaclePI-AM4_1.0.0.4 with microcode patchlevel > > 0x810100b. > > > > Seems like ... the only thing I can do is sit down and wait? > > The revision > > https://svnweb.freebsd.org/base/head/sys/x86/x86/cpu_machdep.c?r1=336763&r2=336762&pathrev=336763 > > works around the mwait issue, i.e. it sets > > sysctl machdep.idle_mwait=0 > sysctl machdep.idle=hlt > > Now it may or may not relate to your problem, but it appears that > Ryzen 2400G also has another issue with HLT, see the DragonFly bug > report > > https://bugs.dragonflybsd.org/issues/3131 > > which AMD is aware of and is possibly working on, but it may not have > appeared in the errata yet. The bug report says that until this is > fixed, the workaround is to also disable HLT in cpu_idle. I am not > sure what is the correct value for the sysctl on FreeBSD, perhaps > > sysctl machdep.idle=0 > > or some other value? > It is in the latest errata and there are no plans to fix it. Based on the detailed description, this is a problem only in a hypervisor. AMD has a suggested workaround for it. -- Gary Jennejohn