summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@localhost>2016-07-28 14:20:27 -0600
committerLinux Build Service Account <lnxbuild@localhost>2016-07-28 14:20:28 -0600
commit8794ed99ea5efc0935e432c1840828c4fb72e877 (patch)
treec9e1e2207735f40ccb8bf567d63cc37ac92902ad /include/linux
parent35e3dabda5a617debff12cbc17c0cb066928f921 (diff)
parent956d9b1ab3db6c7fef95964f7f6be8860433b74e (diff)
Promotion of kernel.lnx.4.4-160728.
CRs Change ID Subject -------------------------------------------------------------------------------------------------------------- 1044532 I510059cc8f495957bd2b5af9973b3495761edd06 msm: Camera buffer overflow fix 1035969 1041449 I3f003d5d1b8f3e9068f467723256932f29009915 Revert "misc: uidstat: avoid create_stat() race and bloc 1038054 Ief8817b4ec000c058d46aa021977b7c6003c0011 ASoC: Fix freed memory access of pcm stream kctl 1046497 Ifca675f308b59913743baf2e59dc3ed515a5b974 msm: ipa3: changes to IPA USB APIs to support SMMU 1038370 Ia3b2aa484f764fb948680357ba6a89bc57b92b24 msm: jpegdma: Remove even number check for crop left and 1007841 Iaede1269f514a314bd9717a33100f748e7753b2a usb: dwc3: Determine connection speed for HS PHY 1044351 Ifeadae2f58eb4fbf398a682beb9180c4f7419041 msm: mdss: dp: rename EDP files to DP 1044799 I2a233e85139be0612314e6fa3dfa1d1c0fa04547 usb: dwc3: Fix NULL ptr dereference in ep disable ops 1037903 I2e357fd60c03833aed48a815794729fabfcfcf93 ASoc: msm: fix out of bounds array access 1007841 I95daf3e3a833f9daeac6190daa33191f9db8cf26 usb: phy: qusb: Add support for host mode phy init seq 1022917 Ifbcb1bf8c418a4b3c787f68392aa141207dddde5 ASoC: wcd_cpe: Add support for two CPE sessions 1007841 I682eb250964f32f93d7b31dae0291aca7fa44362 usb: phy: qusb: Determine linestate for QUSB2 PHY 1046497 Ib177606acdfa9b3826c929578d1c8094242f90cd msm: ipa3: add support for SMMU to USB 1039464 I0e90de49d295563aba87af39169bd3dea1f8ade7 clk: msm: hdmi: fix value of constant for minimum VCO ra 1035969 I9c21883988e3da494c3a0a815fd3eee4c1a70a0f defconfig: um: Disable activity stats 1044351 I90d82873381cb1e9b86ed339d755365cccded537 defconfig: msmcortex: Enable DisplayPort driver 1042125 I1ee284d9a42341da85abb9bd8dbebffa1aace1a8 defconfig: arm64: enable CoreSight drivers for msmcobalt 1044351 I896ab17afce77faf3dcf64fd75b15eaec9d5a00e mdss: Update EDP driver to support DisplayPort 1045876 I94411718f6715860358b4e8eff9262c4034a5e17 ARM: dts: msm: Add the timeout property to BIMC SMMU GDS 1044256 I7a4ab0be9e70f25817edadfc2eab4f7adf4435ee clk: qcom: Porting display clocks from msm folder to qco 1038127 I851b4454e8420706ad3263d67e892720d46e5718 ASoC: msm: qdsp6v2: Add size check in audio cal ioctl 1041130 I6e1a58e901e4c042acfb0ab0a6223dec2949aefe ASoC: msm: qdsp6v2: DAP: Update check to validate data l 1044351 I4d743246dfe74a80ecce283b6056baf153e588f9 ARM: dts: msm: add pinctrl settings for DP GPIOs for msm 1039832 I83029c721f7b90c65fcc8a958c7a82e65d005ed5 coresight-etm4x: avoid reading trace-id from ETM hardwar 1041242 Ibe26e6deeca587f21f8121f6f32cf7cc0a5c3e23 usb: pd: Add vendor defined message handling 1044289 I736657ccb275ab7c343357e842ef61591314252c iommu/arm-smmu: Print device name in context fault handl 1022917 If06c3e3ac1cb5fc04367507c8d55787214cf252f ARM: msm: dts: Changes to add second CPE session for 899 987387 I723bac2f9427cddb5248101c9ac3f2b595ad0379 crypto: msm: crypto driver performance improvement 1007841 I8cfed672ff02cd61beb956116f9fcd365211cf11 ARM: dts: msm: Update QUSB2 PHY device node for host mod 1039475 I6cdf63812cc9dafbb0365c05761cfae18446d31f qcom-charger: qpnp-smb2: update battery charging status 1046478 Ia0271caef25d3fdc1295962b21e0cbdf67190498 defconfig: arm64: msm: enable CP15 barrier and SETEND si 1044419 I19d424ff0d46cc0134210424a7d431b331cbf963 usb: pd: Don't notify EXTCON_USB unless type is SDP or C 1034861 I81d1dc3ed1d588d67525b15120e7d8b947536099 qcom-charger: smb2: configure input from wipower 1031459 Ic0b58b6be29d3c797b21ef5637e4004d08cc0b5c xhci: fix 10 second timeout on removal of PCI hotpluggab 1043377 I0dc5dd822424096522d3b0b5c26da424d3c2e006 ARM: dts: msm: Add glink_pkt devices for MSMFALCON 1043366 If230af86f2fdd12fb5396f3b4736e57a123422bd iommu/iommu-debug: Make debug driver 32 bit compatible 1039033 I882780c1bcbc7713973eda5383291d891787f144 smb-lib: improve handling of usbin plugin interrupt 1042533 I6e20f4c00ec4555ecbae2adbb33287aed268639e clk: msm: clock: Allow removing clock voltage votes duri 1045849 I365a3acd2b3375f093da39e68a98a2a4d35c2287 msm: vidc: add h264 8x8 transform mode support 1046700 I01820e4e8d3d3b603f16b615ae475095c3a417dd scsi: ufs: Crash the system on unrecoverable state 1042363 Ib14c390ecfce73491777f99c5e46ec9300220844 coresight-tmc: add support to set default mem_type 1042302 I7eac4a04a19beebe8c89b5328a2cf921fa78bb69 input: it7258_ts_i2c: clean up the it7258_ts_i2c driver 1039498 Icc33e63a52b3c5ce83ef2fc56d68eae20278cac0 usb: dwc3: Make cfg_ahb_clk optional 1044223 I134790377e15d4003ecfa686a9fa7ab720e08865 icnss: Add state check before calling wlan suspend/resum 1045163 I30420fc51fe1bb153c36342e607539e5cd74de61 input: touchpanel: Add GT9xx touchpanel driver for skuf 1031459 Ic953c4ea17562357cb3845b77c0ab08b7daa1a4d usb: xhci-plat: Add XHCI_STATE_REMOVING flag on removal 1043377 I565c7c6323a129c4f29c8da5c3e8719121f1109d ARM: dts: msm: Add IPC Router devices for MSMFALCON 1035969 1041449 I48bee6e92e4210059aa6e82db4badf24c1cb1546 Revert "misc: uidstat: Remove use of obsolete create_pro 1035873 Ieb6668a1cedd53a17d2cbc13f40a8463c0280769 msm: mdss: Update LM parameters during dest scaler trans 1031648 I2e32522a42508a6bee088c95dc56a13935dd691c msm: kgsl: Map GPU QDSS STM through GPU IOMMU 1035969 1041449 Iecda872c6eae372988ff20a44164fb4a57db0f82 netfilter: xt_qtaguid: seq_printf fixes 1041206 I413cc0231a9125422efc71ed67717921af939959 smb-lib: account for Jeita while distributing FCC 1040776 I6e4222728d805d5b1d07cce4bf4648219cdaf587 msm: mdss: Update backlight filter for AD 1040724 Ifc874c9e881eb1b3ccea321679bb272cd427fabb msm: ipa: do not use delay in SSR 1039498 I92647d8ba53bb498b1048ea920a25c04441f6e10 usb: phy: Make cfg_ahb_clk optional 1045208 Ia9cbfac5dc6e1b74f47bf13dbafaacc2624ee4fd input: touchpanel: Add Mstar msg21xx touchpanel driver 1044805 Ibcd6e49c7dc7c3520527bcf9553296e846fb7458 power: qcom-charger: add driver for GEN3 fuel gauge 1044296 Ie1514b6cf78d3dd34de83608ec00c454316b75bd defconfig: Enable IOMMU debugfs in perf-defconfig 1003807 I227a74c029f10ffda9ceccc10322ad71e7fd0435 sound: usb: Enable autosuspend for usb audio device 1035969 1041449 Ib2ce5e7153756f03d48c94a5afbd32d4ae4c5c83 Revert "net: activity_stats: Stop using obsolete create_ 1039498 I05641c2d532ada36623da1e1cc687c90bc4ee906 clk: msm: clock: Remove support for the USB cfg_ahb2phy 1043733 I93ed98a17daa1c65944dd260c7004f7198741aad sound: usb: Update USB audio QMI data structure 1027456 I58440ae6cf7f02b7137312c38219efeaccf06b58 clk: msm8996: compile 8996 clock files only for ARCH_MSM 1027456 I0a4ea56d48d5133083975365228b3ea2dcc2f539 crypto: msm: enable hw crypto driver for msmfalcon 1046131 If65c952622bbaa3f71de6d02c81dbbba5ccead4e icnss: Update event workqueue flags 1046497 Ibeedeef900b069b3a113b2daabf461797f28287b usb: f_gsi: Update connection parameters for GSI channel 1043064 I388d7f809f670c6db45b933d44d15168ae84f061 qcom-charger: smb-lib: fix secure register writes 1046961 I39eb1175d473d1f2c463e1c4a0a1606307da9dc0 input: ft5x06_ts: Add driver for ft5x06 series 1044805 I7ebb6a50564abc8e607f688d59690c55c10e2dc9 ARM: dts: msm: add FG GEN3 device on pmicobalt 1045353 Ibcccf56d41779b808d1835f62969e3c9365939e8 soc: qcom: Make service locator call asynchronous 1035969 1041449 I2d9251867235a6566b4c676de0546ce046848c91 Revert "misc seq_printf fixes for 4.4" 1042363 Iaa6e6e58b9cf566dd749d81d4693c2b61be2c365 ARM: dts: msm: set default mem_type for ETR device on ms 1046834 I892bc03122b096b43fc7f6b757b1161470597ddb input: touchscreen: Add synaptics v1 driver 1039866 Ifc867e83746f51abc8d990a334d3f5642efc9c33 ARM: dts: msm: add default trace sink for MSMCOBALT 1046755 I85b8ac6dc847343d42cb2f6466137bf43fc1b7c1 msm: vidc: Fix limit for LTR mode control 984317 I53e8f860c2d50061b6c4e6ce2f944c1e2ed8dff2 slim-msm-ngd:Avoid using stale pipe handle 1047223 Ie2024498224f078de77dd006d77cdfa99bb90eee thermal: tsens: Remove registering for Critical trip zon 1040321 Iaf61632cce7ad2812da40ccabef7fe466cee6ebd defconfig: arm64: msm: Enable ESP transformation 1043377 I879f2229b4ab74d760c03f2ce12a9ba3b1c9af8d ARM: dts: msm: Add G-Link SMEM Transport entries for MSM 1038370 I81055befae23b95bd7ba7dbe32c13be642bee66d msm: camera: isp: Add isp version 1044353 Iebf23be99482e97a4a94b700067964a84830180d msm: jpegdma: set minimum acceptable dimension as 8x8 1045934 I070b537e14b505bc247f2f5e6a0e125f1d0fbb81 thermal: qpnp-adc-tm: Update reverse threshold and notif 1039009 I4e02573bc6dadf8d1a2ce50313e6d0c6e6a0e599 net: Revert upstream changes which break routing in tunn 986837 I5881c7d468507bb8402a2e9f8178b9c31e57e8a5 slim-msm: Synchronize SSR callbacks 1027456 I95aacab201d51ffb4eb8e94d2e400578cab37fc8 soc: qcom: build kryo perf events only for MSM8996 1044805 If9e7ba5632d1b5f99d91bda6276d9123c37e4dc7 power: qcom-charger: fix possible out of bounds access f 1035154 I14271b17441308f8ec6dfaea566c01887d1233f4 ASoC: open ASM session with 24 bit for 24 bit playback 1007841 I8d8ed29215f326801ba4e60794cc63e4eaeeb97e ARM: dts: msm: Update QUSB PHY device node compatible pr 1044805 I0f1408099b0736ac510987c3a17ab798d84fbdff defconfig: msmcortex: Enable FG_GEN3 driver 1044735 Ica1325f8aa65c338ea0e5b201f566607c3ddf904 msm: thermal: Update the hotplug initialization 1027456 I3433623797abbefc5f19991c215260d1df11e42a soc: qcom: build kryo-l2-accessors only for msm8996 1037988 Ide845d900259e4c40c0a57f6b5789f8169cae791 ARM: dts: msm: Revert add HDMI support for 8996 mtp 1015292 Ie54c2edc940495484f01e539cf42d5c83c4b0535 msm: mdss: Fix mixer extension offset 1043511 I830dba8f4e47e3383b09639416fc704caa94cdf2 msm: ipa3: fix packet handling for multiple buffers 1018651 I206f3fa334d96e9f57fcbd985922a436ed701ff3 msm: cpp: Query buffer from buffer manager based on inde Change-Id: Ia8193d71154a3f4b46489666de0f78f1b6109d25 CRs-Fixed: 1044532, 1027456, 1040321, 1044296, 1015292, 1044419, 1039033, 1038127, 1042302, 1039866, 1043064, 984317, 1044799, 1043511, 1039832, 1041206, 1044256, 1046961, 1044353, 1039498, 1040776, 1045208, 1043733, 1041242, 1035154, 1003807, 1035873, 1022917, 1031459, 1045876, 1044735, 1047223, 1045849, 1018651, 1039475, 1031648, 1042533, 1046497, 1044289, 1007841, 1044351, 1042125, 1041449, 1043377, 1042363, 1046700, 1037988, 1046131, 1041130, 1044223, 1044805, 1037903, 987387, 1046478, 1034861, 1045163, 1045934, 1040724, 1043366, 1039009, 1035969, 1046755, 1038054, 1038370, 1039464, 1045353, 986837, 1046834
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/input/ft5x06_ts.h31
-rw-r--r--include/linux/ipa_usb.h13
-rw-r--r--include/linux/qpnp/qpnp-adc.h3
-rw-r--r--include/linux/usb/msm_hsusb.h2
-rw-r--r--include/linux/usb/usbpd.h156
5 files changed, 203 insertions, 2 deletions
diff --git a/include/linux/input/ft5x06_ts.h b/include/linux/input/ft5x06_ts.h
new file mode 100644
index 000000000000..b2fb3c4a56ae
--- /dev/null
+++ b/include/linux/input/ft5x06_ts.h
@@ -0,0 +1,31 @@
+/*
+ *
+ * FocalTech ft5x06 TouchScreen driver header file.
+ *
+ * Copyright (c) 2010 Focal tech Ltd.
+ * Copyright (c) 2012, Code Aurora Forum. All rights reserved.
+ *
+ * This software is licensed under the terms of the GNU General Public
+ * License version 2, as published by the Free Software Foundation, and
+ * may be copied, distributed, and modified under those terms.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+#ifndef __LINUX_FT5X06_TS_H__
+#define __LINUX_FT5X06_TS_H__
+
+struct ft5x06_ts_platform_data {
+ unsigned long irqflags;
+ u32 x_max;
+ u32 y_max;
+ u32 irq_gpio;
+ u32 reset_gpio;
+ int (*power_init) (bool);
+ int (*power_on) (bool);
+};
+
+#endif
diff --git a/include/linux/ipa_usb.h b/include/linux/ipa_usb.h
index c3885c72e5ea..0fe0e36c551f 100644
--- a/include/linux/ipa_usb.h
+++ b/include/linux/ipa_usb.h
@@ -94,7 +94,7 @@ struct ipa_usb_xdci_connect_params {
* ipa_usb_xdci_chan_scratch - xDCI protocol SW config area of
* channel scratch
*
- * @last_trb_addr: Address (LSB - based on alignment restrictions) of
+ * @last_trb_addr_iova: Address (iova LSB - based on alignment restrictions) of
* last TRB in queue. Used to identify roll over case
* @const_buffer_size: TRB buffer size in KB (similar to IPA aggregation
* configuration). Must be aligned to max USB Packet Size.
@@ -103,7 +103,7 @@ struct ipa_usb_xdci_connect_params {
* @depcmd_hi_addr: Used to generate "Update Transfer" command.
*/
struct ipa_usb_xdci_chan_scratch {
- u16 last_trb_addr;
+ u16 last_trb_addr_iova;
u8 const_buffer_size;
u32 depcmd_low_addr;
u8 depcmd_hi_addr;
@@ -124,6 +124,11 @@ struct ipa_usb_xdci_chan_scratch {
* @xfer_ring_base_addr: physical base address of transfer ring. Address must be
* aligned to xfer_ring_len rounded to power of two
* @xfer_scratch: parameters for xDCI channel scratch
+ * @xfer_ring_base_addr_iova: IO virtual address mapped to xfer_ring_base_addr
+ * @data_buff_base_len: length of data buffer allocated by USB driver
+ * @data_buff_base_addr: physical base address for the data buffer (where TRBs
+ * points)
+ * @data_buff_base_addr_iova: IO virtual address mapped to data_buff_base_addr
*
*/
struct ipa_usb_xdci_chan_params {
@@ -140,6 +145,10 @@ struct ipa_usb_xdci_chan_params {
u16 xfer_ring_len;
u64 xfer_ring_base_addr;
struct ipa_usb_xdci_chan_scratch xfer_scratch;
+ u64 xfer_ring_base_addr_iova;
+ u32 data_buff_base_len;
+ u64 data_buff_base_addr;
+ u64 data_buff_base_addr_iova;
};
/**
diff --git a/include/linux/qpnp/qpnp-adc.h b/include/linux/qpnp/qpnp-adc.h
index 8d51ddcd4246..af25f0c01369 100644
--- a/include/linux/qpnp/qpnp-adc.h
+++ b/include/linux/qpnp/qpnp-adc.h
@@ -242,6 +242,7 @@ enum qpnp_iadc_channels {
#define QPNP_ADC_HWMON_NAME_LENGTH 64
#define QPNP_MAX_PROP_NAME_LEN 32
#define QPNP_THERMALNODE_NAME_LENGTH 25
+#define QPNP_ADC_1P25_UV 1250000
/* Structure device for qpnp vadc */
struct qpnp_vadc_chip;
@@ -950,6 +951,7 @@ enum qpnp_state_request {
* @low_temp: Low temperature threshold for which notification is requested.
* @high_thr_voltage: High voltage for which notification is requested.
* @low_thr_voltage: Low voltage for which notification is requested.
+ * @adc_tm_hc: Represents the refreshed BTM register design.
* @state_request: Enable/disable the corresponding high and low temperature
* thresholds.
* @timer_interval1: Select polling rate from qpnp_adc_meas_timer_1 type.
@@ -972,6 +974,7 @@ struct qpnp_adc_tm_btm_param {
int32_t low_thr;
int32_t gain_num;
int32_t gain_den;
+ bool adc_tm_hc;
enum qpnp_vadc_channels channel;
enum qpnp_state_request state_request;
enum qpnp_adc_meas_timer_1 timer_interval;
diff --git a/include/linux/usb/msm_hsusb.h b/include/linux/usb/msm_hsusb.h
index 89effb61d153..44b6222db9a3 100644
--- a/include/linux/usb/msm_hsusb.h
+++ b/include/linux/usb/msm_hsusb.h
@@ -176,6 +176,8 @@ struct msm_usb_cable {
#define DEVICE_IN_SS_MODE BIT(5)
#define PHY_LANE_A BIT(6)
#define PHY_LANE_B BIT(7)
+#define PHY_HSFS_MODE BIT(8)
+#define PHY_LS_MODE BIT(9)
#define USB_NUM_BUS_CLOCKS 3
diff --git a/include/linux/usb/usbpd.h b/include/linux/usb/usbpd.h
new file mode 100644
index 000000000000..c2c1025feb8e
--- /dev/null
+++ b/include/linux/usb/usbpd.h
@@ -0,0 +1,156 @@
+/* Copyright (c) 2016, Linux Foundation. All rights reserved.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 and
+ * only version 2 as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ */
+
+#ifndef __LINUX_USB_USBPD_H
+#define __LINUX_USB_USBPD_H
+
+#include <linux/list.h>
+
+struct usbpd;
+
+/* Standard IDs */
+#define USBPD_SID 0xff00
+
+/* Structured VDM Command Type */
+enum usbpd_svdm_cmd_type {
+ SVDM_CMD_TYPE_INITIATOR,
+ SVDM_CMD_TYPE_RESP_ACK,
+ SVDM_CMD_TYPE_RESP_NAK,
+ SVDM_CMD_TYPE_RESP_BUSY,
+};
+
+/* Structured VDM Commands */
+#define USBPD_SVDM_DISCOVER_IDENTITY 0x1
+#define USBPD_SVDM_DISCOVER_SVIDS 0x2
+#define USBPD_SVDM_DISCOVER_MODES 0x3
+#define USBPD_SVDM_ENTER_MODE 0x4
+#define USBPD_SVDM_EXIT_MODE 0x5
+#define USBPD_SVDM_ATTENTION 0x6
+
+/*
+ * Implemented by client
+ */
+struct usbpd_svid_handler {
+ u16 svid;
+
+ void (*connect)(struct usbpd_svid_handler *hdlr);
+ void (*disconnect)(struct usbpd_svid_handler *hdlr);
+
+ /* Unstructured VDM */
+ void (*vdm_received)(struct usbpd_svid_handler *hdlr, u32 vdm_hdr,
+ const u32 *vdos, int num_vdos);
+
+ /* Structured VDM */
+ void (*svdm_received)(struct usbpd_svid_handler *hdlr, u8 cmd,
+ enum usbpd_svdm_cmd_type cmd_type, const u32 *vdos,
+ int num_vdos);
+
+ struct list_head entry;
+};
+
+enum plug_orientation {
+ ORIENTATION_NONE,
+ ORIENTATION_CC1,
+ ORIENTATION_CC2,
+};
+
+#if IS_ENABLED(CONFIG_USB_PD_POLICY)
+/*
+ * Obtains an instance of usbpd from a DT phandle
+ */
+struct usbpd *devm_usbpd_get_by_phandle(struct device *dev,
+ const char *phandle);
+
+/*
+ * Called by client to handle specific SVID messages.
+ * Specify callback functions in the usbpd_svid_handler argument
+ */
+int usbpd_register_svid(struct usbpd *pd, struct usbpd_svid_handler *hdlr);
+
+void usbpd_unregister_svid(struct usbpd *pd, struct usbpd_svid_handler *hdlr);
+
+/*
+ * Transmit a VDM message.
+ */
+int usbpd_send_vdm(struct usbpd *pd, u32 vdm_hdr, const u32 *vdos,
+ int num_vdos);
+
+/*
+ * Transmit a Structured VDM message.
+ */
+int usbpd_send_svdm(struct usbpd *pd, u16 svid, u8 cmd,
+ enum usbpd_svdm_cmd_type cmd_type, int obj_pos,
+ const u32 *vdos, int num_vdos);
+
+/*
+ * Get current status of CC pin orientation.
+ *
+ * Return: ORIENTATION_CC1 or ORIENTATION_CC2 if attached,
+ * otherwise ORIENTATION_NONE if not attached
+ */
+enum plug_orientation usbpd_get_plug_orientation(struct usbpd *pd);
+#else
+static inline struct usbpd *devm_usbpd_get_by_phandle(struct device *dev,
+ const char *phandle)
+{
+ return ERR_PTR(-ENODEV);
+}
+
+static inline int usbpd_register_svid(struct usbpd *pd,
+ struct usbpd_svid_handler *hdlr)
+{
+ return -EINVAL;
+}
+
+static inline void usbpd_unregister_svid(struct usbpd *pd,
+ struct usbpd_svid_handler *hdlr)
+{
+}
+
+static inline int usbpd_send_vdm(struct usbpd *pd, u32 vdm_hdr, const u32 *vdos,
+ int num_vdos)
+{
+ return -EINVAL;
+}
+
+static inline int usbpd_send_svdm(struct usbpd *pd, u16 svid, u8 cmd,
+ enum usbpd_svdm_cmd_type cmd_type, int obj_pos,
+ const u32 *vdos, int num_vdos)
+{
+ return -EINVAL;
+}
+
+static inline enum plug_orientation usbpd_get_plug_orientation(struct usbpd *pd)
+{
+ return ORIENTATION_NONE;
+}
+#endif /* IS_ENABLED(CONFIG_USB_PD_POLICY) */
+
+/*
+ * Additional helpers for Enter/Exit Mode commands
+ */
+
+static inline int usbpd_enter_mode(struct usbpd *pd, u16 svid, int mode,
+ const u32 *vdo)
+{
+ return usbpd_send_svdm(pd, svid, USBPD_SVDM_ENTER_MODE,
+ SVDM_CMD_TYPE_INITIATOR, mode, vdo, vdo ? 1 : 0);
+}
+
+static inline int usbpd_exit_mode(struct usbpd *pd, u16 svid, int mode,
+ const u32 *vdo)
+{
+ return usbpd_send_svdm(pd, svid, USBPD_SVDM_EXIT_MODE,
+ SVDM_CMD_TYPE_INITIATOR, mode, vdo, vdo ? 1 : 0);
+}
+
+#endif /* __LINUX_USB_USBPD_H */