From patchwork Sun May 31 11:10:55 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Rob Gill X-Patchwork-Id: 11580657 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 0FDCE159A for ; Sun, 31 May 2020 11:11:05 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id EB6F620776 for ; Sun, 31 May 2020 11:11:04 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=protonmail.com header.i=@protonmail.com header.b="azau5MTT" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727963AbgEaLLD (ORCPT ); Sun, 31 May 2020 07:11:03 -0400 Received: from mail-40132.protonmail.ch ([185.70.40.132]:13152 "EHLO mail-40132.protonmail.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725898AbgEaLLD (ORCPT ); Sun, 31 May 2020 07:11:03 -0400 Date: Sun, 31 May 2020 11:10:55 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1590923461; bh=qQTpPLZikg3RFH7S3ZE75+/6h6CzFsSEPHP98Tu4A8I=; h=Date:To:From:Reply-To:Subject:From; b=azau5MTTHowQlr6An61k7D95iVkLQQkCkT6t/qOSwwR8dyjidAuiwHgqzC3syr8Tl nimTDkoygYHrFTqRN1y5+6JmfSF72rbQjCW+8rs4wXAhUUtZDOBMPKz/g0GBiTrQng W1imlH0eNiC1Kavk6k4+ldYmNXSXC+L9iRl7chds= To: "linux-usb@vger.kernel.org" From: Rob Gill Reply-To: Rob Gill Subject: [PATCH] usb : Report additional USB classes Message-ID: MIME-Version: 1.0 X-Spam-Status: No, score=-1.2 required=7.0 tests=ALL_TRUSTED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM shortcircuit=no autolearn=disabled version=3.4.4 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on mail.protonmail.ch Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org From 77198692578122b24cf620209cd0fc289287fc8a Mon Sep 17 00:00:00 2001 From: Rob Gill Date: Sun, 31 May 2020 20:49:57 +1000 [PATCH] usb : Report additional USB classes 10h (USB Type-C combined audio/video devices), 11h (USB billboard), 12h (USB Type-C bridge). [https://www.usb.org/defined-class-codes] Signed-off-by: Rob Gill --- drivers/usb/core/devices.c | 4 ++++ include/uapi/linux/usb/ch9.h | 4 ++++ 2 files changed, 8 insertions(+) -- 2.17.1 diff --git a/drivers/usb/core/devices.c b/drivers/usb/core/devices.c index 44f28a114..dda791e5b 100644 --- a/drivers/usb/core/devices.c +++ b/drivers/usb/core/devices.c @@ -133,6 +133,10 @@ static const struct class_info clas_info[] = { {USB_CLASS_CSCID, "scard"}, {USB_CLASS_CONTENT_SEC, "c-sec"}, {USB_CLASS_VIDEO, "video"}, + {USB_CLASS_PERSONAL_HEALTHCARE, "phlth"}, + {USB_CLASS_AUDIO_VIDEO, "av"}, + {USB_CLASS_BILLBOARD, "blbrd"}, + {USB_CLASS_USB_TYPE_C_BRIDGE, "bridg"}, {USB_CLASS_WIRELESS_CONTROLLER, "wlcon"}, {USB_CLASS_MISC, "misc"}, {USB_CLASS_APP_SPEC, "app."}, diff --git a/include/uapi/linux/usb/ch9.h b/include/uapi/linux/usb/ch9.h index 2b623f36a..90f63f55b 100644 --- a/include/uapi/linux/usb/ch9.h +++ b/include/uapi/linux/usb/ch9.h @@ -325,6 +325,10 @@ struct usb_device_descriptor { #define USB_CLASS_CSCID 0x0b /* chip+ smart card */ #define USB_CLASS_CONTENT_SEC 0x0d /* content security */ #define USB_CLASS_VIDEO 0x0e +#define USB_CLASS_PERSONAL_HEALTHCARE 0x0f +#define USB_CLASS_AUDIO_VIDEO 0x10 +#define USB_CLASS_BILLBOARD 0x11 +#define USB_CLASS_USB_TYPE_C_BRIDGE 0x12 #define USB_CLASS_WIRELESS_CONTROLLER 0xe0 #define USB_CLASS_MISC 0xef #define USB_CLASS_APP_SPEC 0xfe