Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp680337ybg; Wed, 3 Jun 2020 10:42:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxjbkVLjR+9T4ztX5EA0A25YvMEYbqGcFd7IaiAhFteoET7Mj9gy2+VWQh/a6+G1xgZxBlg X-Received: by 2002:a17:906:8614:: with SMTP id o20mr409117ejx.444.1591206173850; Wed, 03 Jun 2020 10:42:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591206173; cv=none; d=google.com; s=arc-20160816; b=NrkqFMUjqR/H16Z1GMfbdnM7NE0FLgWCLfAZofM0U7MaHtTBSjOTuqpC1tEhBdmegs Hj3IDLjBx/X1sL11nnwWb0SmBrX8ZzSblLGIEQSMell9dLXVCSKeWjGLlyIWKajfIK7y 69ysggsmmOKCIRjgkK4sVUvY7DMZnm+T3xawNnHdNp8VBDt4ohTgfiMprHpL66Yb1wk/ DXVI6BypWwcYRyoM9bMnzEsmDnq0pI3cZ6mDgpyxWtbfBx/QTHQhX7IWNRQlK+7q/ian 1xm+rzUEBsJ3KKowDHXbvhqqQXrCY7QfvGw0FUvAofczNXv0CKx+hGS+vvPh/FRlBWOd g6Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:references:message-id :content-transfer-encoding:cc:date:in-reply-to:from:subject :mime-version; bh=eFxhPKmJNz0Ww7ea/1/rOkbE2PPr4wIQosxk1Ebif1Y=; b=L8EKkJm8c8TOPwjyN+qIa3XTZSbrIiBYi1zxHeikWMmO+VupAE83997gqMlJnPLSrr YVjUVSZRh/scBa2sbIccSHIZEnuqUfDXs6oGYNGrJAmo3+RhzTiOayDwKM+fW+PCA5HL rqzW5vqddBh+SO8A5kxe34voRGoImLJgphowVk+iMyYoj3TgqFoJh6MqcLar35Lrudjq oBDEu+UECBjexPOxyYMbVWeI1zHqjqf26aGIFgqzd2CAkVkJE0NhvMEuHhf4dOMt/rkl acq8tmgNIeaxdaS5XjOmoj0izvV3OO/epMI4mKHq2kAzdf3jMCxDFkIpTPYhTC0hyn6E XDGA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id o1si144983edr.267.2020.06.03.10.42.28; Wed, 03 Jun 2020 10:42:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-bluetooth-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-bluetooth-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726159AbgFCRmX convert rfc822-to-8bit (ORCPT + 99 others); Wed, 3 Jun 2020 13:42:23 -0400 Received: from coyote.holtmann.net ([212.227.132.17]:48206 "EHLO mail.holtmann.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726061AbgFCRmX (ORCPT ); Wed, 3 Jun 2020 13:42:23 -0400 Received: from marcel-macbook.fritz.box (p5b3d2638.dip0.t-ipconnect.de [91.61.38.56]) by mail.holtmann.org (Postfix) with ESMTPSA id 1E3C1CED2C; Wed, 3 Jun 2020 19:52:09 +0200 (CEST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.80.23.2.2\)) Subject: Re: [PATCH v2 1/2] Bluetooth: Add support to Intel read supported feature From: Marcel Holtmann In-Reply-To: <20200603101523.12547-1-kiran.k@intel.com> Date: Wed, 3 Jun 2020 19:42:20 +0200 Cc: Bluez mailing list , ravishankar.srivatsa@intel.com, Chethan T N , Ps@vger.kernel.org, AyappadasX Content-Transfer-Encoding: 8BIT Message-Id: References: <20200603101523.12547-1-kiran.k@intel.com> To: Kiran K X-Mailer: Apple Mail (2.3608.80.23.2.2) Sender: linux-bluetooth-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-bluetooth@vger.kernel.org Hi Kiran, > The command shall read the Intel controller supported > feature. Based on the supported features addtional debug > configuration shall be enabled. > > Signed-off-by: Chethan T N > Signed-off-by: Ps, AyappadasX > Signed-off-by: Kiran K > --- > drivers/bluetooth/btintel.c | 34 ++++++++++++++++++++++++++++++++++ > drivers/bluetooth/btintel.h | 14 ++++++++++++++ > drivers/bluetooth/btusb.c | 8 +++++++- > 3 files changed, 55 insertions(+), 1 deletion(-) > > diff --git a/drivers/bluetooth/btintel.c b/drivers/bluetooth/btintel.c > index 6a0e2c5a8beb..09e697b92426 100644 > --- a/drivers/bluetooth/btintel.c > +++ b/drivers/bluetooth/btintel.c > @@ -754,6 +754,40 @@ void btintel_reset_to_bootloader(struct hci_dev *hdev) > } > EXPORT_SYMBOL_GPL(btintel_reset_to_bootloader); > > +int btintel_read_supported_features(struct hci_dev *hdev, > + struct intel_supported_features *supported_features) > +{ > + struct sk_buff *skb; > + u8 page_no = 1; > + > + /* Intel controller supports two pages, each page is of 128-bit > + * feature bit mask. And each bit defines specific feature support > + */ > + skb = __hci_cmd_sync(hdev, 0xfca6, sizeof(page_no), &page_no, > + HCI_INIT_TIMEOUT); Please get the coding style right first. We have plenty of examples in the same file on how to do this. Regards Marcel