Received: by 2002:a25:683:0:0:0:0:0 with SMTP id 125csp158681ybg; Tue, 9 Jun 2020 19:34:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxVow9Ntg5Wv02/ULczRpiRwiMpALDP3OnOBG57S12Gwh2KnrEx5B2HKywZmgKCKNmCMIA8 X-Received: by 2002:a17:907:7294:: with SMTP id dt20mr1225439ejc.355.1591756490149; Tue, 09 Jun 2020 19:34:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1591756490; cv=none; d=google.com; s=arc-20160816; b=Joz/8f7351XrHqPePlzYai9As9l3V/2pChc22zhlXAWDj2Yt16knpnV4MBDYAm0X30 BhJQfz+kkfZ01ROu5RD+c11TLRFGrciktVFSjB2RZW3YiYG3oIen+unRzhu2OlbJIKWk 04fTQoPE4GqbP2qwuhHI65UIdMnZxkeLpjbB2osRc7YlNDn5dh8jUF4GtxEHbXxvDDqs zv8s0YXjwc9E4ksZ2Bz8fM7CTUPnlkZu+1/035kY2bSWae3tlgPYu/m58LXZNZYdrc+Y MvoHdXly6kYB21N+lnihQeeZv7OVggfB+1duyYRnRI+L4112zU/ZTPhIgAKeYk/GPi9W QDKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=ikAUH+oSTe3mRlWNNzglrPUeUjqFowmt3yvhPLlzaLI=; b=0Bxx6Z+qxc3LVxo3dJ3rRtj2tm7c/M81pqRq68m4WoUsxhNUqBQqnI1ViryTxLk7Q7 3uzywfHUu9OzmQncVCKDEPWV++B4ggfTgYt1QUJFZo0Z50YhdpGDcacsz92T4yMf/bAQ TVedo0wpNZ3KY+qgXEVUKEgWohNVFA22cBGpZBP33SZHKshuCX26YCDCorXC7/bAkaiP lG4Jv4IsezESvSXVoTTRpEQ9RCuudAYBTiKSVRZ6Fc51Z2KG+OIvW2g1B98bQBrod0E1 Oxj2jjH/RC7coXaVAHke25Ex7FWcZyj+NrQ3O0S5h79dKnOOc4sahPAIUUtH7bQxdnsa kAsA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mediatek.com header.s=dk header.b=PeOj0aIo; 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=NONE dis=NONE) header.from=mediatek.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id oj22si11590409ejb.115.2020.06.09.19.34.26; Tue, 09 Jun 2020 19:34:50 -0700 (PDT) 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=@mediatek.com header.s=dk header.b=PeOj0aIo; 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=NONE dis=NONE) header.from=mediatek.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726040AbgFJCcj (ORCPT + 99 others); Tue, 9 Jun 2020 22:32:39 -0400 Received: from mailgw01.mediatek.com ([210.61.82.183]:56639 "EHLO mailgw01.mediatek.com" rhost-flags-OK-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1725944AbgFJCcj (ORCPT ); Tue, 9 Jun 2020 22:32:39 -0400 X-UUID: d5a16b9c53bb47efa0f5066bc3f6e49e-20200610 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=mediatek.com; s=dk; h=Content-Transfer-Encoding:Content-Type:MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:CC:To:From; bh=ikAUH+oSTe3mRlWNNzglrPUeUjqFowmt3yvhPLlzaLI=; b=PeOj0aIoCG2au5Qxq6ZrDWPs0n6odYH4nRjAp/IFkItVyQr3thMdUmMfZvlTYPWf4rdvD+z4v5aPQ3zqpVu/jG72XTh3jXz41ktimJUCp6hUbvKqAePFpl/kH9CWkHJ1oi81iqWvKl5P8ITVTMCYJ39agmFsw0PHaM0S0BgLXKQ=; X-UUID: d5a16b9c53bb47efa0f5066bc3f6e49e-20200610 Received: from mtkcas10.mediatek.inc [(172.21.101.39)] by mailgw01.mediatek.com (envelope-from ) (Cellopoint E-mail Firewall v4.1.10 Build 0809 with TLS) with ESMTP id 455591256; Wed, 10 Jun 2020 10:32:32 +0800 Received: from MTKCAS06.mediatek.inc (172.21.101.30) by mtkmbs01n1.mediatek.inc (172.21.101.68) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 10 Jun 2020 10:32:31 +0800 Received: from mtkswgap22.mediatek.inc (172.21.77.33) by MTKCAS06.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Wed, 10 Jun 2020 10:32:30 +0800 From: Macpaul Lin To: Felipe Balbi , Greg Kroah-Hartman , Matthias Brugger , Alan Stern , Bart Van Assche CC: Mediatek WSD Upstream , Macpaul Lin , Macpaul Lin , , , , , Justin Hsieh , Hakieyin Hsieh Subject: [PATCH] usb/gadget/function: introduce Built-in CDROM support Date: Wed, 10 Jun 2020 10:32:29 +0800 Message-ID: <1591756349-17865-1-git-send-email-macpaul.lin@mediatek.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: , Mauro Carvalho Chehab , Benjamin Herrenschmidt , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org> References: , Mauro Carvalho Chehab , Benjamin Herrenschmidt , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org> MIME-Version: 1.0 Content-Type: text/plain X-MTK: N Content-Transfer-Encoding: base64 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-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