You've already forked linux-rockchip
mirror of
https://github.com/armbian/linux-rockchip.git
synced 2026-01-06 11:08:10 -08:00
Merge 5.10.203 into android12-5.10-lts
Changes in 5.10.203
RDMA/irdma: Prevent zero-length STAG registration
PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
afs: Fix afs_server_list to be cleaned up with RCU
afs: Make error on cell lookup failure consistent with OpenAFS
drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence
drm/panel: auo,b101uan08.3: Fine tune the panel power sequence
drm/panel: simple: Fix Innolux G101ICE-L01 bus flags
drm/panel: simple: Fix Innolux G101ICE-L01 timings
wireguard: use DEV_STATS_INC()
ata: pata_isapnp: Add missing error check for devm_ioport_map()
drm/rockchip: vop: Fix color for RGB888/BGR888 format on VOP full
HID: core: store the unique system identifier in hid_device
HID: fix HID device resource race between HID core and debugging support
ipv4: Correct/silence an endian warning in __ip_do_redirect
net: usb: ax88179_178a: fix failed operations during ax88179_reset
net/smc: avoid data corruption caused by decline
arm/xen: fix xen_vcpu_info allocation alignment
amd-xgbe: handle corner-case during sfp hotplug
amd-xgbe: handle the corner-case during tx completion
amd-xgbe: propagate the correct speed and duplex status
net: axienet: Fix check for partial TX checksum
afs: Return ENOENT if no cell DNS record can be found
afs: Fix file locking on R/O volumes to operate in local mode
nvmet: remove unnecessary ctrl parameter
nvmet: nul-terminate the NQNs passed in the connect command
USB: dwc3: qcom: fix resource leaks on probe deferral
USB: dwc3: qcom: fix ACPI platform device leak
lockdep: Fix block chain corruption
media: ccs: Correctly initialise try compose rectangle
MIPS: KVM: Fix a build warning about variable set but not used
ext4: add a new helper to check if es must be kept
ext4: factor out __es_alloc_extent() and __es_free_extent()
ext4: use pre-allocated es in __es_insert_extent()
ext4: use pre-allocated es in __es_remove_extent()
ext4: using nofail preallocation in ext4_es_remove_extent()
ext4: using nofail preallocation in ext4_es_insert_delayed_block()
ext4: using nofail preallocation in ext4_es_insert_extent()
ext4: fix slab-use-after-free in ext4_es_insert_extent()
ext4: make sure allocate pending entry not fail
nfsd: lock_rename() needs both directories to live on the same fs
ASoC: simple-card: fixup asoc_simple_probe() error handling
ACPI: resource: Skip IRQ override on ASUS ExpertBook B1402CVA
swiotlb-xen: provide the "max_mapping_size" method
bcache: replace a mistaken IS_ERR() by IS_ERR_OR_NULL() in btree_gc_coalesce()
bcache: fixup multi-threaded bch_sectors_dirty_init() wake-up race
s390/dasd: protect device queue against concurrent access
USB: serial: option: add Luat Air72*U series products
hv_netvsc: Fix race of register_netdevice_notifier and VF register
hv_netvsc: Mark VF as slave before exposing it to user-mode
dm-delay: fix a race between delay_presuspend and delay_bio
bcache: check return value from btree_node_alloc_replacement()
bcache: prevent potential division by zero error
bcache: fixup init dirty data errors
bcache: fixup lock c->root error
USB: serial: option: add Fibocom L7xx modules
USB: serial: option: fix FM101R-GL defines
USB: serial: option: don't claim interface 4 for ZTE MF290
USB: dwc2: write HCINT with INTMASK applied
usb: dwc3: Fix default mode initialization
usb: dwc3: set the dma max_seg_size
USB: dwc3: qcom: fix wakeup after probe deferral
io_uring: fix off-by one bvec index
pinctrl: avoid reload of p state in list iteration
firewire: core: fix possible memory leak in create_units()
mmc: block: Do not lose cache flush during CQE error recovery
ALSA: hda: Disable power-save on KONTRON SinglePC
ALSA: hda/realtek: Headset Mic VREF to 100%
ALSA: hda/realtek: Add supported ALC257 for ChromeOS
dm-verity: align struct dm_verity_fec_io properly
dm verity: don't perform FEC for failed readahead IO
bcache: revert replacing IS_ERR_OR_NULL with IS_ERR
iommu/vt-d: Add MTL to quirk list to skip TE disabling
powerpc: Don't clobber f0/vs0 during fp|altivec register save
parisc: Drop the HP-UX ENOSYM and EREMOTERELEASE error codes
btrfs: add dmesg output for first mount and last unmount of a filesystem
btrfs: ref-verify: fix memory leaks in btrfs_ref_tree_mod()
btrfs: fix off-by-one when checking chunk map includes logical address
btrfs: send: ensure send_fd is writable
btrfs: make error messages more clear when getting a chunk map
Input: xpad - add HyperX Clutch Gladiate Support
hv_netvsc: fix race of netvsc and VF register_netdevice
USB: core: Change configuration warnings to notices
usb: config: fix iteration issue in 'usb_get_bos_descriptor()'
ipv4: igmp: fix refcnt uaf issue when receiving igmp query packet
dpaa2-eth: increase the needed headroom to account for alignment
selftests/net: ipsec: fix constant out of range
selftests/net: mptcp: fix uninitialized variable warnings
net: stmmac: xgmac: Disable FPE MMC interrupts
octeontx2-pf: Fix adding mbox work queue entry when num_vfs > 64
Revert "workqueue: remove unused cancel_work()"
r8169: prevent potential deadlock in rtl8169_close
ravb: Fix races between ravb_tx_timeout_work() and net related ops
net: ravb: Use pm_runtime_resume_and_get()
net: ravb: Start TX queues after HW initialization succeeded
smb3: fix touch -h of symlink
ASoC: Intel: Move soc_intel_is_foo() helpers to a generic header
ASoC: SOF: sof-pci-dev: use community key on all Up boards
ASoC: SOF: sof-pci-dev: add parameter to override topology filename
ASoC: SOF: sof-pci-dev: don't use the community key on APL Chromebooks
ASoC: SOF: sof-pci-dev: Fix community key quirk detection
s390/mm: fix phys vs virt confusion in mark_kernel_pXd() functions family
s390/cmma: fix detection of DAT pages
misc: pci_endpoint_test: Add deviceID for AM64 and J7200
misc: pci_endpoint_test: Add deviceID for J721S2 PCIe EP device support
fbdev: stifb: Make the STI next font pointer a 32-bit signed offset
ima: annotate iint mutex to avoid lockdep false positive warnings
driver core: Move the "removable" attribute from USB to core
drm/amdgpu: don't use ATRM for external devices
fs: add ctime accessors infrastructure
smb3: fix caching of ctime on setxattr
scsi: core: Introduce the scsi_cmd_to_rq() function
scsi: qla2xxx: Use scsi_cmd_to_rq() instead of scsi_cmnd.request
scsi: qla2xxx: Fix system crash due to bad pointer access
cpufreq: imx6q: don't warn for disabling a non-existing frequency
cpufreq: imx6q: Don't disable 792 Mhz OPP unnecessarily
mmc: cqhci: Increase recovery halt timeout
mmc: cqhci: Warn of halt or task clear failure
mmc: cqhci: Fix task clearing in CQE error recovery
mmc: core: convert comma to semicolon
mmc: block: Retry commands in CQE error recovery
mmc: core: add helpers mmc_regulator_enable/disable_vqmmc
mmc: sdhci-sprd: Fix vqmmc not shutting down after the card was pulled
r8169: disable ASPM in case of tx timeout
r8169: fix deadlock on RTL8125 in jumbo mtu mode
driver core: Release all resources during unbind before updating device links
Linux 5.10.203
Change-Id: I7feccd8526f0286020be24411be0e6113129ff65
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
@@ -154,17 +154,6 @@ Description:
|
||||
files hold a string value (enable or disable) indicating whether
|
||||
or not USB3 hardware LPM U1 or U2 is enabled for the device.
|
||||
|
||||
What: /sys/bus/usb/devices/.../removable
|
||||
Date: February 2012
|
||||
Contact: Matthew Garrett <mjg@redhat.com>
|
||||
Description:
|
||||
Some information about whether a given USB device is
|
||||
physically fixed to the platform can be inferred from a
|
||||
combination of hub descriptor bits and platform-specific data
|
||||
such as ACPI. This file will read either "removable" or
|
||||
"fixed" if the information is available, and "unknown"
|
||||
otherwise.
|
||||
|
||||
What: /sys/bus/usb/devices/.../ltm_capable
|
||||
Date: July 2012
|
||||
Contact: Sarah Sharp <sarah.a.sharp@linux.intel.com>
|
||||
|
||||
17
Documentation/ABI/testing/sysfs-devices-removable
Normal file
17
Documentation/ABI/testing/sysfs-devices-removable
Normal file
@@ -0,0 +1,17 @@
|
||||
What: /sys/devices/.../removable
|
||||
Date: May 2021
|
||||
Contact: Rajat Jain <rajatxjain@gmail.com>
|
||||
Description:
|
||||
Information about whether a given device can be removed from the
|
||||
platform by the user. This is determined by its subsystem in a
|
||||
bus / platform-specific way. This attribute is only present for
|
||||
devices that can support determining such information:
|
||||
|
||||
"removable": device can be removed from the platform by the user
|
||||
"fixed": device is fixed to the platform / cannot be removed
|
||||
by the user.
|
||||
"unknown": The information is unavailable / cannot be deduced.
|
||||
|
||||
Currently this is only supported by USB (which infers the
|
||||
information from a combination of hub descriptor bits and
|
||||
platform-specific data such as ACPI).
|
||||
2
Makefile
2
Makefile
@@ -1,7 +1,7 @@
|
||||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 10
|
||||
SUBLEVEL = 202
|
||||
SUBLEVEL = 203
|
||||
EXTRAVERSION =
|
||||
NAME = Dare mighty things
|
||||
|
||||
|
||||
@@ -362,7 +362,8 @@ static int __init xen_guest_init(void)
|
||||
* for secondary CPUs as they are brought up.
|
||||
* For uniformity we use VCPUOP_register_vcpu_info even on cpu0.
|
||||
*/
|
||||
xen_vcpu_info = alloc_percpu(struct vcpu_info);
|
||||
xen_vcpu_info = __alloc_percpu(sizeof(struct vcpu_info),
|
||||
1 << fls(sizeof(struct vcpu_info) - 1));
|
||||
if (xen_vcpu_info == NULL)
|
||||
return -ENOMEM;
|
||||
|
||||
|
||||
@@ -667,7 +667,7 @@ static int kvm_mips_map_page(struct kvm_vcpu *vcpu, unsigned long gpa,
|
||||
gfn_t gfn = gpa >> PAGE_SHIFT;
|
||||
int srcu_idx, err;
|
||||
kvm_pfn_t pfn;
|
||||
pte_t *ptep, entry, old_pte;
|
||||
pte_t *ptep, entry;
|
||||
bool writeable;
|
||||
unsigned long prot_bits;
|
||||
unsigned long mmu_seq;
|
||||
@@ -739,7 +739,6 @@ retry:
|
||||
entry = pfn_pte(pfn, __pgprot(prot_bits));
|
||||
|
||||
/* Write the PTE */
|
||||
old_pte = *ptep;
|
||||
set_pte(ptep, entry);
|
||||
|
||||
err = 0;
|
||||
|
||||
@@ -75,7 +75,6 @@
|
||||
|
||||
/* We now return you to your regularly scheduled HPUX. */
|
||||
|
||||
#define ENOSYM 215 /* symbol does not exist in executable */
|
||||
#define ENOTSOCK 216 /* Socket operation on non-socket */
|
||||
#define EDESTADDRREQ 217 /* Destination address required */
|
||||
#define EMSGSIZE 218 /* Message too long */
|
||||
@@ -101,7 +100,6 @@
|
||||
#define ETIMEDOUT 238 /* Connection timed out */
|
||||
#define ECONNREFUSED 239 /* Connection refused */
|
||||
#define EREFUSED ECONNREFUSED /* for HP's NFS apparently */
|
||||
#define EREMOTERELEASE 240 /* Remote peer released connection */
|
||||
#define EHOSTDOWN 241 /* Host is down */
|
||||
#define EHOSTUNREACH 242 /* No route to host */
|
||||
|
||||
|
||||
@@ -23,6 +23,15 @@
|
||||
#include <asm/feature-fixups.h>
|
||||
|
||||
#ifdef CONFIG_VSX
|
||||
#define __REST_1FPVSR(n,c,base) \
|
||||
BEGIN_FTR_SECTION \
|
||||
b 2f; \
|
||||
END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
||||
REST_FPR(n,base); \
|
||||
b 3f; \
|
||||
2: REST_VSR(n,c,base); \
|
||||
3:
|
||||
|
||||
#define __REST_32FPVSRS(n,c,base) \
|
||||
BEGIN_FTR_SECTION \
|
||||
b 2f; \
|
||||
@@ -41,9 +50,11 @@ END_FTR_SECTION_IFSET(CPU_FTR_VSX); \
|
||||
2: SAVE_32VSRS(n,c,base); \
|
||||
3:
|
||||
#else
|
||||
#define __REST_1FPVSR(n,b,base) REST_FPR(n, base)
|
||||
#define __REST_32FPVSRS(n,b,base) REST_32FPRS(n, base)
|
||||
#define __SAVE_32FPVSRS(n,b,base) SAVE_32FPRS(n, base)
|
||||
#endif
|
||||
#define REST_1FPVSR(n,c,base) __REST_1FPVSR(n,__REG_##c,__REG_##base)
|
||||
#define REST_32FPVSRS(n,c,base) __REST_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||
#define SAVE_32FPVSRS(n,c,base) __SAVE_32FPVSRS(n,__REG_##c,__REG_##base)
|
||||
|
||||
@@ -67,6 +78,7 @@ _GLOBAL(store_fp_state)
|
||||
SAVE_32FPVSRS(0, R4, R3)
|
||||
mffs fr0
|
||||
stfd fr0,FPSTATE_FPSCR(r3)
|
||||
REST_1FPVSR(0, R4, R3)
|
||||
blr
|
||||
EXPORT_SYMBOL(store_fp_state)
|
||||
|
||||
@@ -132,4 +144,5 @@ _GLOBAL(save_fpu)
|
||||
2: SAVE_32FPVSRS(0, R4, R6)
|
||||
mffs fr0
|
||||
stfd fr0,FPSTATE_FPSCR(r6)
|
||||
REST_1FPVSR(0, R4, R6)
|
||||
blr
|
||||
|
||||
@@ -32,6 +32,7 @@ _GLOBAL(store_vr_state)
|
||||
mfvscr v0
|
||||
li r4, VRSTATE_VSCR
|
||||
stvx v0, r4, r3
|
||||
lvx v0, 0, r3
|
||||
blr
|
||||
EXPORT_SYMBOL(store_vr_state)
|
||||
|
||||
@@ -104,6 +105,7 @@ _GLOBAL(save_altivec)
|
||||
mfvscr v0
|
||||
li r4,VRSTATE_VSCR
|
||||
stvx v0,r4,r7
|
||||
lvx v0,0,r7
|
||||
blr
|
||||
|
||||
#ifdef CONFIG_VSX
|
||||
|
||||
@@ -112,7 +112,7 @@ static void mark_kernel_pmd(pud_t *pud, unsigned long addr, unsigned long end)
|
||||
next = pmd_addr_end(addr, end);
|
||||
if (pmd_none(*pmd) || pmd_large(*pmd))
|
||||
continue;
|
||||
page = virt_to_page(pmd_val(*pmd));
|
||||
page = phys_to_page(pmd_val(*pmd));
|
||||
set_bit(PG_arch_1, &page->flags);
|
||||
} while (pmd++, addr = next, addr != end);
|
||||
}
|
||||
@@ -130,8 +130,8 @@ static void mark_kernel_pud(p4d_t *p4d, unsigned long addr, unsigned long end)
|
||||
if (pud_none(*pud) || pud_large(*pud))
|
||||
continue;
|
||||
if (!pud_folded(*pud)) {
|
||||
page = virt_to_page(pud_val(*pud));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(pud_val(*pud));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_pmd(pud, addr, next);
|
||||
@@ -151,8 +151,8 @@ static void mark_kernel_p4d(pgd_t *pgd, unsigned long addr, unsigned long end)
|
||||
if (p4d_none(*p4d))
|
||||
continue;
|
||||
if (!p4d_folded(*p4d)) {
|
||||
page = virt_to_page(p4d_val(*p4d));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(p4d_val(*p4d));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_pud(p4d, addr, next);
|
||||
@@ -173,8 +173,8 @@ static void mark_kernel_pgd(void)
|
||||
if (pgd_none(*pgd))
|
||||
continue;
|
||||
if (!pgd_folded(*pgd)) {
|
||||
page = virt_to_page(pgd_val(*pgd));
|
||||
for (i = 0; i < 3; i++)
|
||||
page = phys_to_page(pgd_val(*pgd));
|
||||
for (i = 0; i < 4; i++)
|
||||
set_bit(PG_arch_1, &page[i].flags);
|
||||
}
|
||||
mark_kernel_p4d(pgd, addr, next);
|
||||
|
||||
@@ -448,6 +448,13 @@ static const struct dmi_system_id asus_laptop[] = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GMxXGxx"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* Asus ExpertBook B1402CVA */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_SYS_VENDOR, "ASUSTeK COMPUTER INC."),
|
||||
DMI_MATCH(DMI_BOARD_NAME, "B1402CVA"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GM6XGxX/TUXEDO Stellaris 16 Gen5 AMD */
|
||||
.matches = {
|
||||
|
||||
@@ -82,6 +82,9 @@ static int isapnp_init_one(struct pnp_dev *idev, const struct pnp_device_id *dev
|
||||
if (pnp_port_valid(idev, 1)) {
|
||||
ctl_addr = devm_ioport_map(&idev->dev,
|
||||
pnp_port_start(idev, 1), 1);
|
||||
if (!ctl_addr)
|
||||
return -ENOMEM;
|
||||
|
||||
ap->ioaddr.altstatus_addr = ctl_addr;
|
||||
ap->ioaddr.ctl_addr = ctl_addr;
|
||||
ap->ops = &isapnp_port_ops;
|
||||
|
||||
@@ -2338,6 +2338,25 @@ static ssize_t online_store(struct device *dev, struct device_attribute *attr,
|
||||
}
|
||||
static DEVICE_ATTR_RW(online);
|
||||
|
||||
static ssize_t removable_show(struct device *dev, struct device_attribute *attr,
|
||||
char *buf)
|
||||
{
|
||||
const char *loc;
|
||||
|
||||
switch (dev->removable) {
|
||||
case DEVICE_REMOVABLE:
|
||||
loc = "removable";
|
||||
break;
|
||||
case DEVICE_FIXED:
|
||||
loc = "fixed";
|
||||
break;
|
||||
default:
|
||||
loc = "unknown";
|
||||
}
|
||||
return sysfs_emit(buf, "%s\n", loc);
|
||||
}
|
||||
static DEVICE_ATTR_RO(removable);
|
||||
|
||||
int device_add_groups(struct device *dev, const struct attribute_group **groups)
|
||||
{
|
||||
return sysfs_create_groups(&dev->kobj, groups);
|
||||
@@ -2515,8 +2534,16 @@ static int device_add_attrs(struct device *dev)
|
||||
goto err_remove_dev_online;
|
||||
}
|
||||
|
||||
if (dev_removable_is_valid(dev)) {
|
||||
error = device_create_file(dev, &dev_attr_removable);
|
||||
if (error)
|
||||
goto err_remove_dev_waiting_for_supplier;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
err_remove_dev_waiting_for_supplier:
|
||||
device_remove_file(dev, &dev_attr_waiting_for_supplier);
|
||||
err_remove_dev_online:
|
||||
device_remove_file(dev, &dev_attr_online);
|
||||
err_remove_dev_groups:
|
||||
@@ -2536,6 +2563,7 @@ static void device_remove_attrs(struct device *dev)
|
||||
struct class *class = dev->class;
|
||||
const struct device_type *type = dev->type;
|
||||
|
||||
device_remove_file(dev, &dev_attr_removable);
|
||||
device_remove_file(dev, &dev_attr_waiting_for_supplier);
|
||||
device_remove_file(dev, &dev_attr_online);
|
||||
device_remove_groups(dev, dev->groups);
|
||||
|
||||
@@ -1187,8 +1187,6 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
||||
else if (drv->remove)
|
||||
drv->remove(dev);
|
||||
|
||||
device_links_driver_cleanup(dev);
|
||||
|
||||
devres_release_all(dev);
|
||||
arch_teardown_dma_ops(dev);
|
||||
kfree(dev->dma_range_map);
|
||||
@@ -1200,6 +1198,8 @@ static void __device_release_driver(struct device *dev, struct device *parent)
|
||||
pm_runtime_reinit(dev);
|
||||
dev_pm_set_driver_flags(dev, 0);
|
||||
|
||||
device_links_driver_cleanup(dev);
|
||||
|
||||
klist_remove(&dev->p->knode_driver);
|
||||
device_pm_check_callbacks(dev);
|
||||
if (dev->bus)
|
||||
|
||||
@@ -209,6 +209,14 @@ static struct cpufreq_driver imx6q_cpufreq_driver = {
|
||||
.suspend = cpufreq_generic_suspend,
|
||||
};
|
||||
|
||||
static void imx6x_disable_freq_in_opp(struct device *dev, unsigned long freq)
|
||||
{
|
||||
int ret = dev_pm_opp_disable(dev, freq);
|
||||
|
||||
if (ret < 0 && ret != -ENODEV)
|
||||
dev_warn(dev, "failed to disable %ldMHz OPP\n", freq / 1000000);
|
||||
}
|
||||
|
||||
#define OCOTP_CFG3 0x440
|
||||
#define OCOTP_CFG3_SPEED_SHIFT 16
|
||||
#define OCOTP_CFG3_SPEED_1P2GHZ 0x3
|
||||
@@ -254,17 +262,15 @@ static int imx6q_opp_check_speed_grading(struct device *dev)
|
||||
val &= 0x3;
|
||||
|
||||
if (val < OCOTP_CFG3_SPEED_996MHZ)
|
||||
if (dev_pm_opp_disable(dev, 996000000))
|
||||
dev_warn(dev, "failed to disable 996MHz OPP\n");
|
||||
imx6x_disable_freq_in_opp(dev, 996000000);
|
||||
|
||||
if (of_machine_is_compatible("fsl,imx6q") ||
|
||||
of_machine_is_compatible("fsl,imx6qp")) {
|
||||
if (val != OCOTP_CFG3_SPEED_852MHZ)
|
||||
if (dev_pm_opp_disable(dev, 852000000))
|
||||
dev_warn(dev, "failed to disable 852MHz OPP\n");
|
||||
imx6x_disable_freq_in_opp(dev, 852000000);
|
||||
|
||||
if (val != OCOTP_CFG3_SPEED_1P2GHZ)
|
||||
if (dev_pm_opp_disable(dev, 1200000000))
|
||||
dev_warn(dev, "failed to disable 1.2GHz OPP\n");
|
||||
imx6x_disable_freq_in_opp(dev, 1200000000);
|
||||
}
|
||||
|
||||
return 0;
|
||||
@@ -316,20 +322,16 @@ static int imx6ul_opp_check_speed_grading(struct device *dev)
|
||||
val >>= OCOTP_CFG3_SPEED_SHIFT;
|
||||
val &= 0x3;
|
||||
|
||||
if (of_machine_is_compatible("fsl,imx6ul")) {
|
||||
if (of_machine_is_compatible("fsl,imx6ul"))
|
||||
if (val != OCOTP_CFG3_6UL_SPEED_696MHZ)
|
||||
if (dev_pm_opp_disable(dev, 696000000))
|
||||
dev_warn(dev, "failed to disable 696MHz OPP\n");
|
||||
}
|
||||
imx6x_disable_freq_in_opp(dev, 696000000);
|
||||
|
||||
if (of_machine_is_compatible("fsl,imx6ull")) {
|
||||
if (val != OCOTP_CFG3_6ULL_SPEED_792MHZ)
|
||||
if (dev_pm_opp_disable(dev, 792000000))
|
||||
dev_warn(dev, "failed to disable 792MHz OPP\n");
|
||||
if (val < OCOTP_CFG3_6ULL_SPEED_792MHZ)
|
||||
imx6x_disable_freq_in_opp(dev, 792000000);
|
||||
|
||||
if (val != OCOTP_CFG3_6ULL_SPEED_900MHZ)
|
||||
if (dev_pm_opp_disable(dev, 900000000))
|
||||
dev_warn(dev, "failed to disable 900MHz OPP\n");
|
||||
imx6x_disable_freq_in_opp(dev, 900000000);
|
||||
}
|
||||
|
||||
return ret;
|
||||
|
||||
@@ -719,14 +719,11 @@ static void create_units(struct fw_device *device)
|
||||
fw_unit_attributes,
|
||||
&unit->attribute_group);
|
||||
|
||||
if (device_register(&unit->device) < 0)
|
||||
goto skip_unit;
|
||||
|
||||
fw_device_get(device);
|
||||
continue;
|
||||
|
||||
skip_unit:
|
||||
kfree(unit);
|
||||
if (device_register(&unit->device) < 0) {
|
||||
put_device(&unit->device);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#include "amdgpu.h"
|
||||
#include "atom.h"
|
||||
|
||||
#include <linux/device.h>
|
||||
#include <linux/pci.h>
|
||||
#include <linux/slab.h>
|
||||
#include <linux/acpi.h>
|
||||
@@ -285,6 +286,10 @@ static bool amdgpu_atrm_get_bios(struct amdgpu_device *adev)
|
||||
if (adev->flags & AMD_IS_APU)
|
||||
return false;
|
||||
|
||||
/* ATRM is for on-platform devices only */
|
||||
if (dev_is_removable(&adev->pdev->dev))
|
||||
return false;
|
||||
|
||||
while ((pdev = pci_get_class(PCI_CLASS_DISPLAY_VGA << 8, pdev)) != NULL) {
|
||||
dhandle = ACPI_HANDLE(&pdev->dev);
|
||||
if (!dhandle)
|
||||
|
||||
@@ -36,6 +36,7 @@ struct panel_desc {
|
||||
const struct panel_init_cmd *init_cmds;
|
||||
unsigned int lanes;
|
||||
bool discharge_on_disable;
|
||||
bool lp11_before_reset;
|
||||
};
|
||||
|
||||
struct boe_panel {
|
||||
@@ -551,6 +552,10 @@ static int boe_panel_prepare(struct drm_panel *panel)
|
||||
|
||||
usleep_range(5000, 10000);
|
||||
|
||||
if (boe->desc->lp11_before_reset) {
|
||||
mipi_dsi_dcs_nop(boe->dsi);
|
||||
usleep_range(1000, 2000);
|
||||
}
|
||||
gpiod_set_value(boe->enable_gpio, 1);
|
||||
usleep_range(1000, 2000);
|
||||
gpiod_set_value(boe->enable_gpio, 0);
|
||||
@@ -692,6 +697,7 @@ static const struct panel_desc auo_b101uan08_3_desc = {
|
||||
.mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
|
||||
MIPI_DSI_MODE_LPM,
|
||||
.init_cmds = auo_b101uan08_3_init_cmd,
|
||||
.lp11_before_reset = true,
|
||||
};
|
||||
|
||||
static const struct drm_display_mode boe_tv105wum_nw0_default_mode = {
|
||||
@@ -719,6 +725,7 @@ static const struct panel_desc boe_tv105wum_nw0_desc = {
|
||||
.mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
|
||||
MIPI_DSI_MODE_LPM,
|
||||
.init_cmds = boe_init_cmd,
|
||||
.lp11_before_reset = true,
|
||||
};
|
||||
|
||||
static int boe_panel_get_modes(struct drm_panel *panel,
|
||||
|
||||
@@ -2154,13 +2154,13 @@ static const struct panel_desc innolux_g070y2_l01 = {
|
||||
static const struct display_timing innolux_g101ice_l01_timing = {
|
||||
.pixelclock = { 60400000, 71100000, 74700000 },
|
||||
.hactive = { 1280, 1280, 1280 },
|
||||
.hfront_porch = { 41, 80, 100 },
|
||||
.hback_porch = { 40, 79, 99 },
|
||||
.hsync_len = { 1, 1, 1 },
|
||||
.hfront_porch = { 30, 60, 70 },
|
||||
.hback_porch = { 30, 60, 70 },
|
||||
.hsync_len = { 22, 40, 60 },
|
||||
.vactive = { 800, 800, 800 },
|
||||
.vfront_porch = { 5, 11, 14 },
|
||||
.vback_porch = { 4, 11, 14 },
|
||||
.vsync_len = { 1, 1, 1 },
|
||||
.vfront_porch = { 3, 8, 14 },
|
||||
.vback_porch = { 3, 8, 14 },
|
||||
.vsync_len = { 4, 7, 12 },
|
||||
.flags = DISPLAY_FLAGS_DE_HIGH,
|
||||
};
|
||||
|
||||
@@ -2177,6 +2177,7 @@ static const struct panel_desc innolux_g101ice_l01 = {
|
||||
.disable = 200,
|
||||
},
|
||||
.bus_format = MEDIA_BUS_FMT_RGB888_1X7X4_SPWG,
|
||||
.bus_flags = DRM_BUS_FLAG_DE_HIGH,
|
||||
.connector_type = DRM_MODE_CONNECTOR_LVDS,
|
||||
};
|
||||
|
||||
|
||||
@@ -248,14 +248,22 @@ static inline void vop_cfg_done(struct vop *vop)
|
||||
VOP_REG_SET(vop, common, cfg_done, 1);
|
||||
}
|
||||
|
||||
static bool has_rb_swapped(uint32_t format)
|
||||
static bool has_rb_swapped(uint32_t version, uint32_t format)
|
||||
{
|
||||
switch (format) {
|
||||
case DRM_FORMAT_XBGR8888:
|
||||
case DRM_FORMAT_ABGR8888:
|
||||
case DRM_FORMAT_BGR888:
|
||||
case DRM_FORMAT_BGR565:
|
||||
return true;
|
||||
/*
|
||||
* full framework (IP version 3.x) only need rb swapped for RGB888 and
|
||||
* little framework (IP version 2.x) only need rb swapped for BGR888,
|
||||
* check for 3.x to also only rb swap BGR888 for unknown vop version
|
||||
*/
|
||||
case DRM_FORMAT_RGB888:
|
||||
return VOP_MAJOR(version) == 3;
|
||||
case DRM_FORMAT_BGR888:
|
||||
return VOP_MAJOR(version) != 3;
|
||||
default:
|
||||
return false;
|
||||
}
|
||||
@@ -988,7 +996,7 @@ static void vop_plane_atomic_update(struct drm_plane *plane,
|
||||
VOP_WIN_SET(vop, win, dsp_info, dsp_info);
|
||||
VOP_WIN_SET(vop, win, dsp_st, dsp_st);
|
||||
|
||||
rb_swap = has_rb_swapped(fb->format->format);
|
||||
rb_swap = has_rb_swapped(vop->data->version, fb->format->format);
|
||||
VOP_WIN_SET(vop, win, rb_swap, rb_swap);
|
||||
|
||||
/*
|
||||
|
||||
@@ -703,15 +703,22 @@ static void hid_close_report(struct hid_device *device)
|
||||
* Free a device structure, all reports, and all fields.
|
||||
*/
|
||||
|
||||
static void hid_device_release(struct device *dev)
|
||||
void hiddev_free(struct kref *ref)
|
||||
{
|
||||
struct hid_device *hid = to_hid_device(dev);
|
||||
struct hid_device *hid = container_of(ref, struct hid_device, ref);
|
||||
|
||||
hid_close_report(hid);
|
||||
kfree(hid->dev_rdesc);
|
||||
kfree(hid);
|
||||
}
|
||||
|
||||
static void hid_device_release(struct device *dev)
|
||||
{
|
||||
struct hid_device *hid = to_hid_device(dev);
|
||||
|
||||
kref_put(&hid->ref, hiddev_free);
|
||||
}
|
||||
|
||||
/*
|
||||
* Fetch a report description item from the data stream. We support long
|
||||
* items, though they are not used yet.
|
||||
@@ -2445,10 +2452,12 @@ int hid_add_device(struct hid_device *hdev)
|
||||
hid_warn(hdev, "bad device descriptor (%d)\n", ret);
|
||||
}
|
||||
|
||||
hdev->id = atomic_inc_return(&id);
|
||||
|
||||
/* XXX hack, any other cleaner solution after the driver core
|
||||
* is converted to allow more than 20 bytes as the device name? */
|
||||
dev_set_name(&hdev->dev, "%04X:%04X:%04X.%04X", hdev->bus,
|
||||
hdev->vendor, hdev->product, atomic_inc_return(&id));
|
||||
hdev->vendor, hdev->product, hdev->id);
|
||||
|
||||
hid_debug_register(hdev, dev_name(&hdev->dev));
|
||||
ret = device_add(&hdev->dev);
|
||||
@@ -2491,6 +2500,7 @@ struct hid_device *hid_allocate_device(void)
|
||||
spin_lock_init(&hdev->debug_list_lock);
|
||||
sema_init(&hdev->driver_input_lock, 1);
|
||||
mutex_init(&hdev->ll_open_lock);
|
||||
kref_init(&hdev->ref);
|
||||
|
||||
return hdev;
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user