Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932267AbdDPWpy (ORCPT ); Sun, 16 Apr 2017 18:45:54 -0400 Received: from mga01.intel.com ([192.55.52.88]:12646 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932091AbdDPWpx (ORCPT ); Sun, 16 Apr 2017 18:45:53 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.37,210,1488873600"; d="scan'208";a="957619263" Date: Mon, 17 Apr 2017 00:45:49 +0200 From: Samuel Ortiz To: Al Viro Cc: linux-kernel@vger.kernel.org, linux-wireless@vger.kernel.org Subject: Re: [PATCH] nfc: fix get_unaligned_...() misuses Message-ID: <20170416224537.GB694@zurbaran.ger.intel.com> References: <20170406164847.GU29622@ZenIV.linux.org.uk> <20170406165859.GV29622@ZenIV.linux.org.uk> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170406165859.GV29622@ZenIV.linux.org.uk> User-Agent: Mutt/1.8.0 (2017-02-23) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 893 Lines: 23 On Thu, Apr 06, 2017 at 05:58:59PM +0100, Al Viro wrote: > On Thu, Apr 06, 2017 at 05:48:47PM +0100, Al Viro wrote: > > * use unaligned.h, not unaligned/access_ok.h > > ... which got misspelled in that patch, sorry... Fixed variant follows: > > commit b3e79ba1708c9b74781079c9f8617448fce36b51 > Author: Al Viro > Date: Thu Apr 6 12:42:14 2017 -0400 > > nfc: fix get_unaligned_...() misuses > > * use unaligned.h, not unaligned/access_ok.h > * if a local variable of type uint16_t is unaligned, your compiler is FUBAR > * the whole point of get_unaligned_... is to avoid memcpy + ..._to_cpu(). > Using it *after* memcpy() (into aligned object, no less) is pointless. > > Signed-off-by: Al Viro Partly applied to nfc-next. The unaligned/access_ok.h replacements were already applied. Cheers, Samuel.