Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp55044pxb; Tue, 17 Nov 2020 20:30:56 -0800 (PST) X-Google-Smtp-Source: ABdhPJxAhhR3DjS1qbLv3omh03unmF+oAxa75BlhAp7s+BItakERB7dyPy4a/mdzQ/3Z9xpkH85V X-Received: by 2002:a17:906:b294:: with SMTP id q20mr22332692ejz.234.1605673856658; Tue, 17 Nov 2020 20:30:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605673856; cv=none; d=google.com; s=arc-20160816; b=f1uCCgRs27qSY5BVur5CzI1bQGJm/CUkQ7eqohEBLnihbATVvJ36hep2G8cPAItqjf D+bKuL+YGQRdpcBaNJ3bdCnc8xWS0PBMNOCjl/RAL2eyzYBlPEk+Ec3+zlXU+RJNJCiW LCXG032mYHOSSLxAACHHX/mSjBnePyHONteJo2JZyGXOaWNYabB3PuU9aklqhpuYeWDr SzOaiJIIXX2T1i1sWVANAvJD8LR2d/2t7F3I297GVg9hIcbN3dMQfyu/kkChPWuWr/KJ tqugUUof4pk+Ynxc/d+C10RdFb26li5N4CoSCgUlPhMwu3d1cVY/QJUEcCa/N/Qel5Kd Scug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:references :in-reply-to:mime-version:dkim-signature; bh=SwvNaokgke4kbvNhyfkXcbbtZGBu7XJmcZ67g6MirT8=; b=0/u3WuK28U1+15DlEtadtmRavokUTNY2365jhQV7x3JqDH1pWrfuHZ7fLPULmdBdG6 txuSkcTpedYb8NIXsZ0kA+NEGbBsuF32VZU+w6xECQ1e+WBUpGw9CE2YaiM+sTYaQ2Lz NiQYTPzP/f4gkPQ5u8OsxQbmUpntfdOBXqdKzjAQblW/62MIOQesO/dsius0CqJruyhT tWBHe6vJjjlVbOs87YAKhxa87Os4gGyxBK8hVQh/wuDN3DoEL0yZTSEi4nILboZOh2GP U7GbJtNSq/n5w1KjpUMmAoWrWlqz4Gu9WiTbquI9re/tmTnyxjviK09y9AZFiwqpKawK Tl0g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=fdhAdSYt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id bz12si16904022ejc.672.2020.11.17.20.30.30; Tue, 17 Nov 2020 20:30:56 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=fdhAdSYt; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726487AbgKRE3L (ORCPT + 99 others); Tue, 17 Nov 2020 23:29:11 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59498 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725446AbgKRE3L (ORCPT ); Tue, 17 Nov 2020 23:29:11 -0500 Received: from mail-yb1-xb41.google.com (mail-yb1-xb41.google.com [IPv6:2607:f8b0:4864:20::b41]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3ABEAC0613D4; Tue, 17 Nov 2020 20:29:11 -0800 (PST) Received: by mail-yb1-xb41.google.com with SMTP id t33so454951ybd.0; Tue, 17 Nov 2020 20:29:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=SwvNaokgke4kbvNhyfkXcbbtZGBu7XJmcZ67g6MirT8=; b=fdhAdSYt+4EQsUVcK5B6NqmI6E/qCHzhtEF6JGYnDzjCIzu8ZHDWMhjJF21LmPetkQ YumukWmaV7VdD5plZFLqQJ9EjRqsR9iFIeCL2o0HdqSPSjP23oxPC5EiTZnQoklJJSMw k+gXTGhSjr2HPncinIhaKsJEfmTbLwPLHisX8ocpR+fBRLOipFID528g32jLvp8yh6pL 23Lr29nB9xmsE8oTx1WHIg56i1KF3Sako43pFQLqGHOc+afHxn+wHByXBtk7706sWZHb /W47t8xfW+W/4HMBR599MeuMtNgHNsx9AwDx69k4xKGKP6znAcn7KVCoA+pxYNA/G/Er aREA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=SwvNaokgke4kbvNhyfkXcbbtZGBu7XJmcZ67g6MirT8=; b=b8lhTjPwZMrTJmUW5+mw49OTd+5lNW2igPCaysCF17moS6+GyeP5qJRTJDTQO7hVcJ NSlAuzX3VjNo+mgwJTUofyrCyNas7a9a7X6URxHg8FJPFQwC1Knxg+EEPXSmZDTL618l QlNGzPoGW4YPFzNGwun5i2id0CdbVtKnY+MzXu7mgPy0rH6h+jKwXDpWA6f+c1/xlBnY RtZo0IXZ7u42SOg6X5PMlv3nDSRchywCEsdAXd4sL3eupKLCqjF4ubIkubLZhMBmdFvq vAUZ0jW4/jYSWtRuvhwVpbOLVgNk3y1ZZ1fFy9HMlCcv2twMwfYT7XRkZ61nsLnySNcn OJCg== X-Gm-Message-State: AOAM532hEtosV3BoFtwv7tUscLozQaQ5Tv7OgxL3ubsPOe9Cw1bxlD0h 76o3hBsd3WPSV1m5qzph02Ot0rk8hQBHucOjH9V3Lz77wos= X-Received: by 2002:a25:2f84:: with SMTP id v126mr4645382ybv.509.1605673750464; Tue, 17 Nov 2020 20:29:10 -0800 (PST) MIME-Version: 1.0 Received: by 2002:a25:9785:0:0:0:0:0 with HTTP; Tue, 17 Nov 2020 20:29:09 -0800 (PST) In-Reply-To: <20201117175758.3befce93@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net> References: <20201117053759epcms2p80e47c3e9be01d564c775c045a42678f7@epcms2p8> <20201117175758.3befce93@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net> From: Bongsu Jeon Date: Wed, 18 Nov 2020 13:29:09 +0900 Message-ID: Subject: Re: [PATCH net-next] net/nfc/nci: Support NCI 2.x initial sequence To: Jakub Kicinski Cc: Bongsu Jeon , "davem@davemloft.net" , "netdev@vger.kernel.org" , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/18/20, Jakub Kicinski wrote: > On Tue, 17 Nov 2020 14:37:59 +0900 Bongsu Jeon wrote: >> implement the NCI 2.x initial sequence to support NCI 2.x NFCC. >> Since NCI 2.0, CORE_RESET and CORE_INIT sequence have been changed. >> If NFCEE supports NCI 2.x, then NCI 2.x initial sequence will work. >> >> In NCI 1.0, Initial sequence and payloads are as below: >> (DH) (NFCC) >> | -- CORE_RESET_CMD --> | >> | <-- CORE_RESET_RSP -- | >> | -- CORE_INIT_CMD --> | >> | <-- CORE_INIT_RSP -- | >> CORE_RESET_RSP payloads are Status, NCI version, Configuration Status. >> CORE_INIT_CMD payloads are empty. >> CORE_INIT_RSP payloads are Status, NFCC Features, >> Number of Supported RF Interfaces, Supported RF Interface, >> Max Logical Connections, Max Routing table Size, >> Max Control Packet Payload Size, Max Size for Large Parameters, >> Manufacturer ID, Manufacturer Specific Information. >> >> In NCI 2.0, Initial Sequence and Parameters are as below: >> (DH) (NFCC) >> | -- CORE_RESET_CMD --> | >> | <-- CORE_RESET_RSP -- | >> | <-- CORE_RESET_NTF -- | >> | -- CORE_INIT_CMD --> | >> | <-- CORE_INIT_RSP -- | >> CORE_RESET_RSP payloads are Status. >> CORE_RESET_NTF payloads are Reset Trigger, >> Configuration Status, NCI Version, Manufacturer ID, >> Manufacturer Specific Information Length, >> Manufacturer Specific Information. >> CORE_INIT_CMD payloads are Feature1, Feature2. >> CORE_INIT_RSP payloads are Status, NFCC Features, >> Max Logical Connections, Max Routing Table Size, >> Max Control Packet Payload Size, >> Max Data Packet Payload Size of the Static HCI Connection, >> Number of Credits of the Static HCI Connection, >> Max NFC-V RF Frame Size, Number of Supported RF Interfaces, >> Supported RF Interfaces. >> >> Signed-off-by: Bongsu Jeon > > Please fix the following sparse (build with C=1) warning: > > net/nfc/nci/ntf.c:42:17: warning: cast to restricted __le32 > >> + __u8 status = 0; > > Please don't use the __u types in the normal kernel code, those are > types for user space ABI. > Thanks for reviewing my patch. I will change the code to fix it and then resend my patch with version2.