From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2997467AbdDZKSb (ORCPT ); Wed, 26 Apr 2017 06:18:31 -0400 Received: from mail.skyhub.de ([5.9.137.197]:35214 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1763850AbdDZKSW (ORCPT ); Wed, 26 Apr 2017 06:18:22 -0400 Date: Wed, 26 Apr 2017 12:18:19 +0200 From: Borislav Petkov To: Elena Reshetova Cc: linux-kernel@vger.kernel.org, dwindsor@gmail.com, ishkamiel@gmail.com, keescook@chromium.org Subject: Re: [PATCH] x86: convert threshold_bank.cpus from atomic_t to refcount_t Message-ID: <20170426101819.fswayow3ga7hnxsb@pd.tnic> References: <1492695536-5947-1-git-send-email-elena.reshetova@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <1492695536-5947-1-git-send-email-elena.reshetova@intel.com> User-Agent: NeoMutt/20170113 (1.7.2) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Apr 20, 2017 at 04:38:56PM +0300, Elena Reshetova wrote: > refcount_t type and corresponding API should be > used instead of atomic_t when the variable is used as > a reference counter. This allows to avoid accidental > refcounter overflows that might lead to use-after-free > situations. > > Suggested-by: Kees Cook > Signed-off-by: Elena Reshetova > Reviewed-by: Hans Liljestrand > Reviewed-by: David Windsor > --- > arch/x86/include/asm/amd_nb.h | 3 ++- > arch/x86/kernel/cpu/mcheck/mce_amd.c | 6 +++--- > 2 files changed, 5 insertions(+), 4 deletions(-) Applied, thanks. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.