Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp783276imm; Fri, 28 Sep 2018 06:48:31 -0700 (PDT) X-Google-Smtp-Source: ACcGV60eZhN56S4jyuC/Dq7rK8kJH1fTmOTk4uvKOKw5BTL/OgNtP9eJ1DdxZxL96r+NmyunbiEu X-Received: by 2002:a63:3285:: with SMTP id y127-v6mr15421843pgy.104.1538142511049; Fri, 28 Sep 2018 06:48:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1538142511; cv=none; d=google.com; s=arc-20160816; b=UEBhcPSo5pqvRA05Dkkw6XnHS6gIPvU2O4dQLeQDrLRifdWg5eyUe/8NIZNARNDgIL RP1gxa1hMXmBClaEDqdMH8lkIEav5WdGUhuPZwJCuBx7qruBZhkSBtFenQKs6Z6Ofu33 HLP70st5/NMC48UYFc365IXVpnNbX4EHw47RMw5yCgbuzpH+7yHKrIsLsmXd+RN6cu74 hQFIL9F/HQISfj1+yxWIkin++3aWyZtdDldxEWeHiv2Mu2Tuk+kT5aRKxcCkcQX17glK h22jzUN0gXS1lGb4txC7ITSoMBP+SpRO4a4QoCqvOjjNa+DoXvZ9OK4qpNnBltgYpfgw xNvw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Zf1p89ISqadCmrRz4cjUn0K7V7bsLw+i7m5jy8+HZuo=; b=FLO5+zVAud4adfvwyKUzo4cO9eJfcwHKc1R0QeT8RzX0K7a06fOypuwkPp5H+rhZB0 wNY8NyPBP5zskesyfMfCzKrRDdBLyPchbof8cU6gfp5GkfdSIc2rf+xUdkhoYAnT4hmI lBfqjGrP4GYdJWLCZ43eKgw1UYF1OPq6U03eqG/bP8+TfvjwZOrEeuZ0NtyLQ+0xRp3a cVxC04fsAFAtCwk7/NSajYec1rMdwyFGRk3CqTk37yObIk74arJRKyd6kxM4seVV2i8R xeFm9KpJmxBgLdcUXIcVsWsqMbvhr/Vz5JTPHeBS1Fd0x48S6qwq2FFBxwVsiplvvYsy RXDQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@zx2c4.com header.s=mail header.b=GRgsD8nk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zx2c4.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t80-v6si5087613pfk.228.2018.09.28.06.48.14; Fri, 28 Sep 2018 06:48:31 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@zx2c4.com header.s=mail header.b=GRgsD8nk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=zx2c4.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729381AbeI1ULU (ORCPT + 99 others); Fri, 28 Sep 2018 16:11:20 -0400 Received: from frisell.zx2c4.com ([192.95.5.64]:53461 "EHLO frisell.zx2c4.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726349AbeI1ULT (ORCPT ); Fri, 28 Sep 2018 16:11:19 -0400 Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTP id 5f7dd145; Fri, 28 Sep 2018 13:28:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=zx2c4.com; h=mime-version :references:in-reply-to:from:date:message-id:subject:to:cc :content-type; s=mail; bh=8zNqg5sjcogZBT5WwrzisBc2jiY=; b=GRgsD8 nkMYpLtsfkBrga8qwOHIpPi0B14Y7X+N64/3ibiyahwN2kc215DXut5bU+5Guh7j Vu7FT88ceJYCbKexqV4mGDucN1oMIN88YvfDRxIivBhGuo0O8xz6K6F2h3b+krUD bM4ZK6yVFV1WzQwI/PVDy/KA6qMJDkaIvGmOtHoJ/IrJKnGVsv7gkjQnAKf6s5Q2 T2ITvs/0gVxIpUGdrkh0S1s63gR9PqXsjuFjL8tTSCtgCloHnz1mSQ3WsHZx2FvQ G4KdnjN+f8JyZPIHtrVIf4hFsljrDxFzsTBFQWSXq/FPrEVH+084FyMSSsJbaVg0 Lr7x1FT681tZIdSw== Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTPSA id 7469f1f6 (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128:NO); Fri, 28 Sep 2018 13:28:39 +0000 (UTC) Received: by mail-ot1-f51.google.com with SMTP id j9-v6so6109677otl.2; Fri, 28 Sep 2018 06:47:26 -0700 (PDT) X-Gm-Message-State: ABuFfoia0daBd8Amk3CpXDomp6SLDjVmpBmkdMxEo+sFkJji+JbmBKK3 Etkd2IlNKIgKwvpG87B9xnwzR711PwygLqote5E= X-Received: by 2002:a9d:42c3:: with SMTP id c3-v6mr9503602otj.54.1538142445660; Fri, 28 Sep 2018 06:47:25 -0700 (PDT) MIME-Version: 1.0 References: <20180925145622.29959-1-Jason@zx2c4.com> <20180925145622.29959-2-Jason@zx2c4.com> In-Reply-To: From: "Jason A. Donenfeld" Date: Fri, 28 Sep 2018 15:47:14 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH net-next v6 01/23] asm: simd context helper API To: Ard Biesheuvel Cc: Joe Perches , LKML , Netdev , Linux Crypto Mailing List , David Miller , Greg Kroah-Hartman , Samuel Neves , Andrew Lutomirski , Thomas Gleixner , linux-arch@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Sep 28, 2018 at 10:49 AM Ard Biesheuvel wrote: > >> +typedef enum { > >> + HAVE_NO_SIMD = 1 << 0, > >> + HAVE_FULL_SIMD = 1 << 1, > >> + HAVE_SIMD_IN_USE = 1 << 31 > >> +} simd_context_t; > >> + > > Oh, and another thing (and I'm surprised checkpatch.pl didn't complain > about it): the use of typedef in new code is strongly discouraged. > This policy predates my involvement, so perhaps Joe can elaborate on > the rationale? In case it matters, the motivation for making this a typedef is I could imagine this at some point turning into a more complicated struct on certain platforms and that would make refactoring easier. I could just make it `struct simd_context` now with 1 member though...