mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-25 03:50:24 +09:00
Merge tag 'android14-5.15.148_r00' into android14-5.15
This merges up to the 5.15.148 LTS release into the android14-5.15 branch. Included in here are the following commits: *30f4052325Merge "Merge branch 'android14-5.15' into branch 'android14-5.15-lts'" into android14-5.15-lts |\ | *2e2880028cMerge branch 'android14-5.15' into branch 'android14-5.15-lts' * |abe9e11e84UPSTREAM: drm/msm/dsi: Enable runtime PM * |6205c3735fUPSTREAM: PM: runtime: Have devm_pm_runtime_enable() handle pm_runtime_dont_use_autosuspend() |/ *c169b3e6e4Merge 5.15.148 into android14-5.15-lts |\ | *6139f2a02fLinux 5.15.148 | *84c39986feRevert "Revert "md/raid5: Wait for MD_SB_CHANGE_PENDING in raid5d"" | *c8483a4845arm64: dts: armada-3720-turris-mox: set irq type for RTC | *98052220f1netfilter: nft_quota: copy content when cloning expression | *3be3c61232netfilter: nft_last: copy content when cloning expression | *42d4617848netfilter: nft_limit: Clone packet limits' cost value | *d808805851netfilter: nft_limit: fix stateful object memory leak | *e562d84225netfilter: nft_connlimit: memleak if nf_ct_netns_get() fails | *10823cfe8enetfilter: nf_tables: typo NULL check in _clone() function | *0f2dca5165block: Remove special-casing of compound pages | *08bf561118i2c: s3c24xx: fix transferring more than one message in polling mode | *38ce342a19i2c: s3c24xx: fix read transfers in polling mode | *62b3387beeipv6: mcast: fix data-race in ipv6_mc_down / mld_ifc_work | *58485b95fdselftests: mlxsw: qos_pfc: Adjust the test to support 8 lanes | *348112522amlxsw: spectrum_acl_tcam: Fix stack corruption | *005f2d10f9mlxsw: spectrum_acl_tcam: Reorder functions to avoid forward declarations | *077c4776d7mlxsw: spectrum_acl_tcam: Make fini symmetric to init | *d28048d319mlxsw: spectrum_acl_tcam: Add missing mutex_destroy() | *196f3595e8mlxsw: spectrum: Use 'bitmap_zalloc()' when applicable | *87c5403393mlxsw: spectrum_acl_erp: Fix error flow of pool allocation failure | *3732db294eethtool: netlink: Add missing ethnl_ops_begin/complete | *7f3d781e0dkdb: Fix a potential buffer overflow in kdb_local() | *995d6099d8ipvs: avoid stat macros calls from preemptible context | *27513eff4cnetfilter: nf_tables: reject NFT_SET_CONCAT with not field length description | *d6420b66adnetfilter: nf_tables: skip dead set elements in netlink dump | *77be8c495anetfilter: nf_tables: do not allow mismatch field size and set key length | *b8eb65bd13netfilter: nft_limit: do not ignore unsupported flags | *d7b5da4fdenetfilter: nf_tables: memcg accounting for dynamically allocated objects | *3bb4403d20netfilter: nft_limit: move stateful fields out of expression data | *8a6635074anetfilter: nft_limit: rename stateful structure | *e2e8fdd0adnetfilter: nft_quota: move stateful fields out of expression data | *b147911d2anetfilter: nft_last: move stateful fields out of expression data | *36997eb13dnetfilter: nft_connlimit: move stateful fields out of expression data | *713a138855netfilter: nf_tables: reject invalid set policy | *78e8546646net: dsa: vsc73xx: Add null pointer check to vsc73xx_gpio_probe | *29ffa63f21bpf: Reject variable offset alu on PTR_TO_FLOW_KEYS | *684290895anet: stmmac: ethtool: Fixed calltrace caused by unbalanced disable_irq_wake calls | *8e481c7f81net: ravb: Fix dma_addr_t truncation in error case | *f05301ad05mptcp: use OPTION_MPTCP_MPJ_SYN in subflow_check_req() | *413b913507mptcp: use OPTION_MPTCP_MPJ_SYNACK in subflow_finish_connect() | *9b82d5f5d0mptcp: strict validation before using mp_opt->hmac | *c99f490a42mptcp: drop unused sk in mptcp_get_options | *cbe983d0e4mptcp: mptcp_parse_option() fix for MPTCPOPT_MP_JOIN | *4f2c4ba321net: phy: micrel: populate .soft_reset for KSZ9131 | *890bc96ef1net: ethernet: ti: am65-cpsw: Fix max mtu to fit ethernet frames | *3b52548622net: qualcomm: rmnet: fix global oob in rmnet_policy | *18babcfa36s390/pci: fix max size calculation in zpci_memcpy_toio() | *bf3304054ePCI: keystone: Fix race condition when initializing PHYs | *a300f741f6nvmet-tcp: Fix the H2C expected PDU len calculation | *b02a005b19nvmet: re-fix tracing strncpy() warning | *763c67e96bserial: imx: Correct clock error message in function probe() | *1ed3c20205usb: xhci-mtk: fix a short packet issue of gen1 isoc-in transfer | *0a12db736eapparmor: avoid crash when parsed profile name is empty | *367d061a18perf env: Avoid recursively taking env->bpf_progs.lock | *0613a2fbdfnvmet-tcp: fix a crash in nvmet_req_complete() | *4cb3cf7177nvmet-tcp: Fix a kernel panic when host sends an invalid H2C PDU length | *013d7878c7usb: cdc-acm: return correct error code on unsupported break | *c50f88954ctty: use 'if' in send_break() instead of 'goto' | *a222bd01catty: don't check for signal_pending() in send_break() | *370b18aefetty: early return from send_break() on TTY_DRIVER_HARDWARE_BREAK | *6f98751fa4tty: change tty_write_lock()'s ndelay parameter to bool | *7ab8ef24fdperf genelf: Set ELF program header addresses properly | *08715e4fa5iio: adc: ad9467: fix scale setting | *d7773702f8iio: adc: ad9467: don't ignore error codes | *fd1957c706iio: adc: ad9467: fix reset gpio handling | *71204292a7iio: adc: ad9467: Benefit from devm_clk_get_enabled() to simplify | *fbcc37f4b4selftests/sgx: Skip non X86_64 platform | *71005a1d9bselftests/sgx: Fix uninitialized pointer dereference in error path | *ff168d4fdbserial: imx: fix tx statemachine deadlock | *714778c299software node: Let args be NULL in software_node_get_reference_args | *c203812b4elibapi: Add missing linux/types.h header to get the __u64 type on io.h | *828cd82948serial: 8250: omap: Don't skip resource freeing if pm_runtime_resume_and_get() failed | *96d289b57dpower: supply: bq256xx: fix some problem in bq256xx_hw_init | *435671571epower: supply: cw2015: correct time_to_empty units in sysfs | *07733ca556MIPS: Alchemy: Fix an out-of-bound access in db1550_dev_setup() | *4590f46c15MIPS: Alchemy: Fix an out-of-bound access in db1200_dev_setup() | *c1669b54c3riscv: Fix module_alloc() that did not reset the linear mapping permissions | *938f70d146riscv: Check if the code to patch lies in the exit section | *8e0935435bmips: Fix incorrect max_low_pfn adjustment | *4b88c9c83fmips: dmi: Fix early remap on MIPS32 | *d1c8c7ef39mfd: intel-lpss: Fix the fractional clock divider flags | *6109ff5ad5leds: aw2013: Select missing dependency REGMAP_I2C | *c3e3a2144bmfd: syscon: Fix null pointer dereference in of_syscon_register() | *a004323a38ARM: 9330/1: davinci: also select PINCTRL | *77c20b4cbciommu/dma: Trace bounce buffer usage when mapping buffers | *fc7c3be665serial: sc16is7xx: set safe default SPI clock frequency | *160ef3fc35serial: sc16is7xx: add check for unsupported SPI modes during probe | *b1effdda4fHID: wacom: Correct behavior when processing some confidence == false touches | *400ad6fe24iio: adc: ad7091r: Pass iio_dev to event handler | *12c2759ab1KVM: arm64: vgic-its: Avoid potential UAF in LPI translation cache | *d99976d145KVM: arm64: vgic-v4: Restore pending state on host userspace write | *9bd4c6e658x86/kvm: Do not try to disable kvmclock if it was not enabled | *a4563156c3PCI: mediatek: Clear interrupt status before dispatching handler | *0f59d3772aPCI: dwc: endpoint: Fix dw_pcie_ep_raise_msix_irq() alignment support | *25aab84f1awifi: mwifiex: configure BSSID consistently when starting AP | *a61373d32cwifi: rtlwifi: Convert LNKCTL change to PCIe cap RMW accessors | *1f0b697913wifi: rtlwifi: Remove bogus and dangerous ASPM disable/enable code | *5600943b0cwifi: mt76: fix broken precal loading from MTD for mt7915 | *4124a004d5iommu/arm-smmu-qcom: Add missing GMU entry to match table | *a7b98aa10fbpf: Fix re-attachment branch in bpf_tracing_prog_attach | *4c71c01df8Bluetooth: Fix atomicity violation in {min,max}_key_size_set | *27e58d3b52rootfs: Fix support for rootfstype= when root= is given | *79ea1c6f06io_uring/rw: ensure io->bytes_done is always initialized | *801c8adb85pwm: jz4740: Don't use dev_err_probe() in .request() | *c9ed30eea4netfilter: nf_tables: check if catch-all set element is active in next generation | *5010c27120block: add check that partition length needs to be aligned with block size | *6a73c9fdb7scsi: mpi3mr: Refresh sdev queue depth after controller reset | *610ca0cadbfbdev: flush deferred work in fb_deferred_io_fsync() | *cb32c0e1bdALSA: hda/relatek: Enable Mute LED on HP Laptop 15s-fq2xxx | *d37d61c077ALSA: oxygen: Fix right channel of capture volume mixer | *314cf7c2ddserial: imx: Ensure that imx_uart_rs485_config() is called with enabled clock | *ac0c3a2fe7usb: mon: Fix atomicity violation in mon_bin_vma_fault | *d7ce8ebd50usb: typec: class: fix typec_altmode_put_partner to put plugs | *4212a9ff65Revert "usb: typec: class: fix typec_altmode_put_partner to put plugs" | *2c64904a0eusb: cdns3: Fix uvc fail when DMA cross 4k boundery since sg enabled | *e1b3be9babusb: cdns3: fix iso transfer error when mult is not zero | *9cdf2c9159usb: cdns3: fix uvc failure work since sg support enabled | *2e349cf0d0usb: chipidea: wait controller resume finished for wakeup irq | *295b4fa321Revert "usb: dwc3: don't reset device side if dwc3 was configured as host-only" | *4f5a109b8fRevert "usb: dwc3: Soft reset phy on probe for host" | *ea968824c4usb: dwc: ep0: Update request status in dwc3_ep0_stall_restart | *e3e35301f1usb: phy: mxs: remove CONFIG_USB_OTG condition for mxs_phy_is_otg_host() | *41e05f246ftick-sched: Fix idle and iowait sleeptime accounting vs CPU hotplug | *98fee5bee9binder: fix race between mmput() and do_exit() | *e03023fcdbxen-netback: don't produce zero-size SKB frags | *409c30ff6cvirtio-crypto: fix memory leak in virtio_crypto_alg_skcipher_close_session() | *f97f612864dma-mapping: Fix build error unused-value | *72d29dcdf5Input: atkbd - use ab83 as id when skipping the getid command | *9c1fa9eedcbinder: fix unused alloc->free_async_space | *c44b276bc1binder: fix async space check for 0-sized buffers | *0921867f77keys, dns: Fix size check of V1 server-list header | *10193a5001selftests/bpf: Add assert for user stacks in test_task_stack | *cc9c60b253of: unittest: Fix of_count_phandle_with_args() expected value message | *4541004084of: Fix double free in of_parse_phandle_with_args_map | *83f5d6c1efksmbd: validate the zero field of packet header | *4af4674158drm/amd/pm/smu7: fix a memleak in smu7_hwmgr_backend_init | *bf1acc6258IB/iser: Prevent invalidating wrong MR | *106136f209mmc: sdhci_omap: Fix TI SoC dependencies | *da9eae2c1ammc: sdhci_am654: Fix TI SoC dependencies | *e517645eadALSA: scarlett2: Add clamp() in scarlett2_mixer_ctl_put() | *3a09488f4fALSA: scarlett2: Add missing error checks to *_ctl_get() | *12023666f2ALSA: scarlett2: Allow passing any output to line_out_remap() | *51d5697e1cALSA: scarlett2: Add missing error check to scarlett2_usb_set_config() | *0ba9386e19ALSA: scarlett2: Add missing error check to scarlett2_config_save() | *c60490b817ASoC: rt5645: Drop double EF20 entry from dmi_platform_data[] | *cf55afb5a5pwm: stm32: Fix enable count for clk in .probe() | *df19bf4044pwm: stm32: Use hweight32 in stm32_pwm_detect_channels | *c82c21e7d9pwm: stm32: Use regmap_clear_bits and regmap_set_bits where applicable | *fa019c01dbclk: fixed-rate: fix clk_hw_register_fixed_rate_with_accuracy_parent_hw | *256d1232c8clk: fixed-rate: add devm_clk_hw_register_fixed_rate | *a30ca04ddeclk: asm9260: use parent index to link the reference clock | *c45ca73b01clk: si5341: fix an error code problem in si5341_output_clk_set_rate | *347f9d7258watchdog: rti_wdt: Drop runtime pm reference count when watchdog is unused | *3646d83db8watchdog: bcm2835_wdt: Fix WDIOC_SETTIMEOUT handling | *1711bdfe5ewatchdog/hpwdt: Only claim UNKNOWN NMI if from iLO | *b9bced8ca7watchdog: set cdev owner before adding | *9117fc44fddrivers: clk: zynqmp: update divider round rate logic | *8f4941940dclk: zynqmp: Add a check for NULL pointer | *f46c0ec5a5clk: zynqmp: make bestdiv unsigned | *e27660be6fdrivers: clk: zynqmp: calculate closest mux rate | *8aff5f6723clk: qcom: videocc-sm8150: Add missing PLL config property | *b31526b8c5clk: qcom: videocc-sm8150: Update the videocc resets | *1dd84d5e83dt-bindings: clock: Update the videocc resets for sm8150 | *c72dbb780dgpu/drm/radeon: fix two memleaks in radeon_vm_init | *b6dcba02eedrivers/amd/pm: fix a use-after-free in kv_parse_power_table | *2bf47c89bbdrm/amd/pm: fix a double-free in si_dpm_init | *11d1f2d895drm/amdgpu/debugfs: fix error code when smc register accessors are NULL | *720919b58dmedia: dvb-frontends: m88ds3103: Fix a memory leak in an error handling path of m88ds3103_probe() | *0a50ca097amedia: dvbdev: drop refcount on error path in dvb_device_open() | *11e60be408f2fs: fix the f2fs_file_write_iter tracepoint | *f3a220d975f2fs: fix to update iostat correctly in f2fs_filemap_fault() | *df2571b4d5f2fs: fix to check compress file in f2fs_move_file_range() | *a3316290a8media: rkisp1: Disable runtime PM in probe error path | *f4176c5185clk: qcom: gpucc-sm8150: Update the gpu_cc_pll1 config | *d3a8c5c783media: cx231xx: fix a memleak in cx231xx_init_isoc | *9f583fc91cdrm/bridge: tc358767: Fix return value on error case | *a3cb0b5b1bdrm/bridge: cdns-mhdp8546: Fix use of uninitialized variable | *a5934df4dfdrm/radeon/trinity_dpm: fix a memleak in trinity_parse_power_table | *1a6cccd7fddrm/radeon/dpm: fix a memleak in sumo_parse_power_table | *14bbfaa5dfdrm/radeon: check the alloc_workqueue return value in radeon_crtc_init() | *929af5cd8adrm/drv: propagate errors from drm_modeset_register_all() | *cbf207b171drm/msm/dsi: Use pm_runtime_resume_and_get to prevent refcnt leaks | *6d8dc61985drm/msm/mdp4: flush vblank event on disable | *d3aa670bbaASoC: cs35l34: Fix GPIO name and drop legacy include | *a0f27f673eASoC: cs35l33: Fix GPIO name and drop legacy include | *528844bb1edrm/radeon: check return value of radeon_ring_lock() | *4e57efe03adrm/radeon/r100: Fix integer overflow issues in r100_cs_track_check() | *1f7008dd12drm/radeon/r600_cs: Fix possible int overflows in r600_cs_check_reg() | *f100ba617df2fs: fix to avoid dirent corruption | *4c5e6a02dcdrm/bridge: Fix typo in post_disable() description | *ec3634ebe2media: pvrusb2: fix use after free on context disconnection | *1821c4d1c3drm/tilcdc: Fix irq free on unload | *08ccff6ecedrm/bridge: tpd12s015: Drop buggy __exit annotation for remove function | *45c4c4b04adrm/nouveau/fence:: fix warning directly dereferencing a rcu pointer | *ab45a15a50drm/panel-elida-kd35t133: hold panel in reset for unprepare | *a811031da2RDMA/hns: Fix inappropriate err code for unsupported operations | *5245c05cd9RDMA/usnic: Silence uninitialized symbol smatch warnings | *ab8038e7bcRevert "drm/omapdrm: Annotate dma-fence critical section in commit path" | *d847363bc5Revert "drm/tidss: Annotate dma-fence critical section in commit path" | *13e3dd2df0ARM: davinci: always select CONFIG_CPU_ARM926T | *4329426cf6ip6_tunnel: fix NEXTHDR_FRAGMENT handling in ip6_tnl_parse_tlv_enc_lim() | *d0464a7edfmlxbf_gige: Enable the GigE port in mlxbf_gige_open | *8d632d0fd2net: mellanox: mlxbf_gige: Replace non-standard interrupt handling | *86f3df0495mlxbf_gige: Fix intermittent no ip issue | *172ba7d46cnet/sched: act_ct: fix skb leak and crash on ooo frags | *c3d8edb170null_blk: don't cap max_hw_sectors to BLK_DEF_MAX_SECTORS | *8676b014e4block: make BLK_DEF_MAX_SECTORS unsigned | *ce3440b699Bluetooth: btmtkuart: fix recv_buf() return value | *cede5d0c29Bluetooth: Fix bogus check for re-auth no supported with non-ssp | *166d65b0d5netfilter: nf_tables: mark newset as dead on transaction abort | *e907e95729wifi: iwlwifi: mvm: send TX path flush in rfkill | *8d6c614212wifi: iwlwifi: mvm: set siso/mimo chains to 1 in FW SMPS request | *5f4ea050bbwifi: rtlwifi: rtl8192se: using calculate_bit_shift() | *aaf4723f52wifi: rtlwifi: rtl8192ee: using calculate_bit_shift() | *dbbbd2cc8fwifi: rtlwifi: rtl8192de: using calculate_bit_shift() | *7e0d54f5dcwifi: rtlwifi: rtl8192ce: using calculate_bit_shift() | *5dbc5c5222wifi: rtlwifi: rtl8192cu: using calculate_bit_shift() | *62de564726wifi: rtlwifi: rtl8192c: using calculate_bit_shift() | *aec0dee37bwifi: rtlwifi: rtl8188ee: phy: using calculate_bit_shift() | *37871c978dwifi: rtlwifi: add calculate_bit_shift() | *493cfed247arm64: dts: qcom: sc7280: Mark SDHCI hosts as cache-coherent | *2c97f94500block: add check of 'minors' and 'first_minor' in device_add_disk() | *df4f5a35c5arm64: dts: qcom: sm8150-hdk: fix SS USB regulators | *6f20058dadsoc: qcom: llcc: Fix dis_cap_alloc and retain_on_pc configuration | *ccc94806d0dma-mapping: clear dev->dma_mem to NULL after freeing it | *99326214f9dma-mapping: Add dma_release_coherent_memory to DMA API | *930cd34addvirtio/vsock: fix logic which reduces credit update messages | *a18eff8ba0selftests/net: fix grep checking for fib_nexthop_multiprefix | *62c904c472scsi: hisi_sas: Correct the number of global debugfs registers | *6bf2126107scsi: hisi_sas: Rollback some operations if FLR failed | *84e174afb5scsi: hisi_sas: Replace with standard error code return value | *0d17931d7escsi: hisi_sas: Prevent parallel FLR and controller reset | *0760d1d6d8scsi: hisi_sas: Rename HISI_SAS_{RESET -> RESETTING}_BIT | *80b0b7c79fblock: Set memalloc_noio to false on device_add_disk() error path | *0296268425bpf: Fix verification of indirect var-off stack access | *8c2127dc93arm64: dts: qcom: sc7280: fix usb_2 wakeup interrupt types | *97c60adff1arm64: dts: qcom: sdm845-db845c: correct LED panic indicator | *6211a043abarm64: dts: qcom: qrb5165-rb5: correct LED panic indicator | *609c7d556cscsi: fnic: Return error if vmalloc() failed | *67e6707f07bpf: fix check for attempt to corrupt spilled pointer | *f40cd60f3farm64: dts: qcom: sm8250: Make watchdog bark interrupt edge triggered | *a413fdd3eaarm64: dts: qcom: sm8150: Make watchdog bark interrupt edge triggered | *a78ae10607arm64: dts: qcom: sdm845: Make watchdog bark interrupt edge triggered | *06ec7a3961arm64: dts: qcom: sc7280: Make watchdog bark interrupt edge triggered | *0c55ace45darm64: dts: qcom: sc7180: Make watchdog bark interrupt edge triggered | *65b28cad75ARM: dts: qcom: sdx65: correct SPMI node name | *bb88e2174abpf: enforce precision of R0 on callback return | *fa5b150abfarm64: dts: ti: k3-am65-main: Fix DSS irq trigger type | *18051358d9wifi: rtlwifi: rtl8821ae: phy: fix an undefined bitwise shift behavior | *bf98ac3288firmware: meson_sm: populate platform devices from sm device tree data | *41b3228281firmware: ti_sci: Fix an off-by-one in ti_sci_debugfs_create() | *7e36646237net/ncsi: Fix netlink major/minor version numbers | *024e24086eARM: dts: qcom: apq8064: correct XOADC register address | *ef2373f31fwifi: libertas: stop selecting wext | *69f7c1f5d2wifi: ath11k: Defer on rproc_get failure | *131afd9a57bpf: Add crosstask check to __bpf_get_stack | *1ed921e42abpf, lpm: Fix check prefixlen before walking trie | *2b67863c5bwifi: rtw88: fix RX filter in FIF_ALLMULTI flag | *9d4f4dea82NFSv4.1/pnfs: Ensure we handle the error NFS4ERR_RETURNCONFLICT | *d0e09a7ba3blocklayoutdriver: Fix reference leak of pnfs_device_node | *a5f2f91b3fcrypto: scomp - fix req->dst buffer overflow | *dc6779550fcrypto: sahara - do not resize req->src when doing hash operations | *a5e0e39daccrypto: sahara - fix processing hash requests with req->nbytes < sg->length | *2dc0f23ac4crypto: sahara - improve error handling in sahara_sha_process() | *faa25455f7crypto: sahara - fix wait_for_completion_timeout() error handling | *2104f405afcrypto: sahara - fix ahash reqsize | *34c6a33567crypto: sahara - handle zero-length aes requests | *a7b435e816crypto: sahara - avoid skcipher fallback code duplication | *b1664c5334crypto: virtio - Wait for tasklet to complete on device remove | *ee0586d73cgfs2: Fix kernel NULL pointer dereference in gfs2_rgrp_dump | *00e3321c65fs: indicate request originates from old mount API | *8fb12524c8pstore: ram_core: fix possible overflow in persistent_ram_init_ecc() | *8dd9e58c69crypto: sahara - fix error handling in sahara_hw_descriptor_create() | *3413d878fdcrypto: sahara - fix processing requests with cryptlen < sg->length | *a962882a35crypto: sahara - fix ahash selftest failure | *6f31caf8aacrypto: sahara - fix cbc selftest failure | *6fb7db05adcrypto: sahara - remove FLAGS_NEW_KEY logic | *d2205b9b57crypto: af_alg - Disallow multiple in-flight AIO requests | *088123ddb4crypto: ccp - fix memleak in ccp_init_dm_workarea | *d3ff5362b4crypto: sa2ul - Return crypto_aead_setkey to transfer the error | *75cba72ddbcrypto: virtio - Handle dataq logic with tasklet | *5e37fa0b4cselinux: Fix error priority for bind with AF_UNSPEC on PF_INET6 socket | *d8ac253776mtd: Fix gluebi NULL pointer dereference caused by ftl notifier | *a252d5c1efkunit: debugfs: Fix unchecked dereference in debugfs_print_results() | *f23aa841a0ACPI: extlog: Clear Extended Error Log status when RAS_CEC handled the error | *f5de4ad61dACPI: LPSS: Fix the fractional clock divider flags | *6b15fb99b0spi: sh-msiof: Enforce fixed DTDL for R-Car H3 | *2aa141f8bcefivarfs: force RO when remounting if SetVariable is not supported | *a4529a08d3calipso: fix memory leak in netlbl_calipso_add_pass() | *dd645fc8f8cpufreq: scmi: process the result of devm_of_clk_add_hw_provider() | *aead146e88cpufreq: Use of_property_present() for testing DT property presence | *435841c106of: Add of_property_present() helper | *c5df417936of: property: define of_property_read_u{8,16,32,64}_array() unconditionally | *c1814a4ffdACPI: LPIT: Avoid u32 multiplication overflow | *3a370502a5ACPI: video: check for error while searching for backlight device parent | *45f6080748mtd: rawnand: Increment IFC_TIMEOUT_MSECS for nand controller response | *9c92f01bb9spi: spi-zynqmp-gqspi: fix driver kconfig dependencies | *f105c26300powerpc/imc-pmu: Add a null pointer check in update_events_in_group() | *6b58d16037powerpc/powernv: Add a null pointer check in opal_powercap_init() | *c0b111ea78powerpc/powernv: Add a null pointer check in opal_event_init() | *2a82c4439bpowerpc/powernv: Add a null pointer check to scom_debug_init_one() | *5daf0ef626selftests/powerpc: Fix error handling in FPU/VMX preemption tests | *999a27b3cepowerpc/pseries/memhp: Fix access beyond end of drmem array | *5d69c8859epowerpc/44x: select I2C for CURRITUCK | *467c9c9dc0powerpc: add crtsavres.o to always-y instead of extra-y | *0b11a145ebpowerpc: remove checks for binutils older than 2.25 | *63ecb08533powerpc/toc: Future proof kernel toc | *2de654d858powerpc: Mark .opd section read-only | *700cf4beadEDAC/thunderx: Fix possible out-of-bounds string access | *b53730a40ex86/lib: Fix overflow when counting digits | *0a43304cf6coresight: etm4x: Fix width of CCITMIN field | *b67064bd37PCI: Add ACS quirk for more Zhaoxin Root Ports | *e62243b353leds: ledtrig-tty: Free allocated ttyname buffer on deactivate | *6c3388c0afparport: parport_serial: Add Brainboxes device IDs and geometry | *72095a5430parport: parport_serial: Add Brainboxes BAR details | *5cf604ee53uio: Fix use-after-free in uio_open | *659be220e6binder: fix comment on binder_alloc_new_buf() return value | *2900c0ee59binder: fix trivial typo of binder_free_buf_locked() | *8ad4d580e8binder: fix use-after-free in shinker's callback | *1263bd9e08binder: use EPOLLERR from eventpoll.h | *0ee3ded745Revert "md/raid5: Wait for MD_SB_CHANGE_PENDING in raid5d" | *12b07f443dkprobes: Fix to handle forcibly unoptimized kprobes on freeing_list | *66cb0868b1bpf: Add --skip_encoding_btf_inconsistent_proto, --btf_gen_optimized to pahole flags for v1.25 | *2a2495b6a3Revert "ASoC: atmel: Remove system clock tree configuration for at91sam9g20ek" | *313cfcaefaACPI: resource: Add another DMI match for the TongFang GMxXGxx | *dec512974cdrm/crtc: fix uninitialized variable use | *21eea9b6c4ARM: sun9i: smp: fix return code check of of_property_match_string | *dc26b67704net: qrtr: ns: Return 0 if server port is not present | *5dbcdaf4dbida: Fix crash in ida_free when the bitmap is empty | *c9f5b801bci2c: rk3x: fix potential spinlock recursion on poll | *3f0dc646b5ASoC: Intel: bytcr_rt5640: Add quirk for the Medion Lifetab S10346 | *adf4616a44Input: xpad - add Razer Wolverine V2 support | *d66ffc87bawifi: iwlwifi: pcie: avoid a NULL pointer dereference | *fd13543dbbARC: fix spare error | *b3f44f21d3s390/scm: fix virtual vs physical address confusion | *46445552edInput: i8042 - add nomux quirk for Acer P459-G2-M | *0f0da2d6bdInput: atkbd - skip ATKBD_CMD_GETID in translated mode | *274b4c8162reset: hisilicon: hi6220: fix Wvoid-pointer-to-enum-cast warning | *5d307038faring-buffer: Do not record in NMI if the arch does not support cmpxchg in NMI | *a9655e7e4btracing: Fix uaf issue when open the hist or hist_debug file | *64d81f61adMIPS: dts: loongson: drop incorrect dwmac fallback compatible | *3f483a39e2stmmac: dwmac-loongson: drop useless check for compatible fallback | *aeb0d506f7tracing: Add size check when printing trace_marker output | *c3729567detracing: Have large events show up as '[LINE TOO BIG]' instead of nothing | *c8af7ad729jbd2: fix soft lockup in journal_finish_inode_data_buffers() | *7b0586ada9platform/x86: intel-vbtn: Fix missing tablet-mode-switch events | *6511772fc0neighbour: Don't let neigh_forced_gc() disable preemption for long | *2e1846b0c0drm/crtc: Fix uninit-value bug in drm_mode_setcrtc | *c01c44559ajbd2: correct the printing of write_flags in jbd2_write_superblock() | *5378fd3c43clk: rockchip: rk3128: Fix HCLK_OTG gate register | *a14da83838hwmon: (corsair-psu) Fix probe when built-in | *7945405205drm/exynos: fix a wrong error checking | *e02a2693aedrm/exynos: fix a potential error pointer dereference | *10250096f3drm/amdgpu: Add NULL checks for function pointers | *8b98524821nvme: introduce helper function to get ctrl state | *c11fc224e5ASoC: ops: add correct range check for limiting volume | *09c0f2814bASoC: da7219: Support low DC impedance headset | *16d3a65eaanet/tg3: fix race condition in tg3_reset_task() | *9904379f19nouveau/tu102: flush all pdbs on vmm flush | *7a3ff8a2bbASoC: rt5650: add mutex to avoid the jack detection failure | *ebf8d5ec4aASoC: cs43130: Fix incorrect frame delay configuration | *ec52e3e241ASoC: cs43130: Fix the position of const qualifier | *ce6cce0799ASoC: Intel: Skylake: mem leak in skl register function | *cb6b6ff7a7ASoC: nau8822: Fix incorrect type in assignment and cast to restricted __be16 | *4ec0f3b3d8ASoC: Intel: Skylake: Fix mem leak in few functions | *20e23f6b14ASoC: wm8974: Correct boost mixer inputs | *05d753d74cnvme-core: check for too small lba shift | *9ad8b171c4drm/amdgpu: Fix cat debugfs amdgpu_regs_didt causes kernel null pointer | *f8eadbe713debugfs: fix automount d_fsdata usage | *473fb46aa3wifi: cfg80211: lock wiphy mutex for rfkill poll | *5d520ae3damptcp: fix uninit-value in mptcp_incoming_options | *8d40e3514aALSA: hda - Fix speaker and headset mic pin config for CHUWI CoreBook XPro | *3dec0bd9c0pinctrl: lochnagar: Don't build on MIPS | *32a6cfc676f2fs: explicitly null-terminate the xattr list * |0e69322670Merge branch 'android14-5.15' into branch 'android14-5.15-lts' * |2c882816b1Revert "ipv6: remove max_size check inline with ipv4" * |a51283fc69Merge "Merge 5.15.147 into android14-5.15-lts" into android14-5.15-lts |\ \ | * |5352f41951Merge 5.15.147 into android14-5.15-lts | |\| | | *ddcaf49990Linux 5.15.147 | | *231752a0a0net: usb: ax88179_178a: move priv to driver_priv | | *d800d18ba1net: usb: ax88179_178a: remove redundant init code | | *329197033btracing/kprobes: Fix symbol counting logic by looking at modules as well | | *ccb7eef5f2kallsyms: Make module_kallsyms_on_each_symbol generally available | | *ab3a3aadb3netfilter: nf_tables: Reject tables of unsupported family | | *0eb556b238perf inject: Fix GEN_ELF_TEXT_OFFSET for jit | | *b8a5308feeipv6: remove max_size check inline with ipv4 | | *ba5efd8544net: tls, update curr on splice as well | | *06bb52d2efmmc: sdhci-sprd: Fix eMMC init failure after hw reset | | *6722186854mmc: core: Cancel delayed work before releasing host | | *edaefc210emmc: rpmb: fixes pause retune on all RPMB partitions. | | *41f20ac9bdmmc: meson-mx-sdhc: Fix initialization frozen issue | | *91432aebcemm: fix unmap_mapping_range high bits shift bug | | *5e44f5da12i2c: core: Fix atomic xfer check for non-preempt config | | *1d5c1617e1x86/kprobes: fix incorrect return address calculation in kprobe_emulate_call_indirect | | *10086ff58cfirewire: ohci: suppress unexpected system reboot in AMD Ryzen machines and ASM108x/VT630x PCIe cards | | *660b3c3bc8mm/memory-failure: check the mapcount of the precise page | | *80eb449f80selftests: secretmem: floor the memory size to the multiple of page_size | | *a58ae5ab71net: Implement missing SO_TIMESTAMPING_NEW cmsg support | | *500c7f32adbnxt_en: Remove mis-applied code from bnxt_cfg_ntp_filters() | | *fda00eb3cdasix: Add check for usbnet_get_endpoints | | *0817c1b215octeontx2-af: Re-enable MAC TX in otx2_stop processing | | *20fce91b4focteontx2-af: Always configure NIX TX link credits based on max frame size | | *6bbbcff3c7octeontx2-af: Set NIX link credits based on max LMAC | | *6ef9a28e1bocteontx2-af: Don't enable Pause frames by default | | *bc56ed720enet/qla3xxx: fix potential memleak in ql_alloc_buffer_queues | | *cfcf549014igc: Fix hicredit calculation | | *6c853b5768i40e: Restore VF MSI-X state during PCI reset | | *9400f854faASoC: meson: g12a-tohdmitx: Fix event generation for S/PDIF mux | | *e08b666e44ASoC: meson: g12a-toacodec: Fix event generation | | *3a78a57764ASoC: meson: g12a-tohdmitx: Validate written enum values | | *f74281f241ASoC: meson: g12a-toacodec: Validate written enum values | | *947db598aci40e: fix use-after-free in i40e_aqc_add_filters() | | *975d6f66f2net: Save and restore msg_namelen in sock_sendmsg | | *b2869e7600netfilter: nft_immediate: drop chain reference counter on error | | *51976846f2net: bcmgenet: Fix FCS generation for fragmented skbuffs | | *c748c358desfc: fix a double-free bug in efx_probe_filters | | *5c161f2220ARM: sun9i: smp: Fix array-index-out-of-bounds read in sunxi_mc_smp_init | | *fd2e782923net-timestamp: extend SOF_TIMESTAMPING_OPT_ID to HW timestamps | | *dc5643abc1can: raw: add support for SO_MARK | | *464fb49ca9can: raw: add support for SO_TXTIME/SCM_TXTIME | | *ba80ff7a85net: Implement missing getsockopt(SO_TIMESTAMPING_NEW) | | *5636941e42r8169: Fix PCI error on system resume | | *0ce9a244d3net: sched: em_text: fix possible memory leak in em_text_destroy() | | *c0b56aa9d1mlxbf_gige: fix receive packet race condition | | *271567afd4ASoC: fsl_rpmsg: Fix error handler with pm_runtime_enable | | *1867a90947igc: Check VLAN EtherType mask | | *f24370ddf7igc: Check VLAN TCI mask | | *4ec5efdb90igc: Report VLAN EtherType matching back to user | | *b17f8024a5i40e: Fix filter input checks to prevent config with invalid values | | *def90597efdrm/i915/dp: Fix passing the correct DPCD_REV for drm_dp_set_phy_test_pattern | | *a7b67635deocteontx2-af: Fix marking couple of structure as __packed | | *802af3c88anfc: llcp_core: Hold a ref to llcp_local->dev when holding a ref to llcp_local | | *5d3e98ef12drm/bridge: ti-sn65dsi86: Never store more than msg->size bytes in AUX xfer | | *2f8cefc8b6wifi: iwlwifi: pcie: don't synchronize IRQs from IRQ | | *1f2f662c8bRevert "PCI/ASPM: Remove pcie_aspm_pm_state_change()" | | *200cecd6ffALSA: hda/realtek: Fix mute and mic-mute LEDs for HP ProBook 440 G6 | | *90ab9a70f0block: Don't invalidate pagecache for invalid falloc modes | | *c496c35310keys, dns: Fix missing size check of V1 server-list header * | |9f5237b3b3ANDROID: db845c: Enable device tree overlay support |/ / * |91bf8d14e7Revert "device property: Add const qualifier to device_get_match_data() parameter" * |88efb6da37Revert "spi: Introduce spi_get_device_match_data() helper" * |049200ae06Revert "iio: imu: adis16475: add spi_device_id table" * |34a1ceac5aRevert "device property: Allow const parameter to dev_fwnode()" * |19757b5e8dMerge 5.15.146 into android14-5.15-lts |\| | *26c690eff0Linux 5.15.146 | *13578b4ea4bpf: Fix prog_array_map_poke_run map poke update | *339add0430device property: Allow const parameter to dev_fwnode() | *4d9dcdb333dm-integrity: don't modify bio's immutable bio_vec in integrity_metadata() | *a033bb82a1ring-buffer: Fix slowpath of interrupted event | *d10f7540c5netfilter: nf_tables: skip set commit for deleted/destroyed sets | *d739f2b6d8ksmbd: fix slab-out-of-bounds in smb_strndup_from_utf16() | *53bed9b9f4ring-buffer: Remove useless update to write_stamp in rb_try_to_discard() | *7fb264aedetracing: Fix blocked reader of snapshot buffer | *c73cb01af1ring-buffer: Fix wake ups when buffer_percent is set to 100 | *c0be52181fmm/filemap: avoid buffered read/write race to read inconsistent data | *2b16d960c7Bluetooth: af_bluetooth: Fix Use-After-Free in bt_sock_recvmsg | *ded3cfdefesmb: client: fix OOB in smbCalcSize() | *bfd18c0f57smb: client: fix OOB in SMB2_query_info_init() | *1228354a98iio: imu: adis16475: add spi_device_id table | *bd1be85dbbspi: Introduce spi_get_device_match_data() helper | *fcf6fce2f1device property: Add const qualifier to device_get_match_data() parameter | *d63fafd6ccnet: usb: ax88179_178a: avoid failed operations when device is disconnected | *f860413aa0net: usb: ax88179_178a: wol optimizations | *2964a0de75net: usb: ax88179_178a: clean up pm calls | *597305fd77ethernet: constify references to netdev->dev_addr in drivers | *32d9a4ce52usb: fotg210-hcd: delete an incorrect bounds test | *d529cc2278ARM: dts: Fix occasional boot hang for am3 usb | *8bf06286d7ksmbd: fix wrong allocation size update in smb2_open() | *06208a04a7ksmbd: avoid duplicate opinfo_put() call on error of smb21_lease_break_ack() | *9444c47d2cksmbd: lazy v2 lease break on smb2_write() | *f58afd8c70ksmbd: send v2 lease break notification for directory | *86967f6965ksmbd: downgrade RWH lease caching state to RH for directory | *f7c8270be3ksmbd: set v2 lease capability | *1bf476d8a8ksmbd: set epoch in create context v2 lease | *ac38551859ksmbd: have a dependency on cifs ARC4 | *b54b9fbc16fuse: share lookup state between submount and its parent | *1c811b7c83x86/alternatives: Sync core before enabling interrupts | *ccda72aa73KVM: arm64: vgic: Force vcpu vgic teardown on vcpu destroy | *46bc250b08lib/vsprintf: Fix %pfwf when current node refcount == 0 | *f9dc6e0a0bgpio: dwapb: mask/unmask IRQ when disable/enale it | *e4d3534c68bus: ti-sysc: Flush posted write only after srst_udelay | *d47b2b6a08tracing / synthetic: Disable events after testing in synth_event_gen_test_init() | *da95f8b7bcscsi: core: Always send batch on reset or error handling command | *686774523fdt-bindings: nvmem: mxs-ocotp: Document fsl,ocotp | *7c25c5d727net: ks8851: Fix TX stall caused by TX buffer overrun | *28855385bfnet: rfkill: gpio: set GPIO direction | *4431cf7c33net: 9p: avoid freeing uninit memory in p9pdu_vreadf | *85fd35ce5bInput: soc_button_array - add mapping for airplane mode button | *a346cfc638Bluetooth: MGMT/SMP: Fix address type when using SMP over BREDR/LE | *916ca52a3eBluetooth: L2CAP: Send reject on command corrupted request | *70db6466c0Bluetooth: hci_event: Fix not checking if HCI_OP_INQUIRY has been sent | *094ae245f7USB: serial: option: add Quectel RM500Q R13 firmware support | *d0adf8fe08USB: serial: option: add Foxconn T99W265 with new baseline | *a67f0b5bc2USB: serial: option: add Quectel EG912Y module support | *0e285069fdUSB: serial: ftdi_sio: update Actisense PIDs constant names | *433889344ewifi: cfg80211: fix certs build to not depend on file order | *69fab6dc37wifi: cfg80211: Add my certificate | *498f212a77ALSA: usb-audio: Increase delay in MOTU M quirk | *5a16bb60b8iio: triggered-buffer: prevent possible freeing of wrong buffer | *3becd9bc5aiio: adc: ti_am335x_adc: Fix return value check of tiadc_request_dma() | *b9ccf18e31iio: common: ms_sensors: ms_sensors_i2c: fix humidity conversion time table | *f1d9a66e9cscsi: bnx2fc: Fix skb double free in bnx2fc_rcv() | *1e3effe67eInput: ipaq-micro-keys - add error handling for devm_kmemdup | *25c441a073iio: imu: inv_mpu6050: fix an error code problem in inv_mpu6050_read_raw | *3cbae23d48interconnect: Treat xlate() returning NULL node as an error | *f47e3f60f2smb: client: fix OOB in smb2_query_reparse_point() | *fd3951b798smb: client: fix NULL deref in asn1_ber_decoder() | *6ded9038e4drm/i915: Fix intel_atomic_setup_scalers() plane_state handling | *f9954b18c4drm/i915: Relocate intel_atomic_setup_scalers() | *2a4ef0d6e5drm/i915/mtl: limit second scaler vertical scaling in ver >= 14 | *6bbeb3960aksmbd: fix wrong name of SMB2_CREATE_ALLOCATION_SIZE | *c0c4e9767egpiolib: cdev: add gpio_device locking wrapper around gpio_ioctl() | *8bdcedfdb0pinctrl: at91-pio4: use dedicated lock class for IRQ | *f0c52b790ai2c: aspeed: Handle the coalesced stop conditions with the start conditions. | *c87ab6e306ASoC: hdmi-codec: fix missing report for jack initial status | *98fb5eaadeafs: Fix use-after-free due to get/remove race in volume tree | *57bf562950afs: Use refcount_t rather than atomic_t | *d1fe946cb5afs: Fix overwriting of result of DNS query | *2552b32b0bkeys, dns: Allow key types (eg. DNS) to be reclaimed immediately on expiry | *a1ab650f14net: check dev->gso_max_size in gso_features_check() | *56eaa3ec31afs: Fix dynamic root lookup DNS check | *3f85785bc4afs: Fix the dynamic root's d_delete to always delete unused dentries | *3739e0a52dnet: check vlan filter feature in vlan_vids_add_by_dev() and vlan_vids_del_by_dev() | *c124a75b24net: mana: select PAGE_POOL | *c0e527c532net/rose: fix races in rose_kill_by_device() | *66d2116880ethernet: atheros: fix a memleak in atl1e_setup_ring_resources | *87255af408net: sched: ife: fix potential use-after-free | *242670aab8net/mlx5e: Correct snprintf truncation handling for fw_version buffer used by representors | *da2396b546net/mlx5: Fix fw tracer first block check | *b0873aa484net/mlx5e: fix a potential double-free in fs_udp_create_groups | *4ddba57b65net/mlx5e: Fix slab-out-of-bounds in mlx5_query_nic_vport_mac_list() | *5ae420f65aRevert "net/mlx5e: fix double free of encap_header" | *135fa6fac9Revert "net/mlx5e: fix double free of encap_header in update funcs" | *b387f06849wifi: mac80211: mesh_plink: fix matches_local logic | *6558f4aa20wifi: iwlwifi: pcie: add another missing bh-disable for rxq->lock | *183ea95f73s390/vx: fix save/restore of fpu kernel context | *58f3fc8333reset: Fix crash when freeing non-existent optional resets | *52c69a070bARM: OMAP2+: Fix null pointer dereference and memory leak in omap_soc_device_init | *d3ffbbb0bcARM: dts: dra7: Fix DRA7 L3 NoC node register size * |3a3430e518Merge 5.15.145 into android14-5.15-lts |\| | *d93fa2c788Linux 5.15.145 | *ee41f667aakasan: disable kasan_non_canonical_hook() for HW tags | *f30f893143tracing/kprobes: Return EADDRNOTAVAIL when func matches several symbols | *7aa33c99b5Revert "drm/bridge: lt9611uxc: Switch to devm MIPI-DSI helpers" | *4a8350a0eaRevert "drm/bridge: lt9611uxc: Register and attach our DSI device at probe" | *e21817ce16Revert "drm/bridge: lt9611uxc: fix the race in the error path" | *811b5eaee7ksmbd: don't update ->op_state as OPLOCK_STATE_NONE on error | *bd47f9c8b5ksmbd: move setting SMB2_FLAGS_ASYNC_COMMAND and AsyncId | *5e1f31378aksmbd: release interim response after sending status pending response | *c21d044508ksmbd: move oplock handling after unlock parent dir | *772d81aeecksmbd: separately allocate ci per dentry | *8ed1118da8ksmbd: fix possible deadlock in smb2_open | *ae3356cbe9ksmbd: prevent memory leak on error return | *8dc9eb7d35ksmbd: handle malformed smb1 message | *1f50c418d4ksmbd: fix kernel-doc comment of ksmbd_vfs_kern_path_locked() | *3fecda5d85ksmbd: no need to wait for binded connection termination at logoff | *841bcade09ksmbd: add support for surrogate pair conversion | *0eaeb8aec4ksmbd: fix missing RDMA-capable flag for IPoIB device in ksmbd_rdma_capable_netdev() | *20b4f6bd4cksmbd: fix recursive locking in vfs helpers | *f30a2ff715ksmbd: fix kernel-doc comment of ksmbd_vfs_setxattr() | *df79244f73ksmbd: reorganize ksmbd_iov_pin_rsp() | *845837fbfeksmbd: Remove unused field in ksmbd_user struct | *fab0175b7fksmbd: fix potential double free on smb2_read_pipe() error path | *ef435dec8aksmbd: fix Null pointer dereferences in ksmbd_update_fstate() | *4b9b7ea1ffksmbd: fix wrong error response status by using set_smb2_rsp_status() | *dd45db4d9bksmbd: fix race condition between tree conn lookup and disconnect | *0901be8dc6ksmbd: fix race condition from parallel smb2 lock requests | *50e13932baksmbd: fix race condition from parallel smb2 logoff requests | *f99d5d1d2aksmbd: fix race condition with fp | *c77fd3e25aksmbd: fix race condition between session lookup and expire | *b9a3e45496ksmbd: check iov vector index in ksmbd_conn_write() | *01df133b1aksmbd: return invalid parameter error response if smb2 request is invalid | *4a67467f11ksmbd: fix passing freed memory 'aux_payload_buf' | *fbed0adfe5ksmbd: remove unneeded mark_inode_dirty in set_info_sec() | *a9128c4134ksmbd: remove experimental warning | *6997fa65bfksmbd: add missing calling smb2_set_err_rsp() on error | *bd554ed4fdksmbd: fix slub overflow in ksmbd_decode_ntlmssp_auth_blob() | *7019440463ksmbd: Fix one kernel-doc comment | *c5aa74449aksmbd: reduce descriptor size if remaining bytes is less than request size | *e12b092416ksmbd: fix `force create mode' and `force directory mode' | *6f0207218cksmbd: fix wrong interim response on compound | *f2283680a8ksmbd: add support for read compound | *d7ad0ac5a8ksmbd: switch to use kmemdup_nul() helper | *5c0df9d30cksmbd: fix out of bounds in init_smb2_rsp_hdr() | *017d85c94fksmbd: validate session id and tree id in compound request | *4a027b9651ksmbd: check if a mount point is crossed during path lookup | *cf63b94fecksmbd: Fix unsigned expression compared with zero | *5f36e22910ksmbd: Replace one-element array with flexible-array member | *d9902ad14fksmbd: Use struct_size() helper in ksmbd_negotiate_smb_dialect() | *97f5c1e308ksmbd: add missing compound request handing in some commands | *6763921847ksmbd: fix out of bounds read in smb2_sess_setup | *d91ba80185ksmbd: Replace the ternary conditional operator with min() | *2222ada095ksmbd: use kvzalloc instead of kvmalloc | *638043bef9ksmbd: Change the return value of ksmbd_vfs_query_maximal_access to void | *7585898ddfksmbd: return a literal instead of 'err' in ksmbd_vfs_kern_path_locked() | *4910a79a5fksmbd: use kzalloc() instead of __GFP_ZERO | *b657622862ksmbd: remove unused ksmbd_tree_conn_share function | *ce95f7d2dcksmbd: add mnt_want_write to ksmbd vfs functions | *0d1a3f97efksmbd: validate smb request protocol id | *df3a4518aeksmbd: check the validation of pdu_size in ksmbd_conn_handler_loop | *ae33f07c87ksmbd: fix posix_acls and acls dereferencing possible ERR_PTR() | *55ceeb4e1cksmbd: fix out-of-bound read in parse_lease_state() | *4adb4fbd74ksmbd: fix out-of-bound read in deassemble_neg_contexts() | *049ed0f953ksmbd: call putname after using the last component | *b423ddab61ksmbd: fix UAF issue from opinfo->conn | *19b2b9af31ksmbd: fix multiple out-of-bounds read during context decoding | *61a306c1ccksmbd: fix uninitialized pointer read in smb2_create_link() | *ea799dd275ksmbd: fix uninitialized pointer read in ksmbd_vfs_rename() | *b36295c17fksmbd: fix racy issue under cocurrent smb2 tree disconnect | *ae06b798f7ksmbd: fix racy issue from smb2 close and logoff with multichannel | *dff87902d9ksmbd: block asynchronous requests when making a delay on session setup | *a6a9601ba9ksmbd: destroy expired sessions | *708c304b58ksmbd: fix racy issue from session setup and logoff | *019aae488dksmbd: fix racy issue from using ->d_parent and ->d_name | *b31e1ef301fs: introduce lock_rename_child() helper | *380a0fe8bdksmbd: remove unused compression negotiate ctx packing | *0dbfcc34efksmbd: avoid duplicate negotiate ctx offset increments | *2ca23947dfksmbd: set NegotiateContextCount once instead of every inc | *39f5b4b313ksmbd: avoid out of bounds access in decode_preauth_ctxt() | *921536046bksmbd: fix slab-out-of-bounds in init_smb2_rsp_hdr | *9494242c8eksmbd: delete asynchronous work from list | *427caadf90ksmbd: remove unused is_char_allowed function | *289b46fd11ksmbd: fix wrong signingkey creation when encryption is AES256 | *bfe8372ef2ksmbd: fix possible memory leak in smb2_lock() | *d625db885aksmbd: Fix parameter name and comment mismatch | *0d3f06fd65ksmbd: Fix spelling mistake "excceed" -> "exceeded" | *1f1aca1d50ksmbd: update Kconfig to note Kerberos support and fix indentation | *a35ebf6589ksmbd: Remove duplicated codes | *b15734ec29ksmbd: fix typo, syncronous->synchronous | *1f485b54d0ksmbd: Implements sess->rpc_handle_list as xarray | *b1caecbf34ksmbd: Implements sess->ksmbd_chann_list as xarray | *d7f088dc27ksmbd: send proper error response in smb2_tree_connect() | *bcab5c8105ksmbd: Convert to use sysfs_emit()/sysfs_emit_at() APIs | *46c517bc0aksmbd: Fix resource leak in smb2_lock() | *9ea6b43d8aksmbd: use F_SETLK when unlocking a file | *8263acd267ksmbd: set SMB2_SESSION_FLAG_ENCRYPT_DATA when enforcing data encryption for this share | *64b4d72c59ksmbd: replace one-element arrays with flexible-array members | *2bdd995f13ksmbd: validate share name from share config response | *ef97ccd0fcksmbd: call ib_drain_qp when disconnected | *b3e852bea8ksmbd: make utf-8 file name comparison work in __caseless_lookup() | *131e308593ksmbd: hide socket error message when ipv6 config is disable | *507cb106c3ksmbd: reduce server smbdirect max send/receive segment sizes | *fe4d09792bksmbd: decrease the number of SMB3 smbdirect server SGEs | *d5a3b1024aksmbd: set NTLMSSP_NEGOTIATE_SEAL flag to challenge blob | *4d796ff899ksmbd: fix encryption failure issue for session logoff response | *e925de7defksmbd: fill sids in SMB_FIND_FILE_POSIX_INFO response | *95b72edca5ksmbd: set file permission mode to match Samba server posix extension behavior | *813ef06ea2ksmbd: change security id to the one samba used for posix extension | *62e6846ee3ksmbd: casefold utf-8 share names and fix ascii lowercase conversion | *43e2963be1ksmbd: remove generic_fillattr use in smb2_open() | *aa77fc8182ksmbd: constify struct path | *b79a9f991eksmbd: don't open-code %pD | *d6686d5791ksmbd: don't open-code file_path() | *a7ddc4951fksmbd: remove unnecessary generic_fillattr in smb2_open | *ebb8c61657ksmbd: request update to stale share config | *c7aff8b8ffksmbd: use wait_event instead of schedule_timeout() | *1f82ecbc7fksmbd: remove unused ksmbd_share_configs_cleanup function | *8d0f823193ksmbd: remove duplicate flag set in smb2_write | *d4b374ff2aksmbd: smbd: Remove useless license text when SPDX-License-Identifier is already used | *ff403dbe43ksmbd: smbd: relax the count of sges required | *9d609b52f9ksmbd: smbd: fix connection dropped issue | *32af379e13ksmbd: Fix some kernel-doc comments | *81602ee1c4ksmbd: fix wrong smbd max read/write size check | *918a690d8aksmbd: smbd: handle multiple Buffer descriptors | *673c186f81ksmbd: smbd: change the return value of get_sg_list | *30bd0df6e6ksmbd: smbd: simplify tracking pending packets | *f17ed7b338ksmbd: smbd: introduce read/write credits for RDMA read/write | *982fcdec10ksmbd: smbd: change prototypes of RDMA read/write related functions | *6bb4399303ksmbd: validate length in smb2_write() | *8e32e15840ksmbd: remove filename in ksmbd_file | *e9a3251246smb3: fix ksmbd bigendian bug in oplock break, and move its struct to smbfs_common | *dc232946d1ksmbd: replace usage of found with dedicated list iterator variable | *a5213868c6ksmbd: Remove a redundant zeroing of memory | *7ee6f9ba97ksmbd: shorten experimental warning on loading the module | *a5a8c9133dksmbd: store fids as opaque u64 integers | *170598b6f3ksmbd: use netif_is_bridge_port | *c5049d2d73ksmbd: add support for key exchange | *09b4c60383ksmbd: smbd: validate buffer descriptor structures | *858b964451ksmbd: smbd: fix missing client's memory region invalidation | *51d0b879d6ksmbd: add smb-direct shutdown | *d15077ad35ksmbd: smbd: change the default maximum read/write, receive size | *ba7c3ff905ksmbd: smbd: create MR pool | *97b3a08892ksmbd: smbd: call rdma_accept() under CM handler | *8a49ab3e59ksmbd: set 445 port to smbdirect port by default | *178ecc3257ksmbd: register ksmbd ib client with ib_register_client() | *91d7307569ksmbd: Fix smb2_get_name() kernel-doc comment | *dd56eb361fksmbd: Delete an invalid argument description in smb2_populate_readdir_entry() | *36167446ceksmbd: Fix smb2_set_info_file() kernel-doc comment | *2fa426c9d7ksmbd: Fix buffer_check_err() kernel-doc comment | *e5b04973e7ksmbd: set both ipv4 and ipv6 in FSCTL_QUERY_NETWORK_INTERFACE_INFO | *a63256708aksmbd: Remove unused fields from ksmbd_file struct definition | *de203cdf1eksmbd: Remove unused parameter from smb2_get_name() | *82ae5fe3e6ksmbd: use oid registry functions to decode OIDs | *7833bd31bcksmbd: change LeaseKey data type to u8 array | *199b8b5cebksmbd: remove smb2_buf_length in smb2_transform_hdr | *e0c5842057ksmbd: remove smb2_buf_length in smb2_hdr | *6cd90c01b0ksmbd: remove md4 leftovers | *84af59bcabksmbd: Remove redundant 'flush_workqueue()' calls | *a33bb607a1ksmdb: use cmd helper variable in smb2_get_ksmbd_tcon() | *5fed9cbbafksmbd: use ksmbd_req_buf_next() in ksmbd_verify_smb_message() *2773ab8870Reapply "kasan: print the original fault addr when access invalid shadow" Change-Id: I54bd429db3190962e1a0b26565054a0c428185c4 Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
@@ -14,9 +14,11 @@ allOf:
|
||||
|
||||
properties:
|
||||
compatible:
|
||||
enum:
|
||||
- fsl,imx23-ocotp
|
||||
- fsl,imx28-ocotp
|
||||
items:
|
||||
- enum:
|
||||
- fsl,imx23-ocotp
|
||||
- fsl,imx28-ocotp
|
||||
- const: fsl,ocotp
|
||||
|
||||
"#address-cells":
|
||||
const: 1
|
||||
@@ -40,7 +42,7 @@ additionalProperties: false
|
||||
examples:
|
||||
- |
|
||||
ocotp: efuse@8002c000 {
|
||||
compatible = "fsl,imx28-ocotp";
|
||||
compatible = "fsl,imx28-ocotp", "fsl,ocotp";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
reg = <0x8002c000 0x2000>;
|
||||
|
||||
2
Makefile
2
Makefile
@@ -1,7 +1,7 @@
|
||||
# SPDX-License-Identifier: GPL-2.0
|
||||
VERSION = 5
|
||||
PATCHLEVEL = 15
|
||||
SUBLEVEL = 144
|
||||
SUBLEVEL = 148
|
||||
EXTRAVERSION =
|
||||
NAME = Trick or Treat
|
||||
|
||||
|
||||
@@ -61,7 +61,7 @@ struct rt_sigframe {
|
||||
unsigned int sigret_magic;
|
||||
};
|
||||
|
||||
static int save_arcv2_regs(struct sigcontext *mctx, struct pt_regs *regs)
|
||||
static int save_arcv2_regs(struct sigcontext __user *mctx, struct pt_regs *regs)
|
||||
{
|
||||
int err = 0;
|
||||
#ifndef CONFIG_ISA_ARCOMPACT
|
||||
@@ -74,12 +74,12 @@ static int save_arcv2_regs(struct sigcontext *mctx, struct pt_regs *regs)
|
||||
#else
|
||||
v2abi.r58 = v2abi.r59 = 0;
|
||||
#endif
|
||||
err = __copy_to_user(&mctx->v2abi, &v2abi, sizeof(v2abi));
|
||||
err = __copy_to_user(&mctx->v2abi, (void const *)&v2abi, sizeof(v2abi));
|
||||
#endif
|
||||
return err;
|
||||
}
|
||||
|
||||
static int restore_arcv2_regs(struct sigcontext *mctx, struct pt_regs *regs)
|
||||
static int restore_arcv2_regs(struct sigcontext __user *mctx, struct pt_regs *regs)
|
||||
{
|
||||
int err = 0;
|
||||
#ifndef CONFIG_ISA_ARCOMPACT
|
||||
|
||||
@@ -349,6 +349,7 @@
|
||||
<SYSC_IDLE_NO>,
|
||||
<SYSC_IDLE_SMART>,
|
||||
<SYSC_IDLE_SMART_WKUP>;
|
||||
ti,sysc-delay-us = <2>;
|
||||
clocks = <&l3s_clkctrl AM3_L3S_USB_OTG_HS_CLKCTRL 0>;
|
||||
clock-names = "fck";
|
||||
#address-cells = <1>;
|
||||
|
||||
@@ -144,7 +144,7 @@
|
||||
|
||||
l3-noc@44000000 {
|
||||
compatible = "ti,dra7-l3-noc";
|
||||
reg = <0x44000000 0x1000>,
|
||||
reg = <0x44000000 0x1000000>,
|
||||
<0x45000000 0x1000>;
|
||||
interrupts-extended = <&crossbar_mpu GIC_SPI 4 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<&wakeupgen GIC_SPI 10 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
||||
@@ -760,7 +760,7 @@
|
||||
|
||||
xoadc: xoadc@197 {
|
||||
compatible = "qcom,pm8921-adc";
|
||||
reg = <197>;
|
||||
reg = <0x197>;
|
||||
interrupts-extended = <&pmicintc 78 IRQ_TYPE_EDGE_RISING>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <0>;
|
||||
|
||||
@@ -457,7 +457,7 @@
|
||||
reg = <0x0c264000 0x1000>;
|
||||
};
|
||||
|
||||
spmi_bus: qcom,spmi@c440000 {
|
||||
spmi_bus: spmi@c440000 {
|
||||
compatible = "qcom,spmi-pmic-arb";
|
||||
reg = <0x0c440000 0x0000d00>,
|
||||
<0x0c600000 0x2000000>,
|
||||
|
||||
@@ -3,12 +3,14 @@
|
||||
menuconfig ARCH_DAVINCI
|
||||
bool "TI DaVinci"
|
||||
depends on ARCH_MULTI_V5
|
||||
select CPU_ARM926T
|
||||
select DAVINCI_TIMER
|
||||
select ZONE_DMA
|
||||
select PM_GENERIC_DOMAINS if PM
|
||||
select PM_GENERIC_DOMAINS_OF if PM && OF
|
||||
select REGMAP_MMIO
|
||||
select RESET_CONTROLLER
|
||||
select PINCTRL
|
||||
select PINCTRL_SINGLE
|
||||
|
||||
if ARCH_DAVINCI
|
||||
|
||||
@@ -793,11 +793,16 @@ void __init omap_soc_device_init(void)
|
||||
|
||||
soc_dev_attr->machine = soc_name;
|
||||
soc_dev_attr->family = omap_get_family();
|
||||
if (!soc_dev_attr->family) {
|
||||
kfree(soc_dev_attr);
|
||||
return;
|
||||
}
|
||||
soc_dev_attr->revision = soc_rev;
|
||||
soc_dev_attr->custom_attr_group = omap_soc_groups[0];
|
||||
|
||||
soc_dev = soc_device_register(soc_dev_attr);
|
||||
if (IS_ERR(soc_dev)) {
|
||||
kfree(soc_dev_attr->family);
|
||||
kfree(soc_dev_attr);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -804,16 +804,16 @@ static int __init sunxi_mc_smp_init(void)
|
||||
for (i = 0; i < ARRAY_SIZE(sunxi_mc_smp_data); i++) {
|
||||
ret = of_property_match_string(node, "enable-method",
|
||||
sunxi_mc_smp_data[i].enable_method);
|
||||
if (!ret)
|
||||
if (ret >= 0)
|
||||
break;
|
||||
}
|
||||
|
||||
is_a83t = sunxi_mc_smp_data[i].is_a83t;
|
||||
|
||||
of_node_put(node);
|
||||
if (ret)
|
||||
if (ret < 0)
|
||||
return -ENODEV;
|
||||
|
||||
is_a83t = sunxi_mc_smp_data[i].is_a83t;
|
||||
|
||||
if (!sunxi_mc_smp_cpu_table_init())
|
||||
return -EINVAL;
|
||||
|
||||
|
||||
@@ -130,7 +130,7 @@
|
||||
compatible = "microchip,mcp7940x";
|
||||
reg = <0x6f>;
|
||||
interrupt-parent = <&gpiosb>;
|
||||
interrupts = <5 0>; /* GPIO2_5 */
|
||||
interrupts = <5 IRQ_TYPE_EDGE_FALLING>; /* GPIO2_5 */
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
@@ -60,8 +60,8 @@
|
||||
user4 {
|
||||
label = "green:user4";
|
||||
gpios = <&pm8150_gpios 10 GPIO_ACTIVE_HIGH>;
|
||||
linux,default-trigger = "panic-indicator";
|
||||
default-state = "off";
|
||||
panic-indicator;
|
||||
};
|
||||
|
||||
wlan {
|
||||
|
||||
@@ -3366,7 +3366,7 @@
|
||||
compatible = "qcom,apss-wdt-sc7180", "qcom,kpss-wdt";
|
||||
reg = <0 0x17c10000 0 0x1000>;
|
||||
clocks = <&sleep_clk>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
|
||||
timer@17c20000{
|
||||
|
||||
@@ -485,6 +485,7 @@
|
||||
|
||||
bus-width = <8>;
|
||||
supports-cqe;
|
||||
dma-coherent;
|
||||
|
||||
qcom,dll-config = <0x0007642c>;
|
||||
qcom,ddr-config = <0x80040868>;
|
||||
@@ -1174,6 +1175,7 @@
|
||||
operating-points-v2 = <&sdhc2_opp_table>;
|
||||
|
||||
bus-width = <4>;
|
||||
dma-coherent;
|
||||
|
||||
qcom,dll-config = <0x0007642c>;
|
||||
|
||||
@@ -1290,8 +1292,8 @@
|
||||
assigned-clock-rates = <19200000>, <200000000>;
|
||||
|
||||
interrupts-extended = <&intc GIC_SPI 240 IRQ_TYPE_LEVEL_HIGH>,
|
||||
<&pdc 13 IRQ_TYPE_EDGE_RISING>,
|
||||
<&pdc 12 IRQ_TYPE_EDGE_RISING>;
|
||||
<&pdc 12 IRQ_TYPE_EDGE_BOTH>,
|
||||
<&pdc 13 IRQ_TYPE_EDGE_BOTH>;
|
||||
interrupt-names = "hs_phy_irq",
|
||||
"dm_hs_phy_irq", "dp_hs_phy_irq";
|
||||
|
||||
@@ -1711,7 +1713,7 @@
|
||||
compatible = "qcom,apss-wdt-sc7280", "qcom,kpss-wdt";
|
||||
reg = <0 0x17c10000 0 0x1000>;
|
||||
clocks = <&sleep_clk>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
|
||||
timer@17c20000 {
|
||||
|
||||
@@ -57,8 +57,8 @@
|
||||
user4 {
|
||||
label = "green:user4";
|
||||
gpios = <&pm8998_gpio 13 GPIO_ACTIVE_HIGH>;
|
||||
linux,default-trigger = "panic-indicator";
|
||||
default-state = "off";
|
||||
panic-indicator;
|
||||
};
|
||||
|
||||
wlan {
|
||||
|
||||
@@ -4725,7 +4725,7 @@
|
||||
compatible = "qcom,apss-wdt-sdm845", "qcom,kpss-wdt";
|
||||
reg = <0 0x17980000 0 0x1000>;
|
||||
clocks = <&sleep_clk>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
|
||||
apss_shared: mailbox@17990000 {
|
||||
|
||||
@@ -126,8 +126,6 @@
|
||||
vdda_sp_sensor:
|
||||
vdda_ufs_2ln_core_1:
|
||||
vdda_ufs_2ln_core_2:
|
||||
vdda_usb_ss_dp_core_1:
|
||||
vdda_usb_ss_dp_core_2:
|
||||
vdda_qlink_lv:
|
||||
vdda_qlink_lv_ck:
|
||||
vreg_l5a_0p875: ldo5 {
|
||||
@@ -209,6 +207,12 @@
|
||||
regulator-max-microvolt = <3008000>;
|
||||
regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
|
||||
};
|
||||
|
||||
vreg_l18a_0p8: ldo18 {
|
||||
regulator-min-microvolt = <880000>;
|
||||
regulator-max-microvolt = <880000>;
|
||||
regulator-initial-mode = <RPMH_REGULATOR_MODE_HPM>;
|
||||
};
|
||||
};
|
||||
|
||||
pm8150l-rpmh-regulators {
|
||||
@@ -441,13 +445,13 @@
|
||||
&usb_1_qmpphy {
|
||||
status = "okay";
|
||||
vdda-phy-supply = <&vreg_l3c_1p2>;
|
||||
vdda-pll-supply = <&vdda_usb_ss_dp_core_1>;
|
||||
vdda-pll-supply = <&vreg_l18a_0p8>;
|
||||
};
|
||||
|
||||
&usb_2_qmpphy {
|
||||
status = "okay";
|
||||
vdda-phy-supply = <&vreg_l3c_1p2>;
|
||||
vdda-pll-supply = <&vdda_usb_ss_dp_core_1>;
|
||||
vdda-pll-supply = <&vreg_l5a_0p875>;
|
||||
};
|
||||
|
||||
&usb_1 {
|
||||
|
||||
@@ -3359,7 +3359,7 @@
|
||||
compatible = "qcom,apss-wdt-sm8150", "qcom,kpss-wdt";
|
||||
reg = <0 0x17c10000 0 0x1000>;
|
||||
clocks = <&sleep_clk>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
|
||||
timer@17c20000 {
|
||||
|
||||
@@ -3947,7 +3947,7 @@
|
||||
compatible = "qcom,apss-wdt-sm8250", "qcom,kpss-wdt";
|
||||
reg = <0 0x17c10000 0 0x1000>;
|
||||
clocks = <&sleep_clk>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_LEVEL_HIGH>;
|
||||
interrupts = <GIC_SPI 0 IRQ_TYPE_EDGE_RISING>;
|
||||
};
|
||||
|
||||
timer@17c20000 {
|
||||
|
||||
@@ -855,7 +855,7 @@
|
||||
assigned-clocks = <&k3_clks 67 2>;
|
||||
assigned-clock-parents = <&k3_clks 67 5>;
|
||||
|
||||
interrupts = <GIC_SPI 166 IRQ_TYPE_EDGE_RISING>;
|
||||
interrupts = <GIC_SPI 166 IRQ_TYPE_LEVEL_HIGH>;
|
||||
|
||||
dma-coherent;
|
||||
|
||||
|
||||
@@ -497,7 +497,7 @@ void kvm_arch_vcpu_destroy(struct kvm_vcpu *vcpu)
|
||||
|
||||
kvm_timer_vcpu_terminate(vcpu);
|
||||
kvm_pmu_vcpu_destroy(vcpu);
|
||||
|
||||
kvm_vgic_vcpu_destroy(vcpu);
|
||||
kvm_arm_vcpu_destroy(vcpu);
|
||||
}
|
||||
|
||||
|
||||
@@ -379,7 +379,10 @@ void kvm_vgic_vcpu_destroy(struct kvm_vcpu *vcpu)
|
||||
vgic_flush_pending_lpis(vcpu);
|
||||
|
||||
INIT_LIST_HEAD(&vgic_cpu->ap_list_head);
|
||||
vgic_cpu->rd_iodev.base_addr = VGIC_ADDR_UNDEF;
|
||||
if (vcpu->kvm->arch.vgic.vgic_model == KVM_DEV_TYPE_ARM_VGIC_V3) {
|
||||
vgic_unregister_redist_iodev(vcpu);
|
||||
vgic_cpu->rd_iodev.base_addr = VGIC_ADDR_UNDEF;
|
||||
}
|
||||
}
|
||||
|
||||
static void __kvm_vgic_destroy(struct kvm *kvm)
|
||||
|
||||
@@ -584,7 +584,11 @@ static struct vgic_irq *vgic_its_check_cache(struct kvm *kvm, phys_addr_t db,
|
||||
unsigned long flags;
|
||||
|
||||
raw_spin_lock_irqsave(&dist->lpi_list_lock, flags);
|
||||
|
||||
irq = __vgic_its_check_cache(dist, db, devid, eventid);
|
||||
if (irq)
|
||||
vgic_get_irq_kref(irq);
|
||||
|
||||
raw_spin_unlock_irqrestore(&dist->lpi_list_lock, flags);
|
||||
|
||||
return irq;
|
||||
@@ -763,6 +767,7 @@ int vgic_its_inject_cached_translation(struct kvm *kvm, struct kvm_msi *msi)
|
||||
raw_spin_lock_irqsave(&irq->irq_lock, flags);
|
||||
irq->pending_latch = true;
|
||||
vgic_queue_irq_unlock(kvm, irq, flags);
|
||||
vgic_put_irq(kvm, irq);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -365,19 +365,26 @@ static int vgic_v3_uaccess_write_pending(struct kvm_vcpu *vcpu,
|
||||
struct vgic_irq *irq = vgic_get_irq(vcpu->kvm, vcpu, intid + i);
|
||||
|
||||
raw_spin_lock_irqsave(&irq->irq_lock, flags);
|
||||
if (test_bit(i, &val)) {
|
||||
/*
|
||||
* pending_latch is set irrespective of irq type
|
||||
* (level or edge) to avoid dependency that VM should
|
||||
* restore irq config before pending info.
|
||||
*/
|
||||
irq->pending_latch = true;
|
||||
vgic_queue_irq_unlock(vcpu->kvm, irq, flags);
|
||||
} else {
|
||||
|
||||
/*
|
||||
* pending_latch is set irrespective of irq type
|
||||
* (level or edge) to avoid dependency that VM should
|
||||
* restore irq config before pending info.
|
||||
*/
|
||||
irq->pending_latch = test_bit(i, &val);
|
||||
|
||||
if (irq->hw && vgic_irq_is_sgi(irq->intid)) {
|
||||
irq_set_irqchip_state(irq->host_irq,
|
||||
IRQCHIP_STATE_PENDING,
|
||||
irq->pending_latch);
|
||||
irq->pending_latch = false;
|
||||
raw_spin_unlock_irqrestore(&irq->irq_lock, flags);
|
||||
}
|
||||
|
||||
if (irq->pending_latch)
|
||||
vgic_queue_irq_unlock(vcpu->kvm, irq, flags);
|
||||
else
|
||||
raw_spin_unlock_irqrestore(&irq->irq_lock, flags);
|
||||
|
||||
vgic_put_irq(vcpu->kvm, irq);
|
||||
}
|
||||
|
||||
@@ -820,7 +827,7 @@ out_unlock:
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void vgic_unregister_redist_iodev(struct kvm_vcpu *vcpu)
|
||||
void vgic_unregister_redist_iodev(struct kvm_vcpu *vcpu)
|
||||
{
|
||||
struct vgic_io_device *rd_dev = &vcpu->arch.vgic_cpu.rd_iodev;
|
||||
|
||||
|
||||
@@ -239,6 +239,7 @@ int vgic_v3_lpi_sync_pending_status(struct kvm *kvm, struct vgic_irq *irq);
|
||||
int vgic_v3_save_pending_tables(struct kvm *kvm);
|
||||
int vgic_v3_set_redist_base(struct kvm *kvm, u32 index, u64 addr, u32 count);
|
||||
int vgic_register_redist_iodev(struct kvm_vcpu *vcpu);
|
||||
void vgic_unregister_redist_iodev(struct kvm_vcpu *vcpu);
|
||||
bool vgic_v3_check_base(struct kvm *kvm);
|
||||
|
||||
void vgic_v3_load(struct kvm_vcpu *vcpu);
|
||||
|
||||
@@ -847,7 +847,7 @@ int __init db1200_dev_setup(void)
|
||||
i2c_register_board_info(0, db1200_i2c_devs,
|
||||
ARRAY_SIZE(db1200_i2c_devs));
|
||||
spi_register_board_info(db1200_spi_devs,
|
||||
ARRAY_SIZE(db1200_i2c_devs));
|
||||
ARRAY_SIZE(db1200_spi_devs));
|
||||
|
||||
/* SWITCHES: S6.8 I2C/SPI selector (OFF=I2C ON=SPI)
|
||||
* S6.7 AC97/I2S selector (OFF=AC97 ON=I2S)
|
||||
|
||||
@@ -588,7 +588,7 @@ int __init db1550_dev_setup(void)
|
||||
i2c_register_board_info(0, db1550_i2c_devs,
|
||||
ARRAY_SIZE(db1550_i2c_devs));
|
||||
spi_register_board_info(db1550_spi_devs,
|
||||
ARRAY_SIZE(db1550_i2c_devs));
|
||||
ARRAY_SIZE(db1550_spi_devs));
|
||||
|
||||
c = clk_get(NULL, "psc0_intclk");
|
||||
if (!IS_ERR(c)) {
|
||||
|
||||
@@ -118,8 +118,7 @@
|
||||
compatible = "pci0014,7a03.0",
|
||||
"pci0014,7a03",
|
||||
"pciclass0c0320",
|
||||
"pciclass0c03",
|
||||
"loongson, pci-gmac";
|
||||
"pciclass0c03";
|
||||
|
||||
reg = <0x1800 0x0 0x0 0x0 0x0>;
|
||||
interrupts = <12 IRQ_TYPE_LEVEL_LOW>,
|
||||
|
||||
@@ -186,8 +186,7 @@
|
||||
compatible = "pci0014,7a03.0",
|
||||
"pci0014,7a03",
|
||||
"pciclass020000",
|
||||
"pciclass0200",
|
||||
"loongson, pci-gmac";
|
||||
"pciclass0200";
|
||||
|
||||
reg = <0x1800 0x0 0x0 0x0 0x0>;
|
||||
interrupts = <12 IRQ_TYPE_LEVEL_HIGH>,
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
#include <linux/io.h>
|
||||
#include <linux/memblock.h>
|
||||
|
||||
#define dmi_early_remap(x, l) ioremap_cache(x, l)
|
||||
#define dmi_early_remap(x, l) ioremap(x, l)
|
||||
#define dmi_early_unmap(x, l) iounmap(x)
|
||||
#define dmi_remap(x, l) ioremap_cache(x, l)
|
||||
#define dmi_unmap(x) iounmap(x)
|
||||
|
||||
@@ -324,11 +324,11 @@ static void __init bootmem_init(void)
|
||||
panic("Incorrect memory mapping !!!");
|
||||
|
||||
if (max_pfn > PFN_DOWN(HIGHMEM_START)) {
|
||||
max_low_pfn = PFN_DOWN(HIGHMEM_START);
|
||||
#ifdef CONFIG_HIGHMEM
|
||||
highstart_pfn = PFN_DOWN(HIGHMEM_START);
|
||||
highstart_pfn = max_low_pfn;
|
||||
highend_pfn = max_pfn;
|
||||
#else
|
||||
max_low_pfn = PFN_DOWN(HIGHMEM_START);
|
||||
max_pfn = max_low_pfn;
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -44,18 +44,13 @@ machine-$(CONFIG_PPC64) += 64
|
||||
machine-$(CONFIG_CPU_LITTLE_ENDIAN) += le
|
||||
UTS_MACHINE := $(subst $(space),,$(machine-y))
|
||||
|
||||
# XXX This needs to be before we override LD below
|
||||
ifdef CONFIG_PPC32
|
||||
KBUILD_LDFLAGS_MODULE += arch/powerpc/lib/crtsavres.o
|
||||
else
|
||||
ifeq ($(call ld-ifversion, -ge, 22500, y),y)
|
||||
ifeq ($(CONFIG_PPC64)$(CONFIG_LD_IS_BFD),yy)
|
||||
# Have the linker provide sfpr if possible.
|
||||
# There is a corresponding test in arch/powerpc/lib/Makefile
|
||||
KBUILD_LDFLAGS_MODULE += --save-restore-funcs
|
||||
else
|
||||
KBUILD_LDFLAGS_MODULE += arch/powerpc/lib/crtsavres.o
|
||||
endif
|
||||
endif
|
||||
|
||||
ifdef CONFIG_CPU_LITTLE_ENDIAN
|
||||
KBUILD_CFLAGS += -mlittle-endian
|
||||
@@ -434,16 +429,7 @@ endif # CONFIG_PPC32
|
||||
endif # CONFIG_SMP
|
||||
|
||||
PHONY += checkbin
|
||||
# Check toolchain versions:
|
||||
# - gcc-4.6 is the minimum kernel-wide version so nothing required.
|
||||
checkbin:
|
||||
@if test "x${CONFIG_CPU_LITTLE_ENDIAN}" = "xy" \
|
||||
&& $(LD) --version | head -1 | grep ' 2\.24$$' >/dev/null ; then \
|
||||
echo -n '*** binutils 2.24 miscompiles weak symbols ' ; \
|
||||
echo 'in some circumstances.' ; \
|
||||
echo -n '*** Please use a different binutils version.' ; \
|
||||
false ; \
|
||||
fi
|
||||
@if test "x${CONFIG_FTRACE_MCOUNT_USE_RECORDMCOUNT}" = "xy" -a \
|
||||
"x${CONFIG_LD_IS_BFD}" = "xy" -a \
|
||||
"${CONFIG_LD_VERSION}" = "23700" ; then \
|
||||
|
||||
@@ -28,7 +28,7 @@ p_etext: .8byte _etext
|
||||
p_bss_start: .8byte __bss_start
|
||||
p_end: .8byte _end
|
||||
|
||||
p_toc: .8byte __toc_start + 0x8000 - p_base
|
||||
p_toc: .8byte .TOC. - p_base
|
||||
p_dyn: .8byte __dynamic_start - p_base
|
||||
p_rela: .8byte __rela_dyn_start - p_base
|
||||
p_prom: .8byte 0
|
||||
|
||||
@@ -36,12 +36,9 @@ SECTIONS
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PPC64_BOOT_WRAPPER
|
||||
. = ALIGN(256);
|
||||
.got :
|
||||
.got : ALIGN(256)
|
||||
{
|
||||
__toc_start = .;
|
||||
*(.got)
|
||||
*(.toc)
|
||||
*(.got .toc)
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -26,16 +26,16 @@ extern char start_virt_trampolines[];
|
||||
extern char end_virt_trampolines[];
|
||||
#endif
|
||||
|
||||
/*
|
||||
* This assumes the kernel is never compiled -mcmodel=small or
|
||||
* the total .toc is always less than 64k.
|
||||
*/
|
||||
static inline unsigned long kernel_toc_addr(void)
|
||||
{
|
||||
/* Defined by the linker, see vmlinux.lds.S */
|
||||
extern unsigned long __toc_start;
|
||||
unsigned long toc_ptr;
|
||||
|
||||
/*
|
||||
* The TOC register (r2) points 32kB into the TOC, so that 64kB of
|
||||
* the TOC can be addressed using a single machine instruction.
|
||||
*/
|
||||
return (unsigned long)(&__toc_start) + 0x8000UL;
|
||||
asm volatile("mr %0, 2" : "=r" (toc_ptr));
|
||||
return toc_ptr;
|
||||
}
|
||||
|
||||
static inline int overlaps_interrupt_vector_text(unsigned long start,
|
||||
|
||||
@@ -904,7 +904,7 @@ _GLOBAL(relative_toc)
|
||||
blr
|
||||
|
||||
.balign 8
|
||||
p_toc: .8byte __toc_start + 0x8000 - 0b
|
||||
p_toc: .8byte .TOC. - 0b
|
||||
|
||||
/*
|
||||
* This is where the main kernel code starts.
|
||||
|
||||
@@ -148,6 +148,12 @@ SECTIONS
|
||||
SOFT_MASK_TABLE(8)
|
||||
RESTART_TABLE(8)
|
||||
|
||||
.opd : AT(ADDR(.opd) - LOAD_OFFSET) {
|
||||
__start_opd = .;
|
||||
KEEP(*(.opd))
|
||||
__end_opd = .;
|
||||
}
|
||||
|
||||
. = ALIGN(8);
|
||||
__stf_entry_barrier_fixup : AT(ADDR(__stf_entry_barrier_fixup) - LOAD_OFFSET) {
|
||||
__start___stf_entry_barrier_fixup = .;
|
||||
@@ -346,21 +352,13 @@ SECTIONS
|
||||
*(.branch_lt)
|
||||
}
|
||||
|
||||
.opd : AT(ADDR(.opd) - LOAD_OFFSET) {
|
||||
__start_opd = .;
|
||||
KEEP(*(.opd))
|
||||
__end_opd = .;
|
||||
}
|
||||
|
||||
. = ALIGN(256);
|
||||
.got : AT(ADDR(.got) - LOAD_OFFSET) {
|
||||
__toc_start = .;
|
||||
.got : AT(ADDR(.got) - LOAD_OFFSET) ALIGN(256) {
|
||||
*(.got)
|
||||
#ifndef CONFIG_RELOCATABLE
|
||||
__prom_init_toc_start = .;
|
||||
arch/powerpc/kernel/prom_init.o*(.toc .got)
|
||||
arch/powerpc/kernel/prom_init.o*(.toc)
|
||||
__prom_init_toc_end = .;
|
||||
#endif
|
||||
*(.got)
|
||||
*(.toc)
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -37,8 +37,8 @@ obj-$(CONFIG_FUNCTION_ERROR_INJECTION) += error-inject.o
|
||||
# 64-bit linker creates .sfpr on demand for final link (vmlinux),
|
||||
# so it is only needed for modules, and only for older linkers which
|
||||
# do not support --save-restore-funcs
|
||||
ifeq ($(call ld-ifversion, -lt, 22500, y),y)
|
||||
extra-$(CONFIG_PPC64) += crtsavres.o
|
||||
ifndef CONFIG_LD_IS_BFD
|
||||
always-$(CONFIG_PPC64) += crtsavres.o
|
||||
endif
|
||||
|
||||
obj-$(CONFIG_PPC_BOOK3S_64) += copyuser_power7.o copypage_power7.o \
|
||||
|
||||
@@ -292,6 +292,8 @@ static int update_events_in_group(struct device_node *node, struct imc_pmu *pmu)
|
||||
attr_group->attrs = attrs;
|
||||
do {
|
||||
ev_val_str = kasprintf(GFP_KERNEL, "event=0x%x", pmu->events[i].value);
|
||||
if (!ev_val_str)
|
||||
continue;
|
||||
dev_str = device_str_attr_create(pmu->events[i].name, ev_val_str);
|
||||
if (!dev_str)
|
||||
continue;
|
||||
@@ -299,6 +301,8 @@ static int update_events_in_group(struct device_node *node, struct imc_pmu *pmu)
|
||||
attrs[j++] = dev_str;
|
||||
if (pmu->events[i].scale) {
|
||||
ev_scale_str = kasprintf(GFP_KERNEL, "%s.scale", pmu->events[i].name);
|
||||
if (!ev_scale_str)
|
||||
continue;
|
||||
dev_str = device_str_attr_create(ev_scale_str, pmu->events[i].scale);
|
||||
if (!dev_str)
|
||||
continue;
|
||||
@@ -308,6 +312,8 @@ static int update_events_in_group(struct device_node *node, struct imc_pmu *pmu)
|
||||
|
||||
if (pmu->events[i].unit) {
|
||||
ev_unit_str = kasprintf(GFP_KERNEL, "%s.unit", pmu->events[i].name);
|
||||
if (!ev_unit_str)
|
||||
continue;
|
||||
dev_str = device_str_attr_create(ev_unit_str, pmu->events[i].unit);
|
||||
if (!dev_str)
|
||||
continue;
|
||||
|
||||
@@ -177,6 +177,7 @@ config ISS4xx
|
||||
config CURRITUCK
|
||||
bool "IBM Currituck (476fpe) Support"
|
||||
depends on PPC_47x
|
||||
select I2C
|
||||
select SWIOTLB
|
||||
select 476FPE
|
||||
select FORCE_PCI
|
||||
|
||||
@@ -275,6 +275,8 @@ int __init opal_event_init(void)
|
||||
else
|
||||
name = kasprintf(GFP_KERNEL, "opal");
|
||||
|
||||
if (!name)
|
||||
continue;
|
||||
/* Install interrupt handler */
|
||||
rc = request_irq(r->start, opal_interrupt, r->flags & IRQD_TRIGGER_MASK,
|
||||
name, NULL);
|
||||
|
||||
@@ -196,6 +196,12 @@ void __init opal_powercap_init(void)
|
||||
|
||||
j = 0;
|
||||
pcaps[i].pg.name = kasprintf(GFP_KERNEL, "%pOFn", node);
|
||||
if (!pcaps[i].pg.name) {
|
||||
kfree(pcaps[i].pattrs);
|
||||
kfree(pcaps[i].pg.attrs);
|
||||
goto out_pcaps_pattrs;
|
||||
}
|
||||
|
||||
if (has_min) {
|
||||
powercap_add_attr(min, "powercap-min",
|
||||
&pcaps[i].pattrs[j]);
|
||||
|
||||
@@ -165,6 +165,11 @@ static int scom_debug_init_one(struct dentry *root, struct device_node *dn,
|
||||
ent->chip = chip;
|
||||
snprintf(ent->name, 16, "%08x", chip);
|
||||
ent->path.data = (void *)kasprintf(GFP_KERNEL, "%pOF", dn);
|
||||
if (!ent->path.data) {
|
||||
kfree(ent);
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
ent->path.size = strlen((char *)ent->path.data);
|
||||
|
||||
dir = debugfs_create_dir(ent->name, root);
|
||||
|
||||
@@ -501,14 +501,15 @@ static int dlpar_memory_remove_by_index(u32 drc_index)
|
||||
}
|
||||
}
|
||||
|
||||
if (!lmb_found)
|
||||
if (!lmb_found) {
|
||||
pr_debug("Failed to look up LMB for drc index %x\n", drc_index);
|
||||
rc = -EINVAL;
|
||||
|
||||
if (rc)
|
||||
} else if (rc) {
|
||||
pr_debug("Failed to hot-remove memory at %llx\n",
|
||||
lmb->base_addr);
|
||||
else
|
||||
} else {
|
||||
pr_debug("Memory at %llx was hot-removed\n", lmb->base_addr);
|
||||
}
|
||||
|
||||
return rc;
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ extern char _start_kernel[];
|
||||
extern char __init_data_begin[], __init_data_end[];
|
||||
extern char __init_text_begin[], __init_text_end[];
|
||||
extern char __alt_start[], __alt_end[];
|
||||
extern char __exittext_begin[], __exittext_end[];
|
||||
|
||||
static inline bool is_va_kernel_text(uintptr_t va)
|
||||
{
|
||||
|
||||
@@ -423,7 +423,8 @@ void *module_alloc(unsigned long size)
|
||||
{
|
||||
return __vmalloc_node_range(size, 1, MODULES_VADDR,
|
||||
MODULES_END, GFP_KERNEL,
|
||||
PAGE_KERNEL, 0, NUMA_NO_NODE,
|
||||
PAGE_KERNEL, VM_FLUSH_RESET_PERMS,
|
||||
NUMA_NO_NODE,
|
||||
__builtin_return_address(0));
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include <asm/fixmap.h>
|
||||
#include <asm/ftrace.h>
|
||||
#include <asm/patch.h>
|
||||
#include <asm/sections.h>
|
||||
|
||||
struct patch_insn {
|
||||
void *addr;
|
||||
@@ -23,6 +24,14 @@ struct patch_insn {
|
||||
int riscv_patch_in_stop_machine = false;
|
||||
|
||||
#ifdef CONFIG_MMU
|
||||
|
||||
static inline bool is_kernel_exittext(uintptr_t addr)
|
||||
{
|
||||
return system_state < SYSTEM_RUNNING &&
|
||||
addr >= (uintptr_t)__exittext_begin &&
|
||||
addr < (uintptr_t)__exittext_end;
|
||||
}
|
||||
|
||||
/*
|
||||
* The fix_to_virt(, idx) needs a const value (not a dynamic variable of
|
||||
* reg-a0) or BUILD_BUG_ON failed with "idx >= __end_of_fixed_addresses".
|
||||
@@ -33,7 +42,7 @@ static __always_inline void *patch_map(void *addr, const unsigned int fixmap)
|
||||
uintptr_t uintaddr = (uintptr_t) addr;
|
||||
struct page *page;
|
||||
|
||||
if (core_kernel_text(uintaddr))
|
||||
if (core_kernel_text(uintaddr) || is_kernel_exittext(uintaddr))
|
||||
page = phys_to_page(__pa_symbol(addr));
|
||||
else if (IS_ENABLED(CONFIG_STRICT_MODULE_RWX))
|
||||
page = vmalloc_to_page(addr);
|
||||
|
||||
@@ -29,10 +29,12 @@ SECTIONS
|
||||
HEAD_TEXT_SECTION
|
||||
INIT_TEXT_SECTION(PAGE_SIZE)
|
||||
/* we have to discard exit text and such at runtime, not link time */
|
||||
__exittext_begin = .;
|
||||
.exit.text :
|
||||
{
|
||||
EXIT_TEXT
|
||||
}
|
||||
__exittext_end = .;
|
||||
|
||||
.text : {
|
||||
_text = .;
|
||||
|
||||
@@ -73,10 +73,12 @@ SECTIONS
|
||||
__soc_builtin_dtb_table_end = .;
|
||||
}
|
||||
/* we have to discard exit text and such at runtime, not link time */
|
||||
__exittext_begin = .;
|
||||
.exit.text :
|
||||
{
|
||||
EXIT_TEXT
|
||||
}
|
||||
__exittext_end = .;
|
||||
|
||||
__init_text_end = .;
|
||||
. = ALIGN(SECTION_ALIGN);
|
||||
|
||||
@@ -78,7 +78,7 @@ static inline int test_fp_ctl(u32 fpc)
|
||||
#define KERNEL_VXR_HIGH (KERNEL_VXR_V16V23|KERNEL_VXR_V24V31)
|
||||
|
||||
#define KERNEL_VXR (KERNEL_VXR_LOW|KERNEL_VXR_HIGH)
|
||||
#define KERNEL_FPR (KERNEL_FPC|KERNEL_VXR_V0V7)
|
||||
#define KERNEL_FPR (KERNEL_FPC|KERNEL_VXR_LOW)
|
||||
|
||||
struct kernel_fpu;
|
||||
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
/* I/O size constraints */
|
||||
#define ZPCI_MAX_READ_SIZE 8
|
||||
#define ZPCI_MAX_WRITE_SIZE 128
|
||||
#define ZPCI_BOUNDARY_SIZE (1 << 12)
|
||||
#define ZPCI_BOUNDARY_MASK (ZPCI_BOUNDARY_SIZE - 1)
|
||||
|
||||
/* I/O Map */
|
||||
#define ZPCI_IOMAP_SHIFT 48
|
||||
@@ -125,16 +127,18 @@ out:
|
||||
int zpci_write_block(volatile void __iomem *dst, const void *src,
|
||||
unsigned long len);
|
||||
|
||||
static inline u8 zpci_get_max_write_size(u64 src, u64 dst, int len, int max)
|
||||
static inline int zpci_get_max_io_size(u64 src, u64 dst, int len, int max)
|
||||
{
|
||||
int count = len > max ? max : len, size = 1;
|
||||
int offset = dst & ZPCI_BOUNDARY_MASK;
|
||||
int size;
|
||||
|
||||
while (!(src & 0x1) && !(dst & 0x1) && ((size << 1) <= count)) {
|
||||
dst = dst >> 1;
|
||||
src = src >> 1;
|
||||
size = size << 1;
|
||||
}
|
||||
return size;
|
||||
size = min3(len, ZPCI_BOUNDARY_SIZE - offset, max);
|
||||
if (IS_ALIGNED(src, 8) && IS_ALIGNED(dst, 8) && IS_ALIGNED(size, 8))
|
||||
return size;
|
||||
|
||||
if (size >= 8)
|
||||
return 8;
|
||||
return rounddown_pow_of_two(size);
|
||||
}
|
||||
|
||||
static inline int zpci_memcpy_fromio(void *dst,
|
||||
@@ -144,9 +148,9 @@ static inline int zpci_memcpy_fromio(void *dst,
|
||||
int size, rc = 0;
|
||||
|
||||
while (n > 0) {
|
||||
size = zpci_get_max_write_size((u64 __force) src,
|
||||
(u64) dst, n,
|
||||
ZPCI_MAX_READ_SIZE);
|
||||
size = zpci_get_max_io_size((u64 __force) src,
|
||||
(u64) dst, n,
|
||||
ZPCI_MAX_READ_SIZE);
|
||||
rc = zpci_read_single(dst, src, size);
|
||||
if (rc)
|
||||
break;
|
||||
@@ -166,9 +170,9 @@ static inline int zpci_memcpy_toio(volatile void __iomem *dst,
|
||||
return -EINVAL;
|
||||
|
||||
while (n > 0) {
|
||||
size = zpci_get_max_write_size((u64 __force) dst,
|
||||
(u64) src, n,
|
||||
ZPCI_MAX_WRITE_SIZE);
|
||||
size = zpci_get_max_io_size((u64 __force) dst,
|
||||
(u64) src, n,
|
||||
ZPCI_MAX_WRITE_SIZE);
|
||||
if (size > 8) /* main path */
|
||||
rc = zpci_write_block(dst, src, size);
|
||||
else
|
||||
|
||||
@@ -96,9 +96,9 @@ static inline int __memcpy_toio_inuser(void __iomem *dst,
|
||||
return -EINVAL;
|
||||
|
||||
while (n > 0) {
|
||||
size = zpci_get_max_write_size((u64 __force) dst,
|
||||
(u64 __force) src, n,
|
||||
ZPCI_MAX_WRITE_SIZE);
|
||||
size = zpci_get_max_io_size((u64 __force) dst,
|
||||
(u64 __force) src, n,
|
||||
ZPCI_MAX_WRITE_SIZE);
|
||||
if (size > 8) /* main path */
|
||||
rc = __pcistb_mio_inuser(dst, src, size, &status);
|
||||
else
|
||||
@@ -241,9 +241,9 @@ static inline int __memcpy_fromio_inuser(void __user *dst,
|
||||
u8 status;
|
||||
|
||||
while (n > 0) {
|
||||
size = zpci_get_max_write_size((u64 __force) src,
|
||||
(u64 __force) dst, n,
|
||||
ZPCI_MAX_READ_SIZE);
|
||||
size = zpci_get_max_io_size((u64 __force) src,
|
||||
(u64 __force) dst, n,
|
||||
ZPCI_MAX_READ_SIZE);
|
||||
rc = __pcilg_mio_inuser(dst, src, size, &status);
|
||||
if (rc)
|
||||
break;
|
||||
|
||||
@@ -963,8 +963,8 @@ void __init_or_module text_poke_early(void *addr, const void *opcode,
|
||||
} else {
|
||||
local_irq_save(flags);
|
||||
memcpy(addr, opcode, len);
|
||||
local_irq_restore(flags);
|
||||
sync_core();
|
||||
local_irq_restore(flags);
|
||||
|
||||
/*
|
||||
* Could also do a CLFLUSH here to speed up CPU recovery; but
|
||||
|
||||
@@ -563,7 +563,8 @@ static void kprobe_emulate_call_indirect(struct kprobe *p, struct pt_regs *regs)
|
||||
{
|
||||
unsigned long offs = addrmode_regoffs[p->ainsn.indirect.reg];
|
||||
|
||||
int3_emulate_call(regs, regs_get_register(regs, offs));
|
||||
int3_emulate_push(regs, regs->ip - INT3_INSN_SIZE + p->ainsn.size);
|
||||
int3_emulate_jmp(regs, regs_get_register(regs, offs));
|
||||
}
|
||||
NOKPROBE_SYMBOL(kprobe_emulate_call_indirect);
|
||||
|
||||
|
||||
@@ -24,8 +24,8 @@
|
||||
|
||||
static int kvmclock __initdata = 1;
|
||||
static int kvmclock_vsyscall __initdata = 1;
|
||||
static int msr_kvm_system_time __ro_after_init = MSR_KVM_SYSTEM_TIME;
|
||||
static int msr_kvm_wall_clock __ro_after_init = MSR_KVM_WALL_CLOCK;
|
||||
static int msr_kvm_system_time __ro_after_init;
|
||||
static int msr_kvm_wall_clock __ro_after_init;
|
||||
static u64 kvm_sched_clock_offset __ro_after_init;
|
||||
|
||||
static int __init parse_no_kvmclock(char *arg)
|
||||
@@ -195,7 +195,8 @@ static void kvm_setup_secondary_clock(void)
|
||||
|
||||
void kvmclock_disable(void)
|
||||
{
|
||||
native_write_msr(msr_kvm_system_time, 0, 0);
|
||||
if (msr_kvm_system_time)
|
||||
native_write_msr(msr_kvm_system_time, 0, 0);
|
||||
}
|
||||
|
||||
static void __init kvmclock_init_mem(void)
|
||||
@@ -291,7 +292,10 @@ void __init kvmclock_init(void)
|
||||
if (kvm_para_has_feature(KVM_FEATURE_CLOCKSOURCE2)) {
|
||||
msr_kvm_system_time = MSR_KVM_SYSTEM_TIME_NEW;
|
||||
msr_kvm_wall_clock = MSR_KVM_WALL_CLOCK_NEW;
|
||||
} else if (!kvm_para_has_feature(KVM_FEATURE_CLOCKSOURCE)) {
|
||||
} else if (kvm_para_has_feature(KVM_FEATURE_CLOCKSOURCE)) {
|
||||
msr_kvm_system_time = MSR_KVM_SYSTEM_TIME;
|
||||
msr_kvm_wall_clock = MSR_KVM_WALL_CLOCK;
|
||||
} else {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
*/
|
||||
int num_digits(int val)
|
||||
{
|
||||
int m = 10;
|
||||
long long m = 10;
|
||||
int d = 1;
|
||||
|
||||
if (val < 0) {
|
||||
|
||||
@@ -1029,7 +1029,7 @@ void bio_release_pages(struct bio *bio, bool mark_dirty)
|
||||
return;
|
||||
|
||||
bio_for_each_segment_all(bvec, bio, iter_all) {
|
||||
if (mark_dirty && !PageCompound(bvec->bv_page))
|
||||
if (mark_dirty)
|
||||
set_page_dirty_lock(bvec->bv_page);
|
||||
put_page(bvec->bv_page);
|
||||
}
|
||||
@@ -1348,8 +1348,7 @@ void bio_set_pages_dirty(struct bio *bio)
|
||||
struct bvec_iter_all iter_all;
|
||||
|
||||
bio_for_each_segment_all(bvec, bio, iter_all) {
|
||||
if (!PageCompound(bvec->bv_page))
|
||||
set_page_dirty_lock(bvec->bv_page);
|
||||
set_page_dirty_lock(bvec->bv_page);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1397,7 +1396,7 @@ void bio_check_pages_dirty(struct bio *bio)
|
||||
struct bvec_iter_all iter_all;
|
||||
|
||||
bio_for_each_segment_all(bvec, bio, iter_all) {
|
||||
if (!PageDirty(bvec->bv_page) && !PageCompound(bvec->bv_page))
|
||||
if (!PageDirty(bvec->bv_page))
|
||||
goto defer;
|
||||
}
|
||||
|
||||
|
||||
@@ -202,7 +202,7 @@ void blk_queue_max_hw_sectors(struct request_queue *q, unsigned int max_hw_secto
|
||||
limits->max_hw_sectors = max_hw_sectors;
|
||||
|
||||
max_sectors = min_not_zero(max_hw_sectors, limits->max_dev_sectors);
|
||||
max_sectors = min_t(unsigned int, max_sectors, BLK_DEF_MAX_SECTORS);
|
||||
max_sectors = min(max_sectors, BLK_DEF_MAX_SECTORS);
|
||||
max_sectors = round_down(max_sectors,
|
||||
limits->logical_block_size >> SECTOR_SHIFT);
|
||||
limits->max_sectors = max_sectors;
|
||||
|
||||
21
block/fops.c
21
block/fops.c
@@ -599,22 +599,33 @@ static long blkdev_fallocate(struct file *file, int mode, loff_t start,
|
||||
|
||||
filemap_invalidate_lock(inode->i_mapping);
|
||||
|
||||
/* Invalidate the page cache, including dirty pages. */
|
||||
error = truncate_bdev_range(bdev, file->f_mode, start, end);
|
||||
if (error)
|
||||
goto fail;
|
||||
|
||||
/*
|
||||
* Invalidate the page cache, including dirty pages, for valid
|
||||
* de-allocate mode calls to fallocate().
|
||||
*/
|
||||
switch (mode) {
|
||||
case FALLOC_FL_ZERO_RANGE:
|
||||
case FALLOC_FL_ZERO_RANGE | FALLOC_FL_KEEP_SIZE:
|
||||
error = truncate_bdev_range(bdev, file->f_mode, start, end);
|
||||
if (error)
|
||||
goto fail;
|
||||
|
||||
error = blkdev_issue_zeroout(bdev, start >> 9, len >> 9,
|
||||
GFP_KERNEL, BLKDEV_ZERO_NOUNMAP);
|
||||
break;
|
||||
case FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE:
|
||||
error = truncate_bdev_range(bdev, file->f_mode, start, end);
|
||||
if (error)
|
||||
goto fail;
|
||||
|
||||
error = blkdev_issue_zeroout(bdev, start >> 9, len >> 9,
|
||||
GFP_KERNEL, BLKDEV_ZERO_NOFALLBACK);
|
||||
break;
|
||||
case FALLOC_FL_PUNCH_HOLE | FALLOC_FL_KEEP_SIZE | FALLOC_FL_NO_HIDE_STALE:
|
||||
error = truncate_bdev_range(bdev, file->f_mode, start, end);
|
||||
if (error)
|
||||
goto fail;
|
||||
|
||||
error = blkdev_issue_discard(bdev, start >> 9, len >> 9,
|
||||
GFP_KERNEL, 0);
|
||||
break;
|
||||
|
||||
@@ -421,7 +421,9 @@ int device_add_disk(struct device *parent, struct gendisk *disk,
|
||||
DISK_MAX_PARTS);
|
||||
disk->minors = DISK_MAX_PARTS;
|
||||
}
|
||||
if (disk->first_minor + disk->minors > MINORMASK + 1)
|
||||
if (disk->first_minor > MINORMASK ||
|
||||
disk->minors > MINORMASK + 1 ||
|
||||
disk->first_minor + disk->minors > MINORMASK + 1)
|
||||
return -EINVAL;
|
||||
} else {
|
||||
if (WARN_ON(disk->minors))
|
||||
@@ -538,6 +540,7 @@ out_del_integrity:
|
||||
out_del_block_link:
|
||||
if (!sysfs_deprecated)
|
||||
sysfs_remove_link(block_depr, dev_name(ddev));
|
||||
pm_runtime_set_memalloc_noio(ddev, false);
|
||||
out_device_del:
|
||||
device_del(ddev);
|
||||
out_free_ext_minor:
|
||||
|
||||
@@ -18,7 +18,7 @@ static int blkpg_do_ioctl(struct block_device *bdev,
|
||||
{
|
||||
struct gendisk *disk = bdev->bd_disk;
|
||||
struct blkpg_partition p;
|
||||
long long start, length;
|
||||
sector_t start, length;
|
||||
|
||||
if (disk->flags & GENHD_FL_NO_PART)
|
||||
return -EINVAL;
|
||||
@@ -35,14 +35,17 @@ static int blkpg_do_ioctl(struct block_device *bdev,
|
||||
if (op == BLKPG_DEL_PARTITION)
|
||||
return bdev_del_partition(disk, p.pno);
|
||||
|
||||
if (p.start < 0 || p.length <= 0 || p.start + p.length < 0)
|
||||
return -EINVAL;
|
||||
/* Check that the partition is aligned to the block size */
|
||||
if (!IS_ALIGNED(p.start | p.length, bdev_logical_block_size(bdev)))
|
||||
return -EINVAL;
|
||||
|
||||
start = p.start >> SECTOR_SHIFT;
|
||||
length = p.length >> SECTOR_SHIFT;
|
||||
|
||||
switch (op) {
|
||||
case BLKPG_ADD_PARTITION:
|
||||
/* check if partition is aligned to blocksize */
|
||||
if (p.start & (bdev_logical_block_size(bdev) - 1))
|
||||
return -EINVAL;
|
||||
return bdev_add_partition(disk, p.pno, start, length);
|
||||
case BLKPG_RESIZE_PARTITION:
|
||||
return bdev_resize_partition(disk, p.pno, start, length);
|
||||
|
||||
@@ -7,6 +7,8 @@ FRAGMENT_CONFIG=${KERNEL_DIR}/arch/arm64/configs/db845c_gki.fragment
|
||||
PRE_DEFCONFIG_CMDS="KCONFIG_CONFIG=${ROOT_DIR}/${KERNEL_DIR}/arch/arm64/configs/${DEFCONFIG} ${ROOT_DIR}/${KERNEL_DIR}/scripts/kconfig/merge_config.sh -m -r ${ROOT_DIR}/${KERNEL_DIR}/arch/arm64/configs/gki_defconfig ${ROOT_DIR}/${FRAGMENT_CONFIG}"
|
||||
POST_DEFCONFIG_CMDS="rm ${ROOT_DIR}/${KERNEL_DIR}/arch/arm64/configs/${DEFCONFIG}"
|
||||
|
||||
DTC_FLAGS="${DTC_FLAGS} -@"
|
||||
|
||||
FILES="
|
||||
arch/arm64/boot/dts/qcom/sdm845-db845c.dtb
|
||||
arch/arm64/boot/dts/qcom/qrb5165-rb5.dtb
|
||||
|
||||
@@ -1045,9 +1045,13 @@ EXPORT_SYMBOL_GPL(af_alg_sendpage);
|
||||
void af_alg_free_resources(struct af_alg_async_req *areq)
|
||||
{
|
||||
struct sock *sk = areq->sk;
|
||||
struct af_alg_ctx *ctx;
|
||||
|
||||
af_alg_free_areq_sgls(areq);
|
||||
sock_kfree_s(sk, areq, areq->areqlen);
|
||||
|
||||
ctx = alg_sk(sk)->private;
|
||||
ctx->inflight = false;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(af_alg_free_resources);
|
||||
|
||||
@@ -1117,11 +1121,19 @@ EXPORT_SYMBOL_GPL(af_alg_poll);
|
||||
struct af_alg_async_req *af_alg_alloc_areq(struct sock *sk,
|
||||
unsigned int areqlen)
|
||||
{
|
||||
struct af_alg_async_req *areq = sock_kmalloc(sk, areqlen, GFP_KERNEL);
|
||||
struct af_alg_ctx *ctx = alg_sk(sk)->private;
|
||||
struct af_alg_async_req *areq;
|
||||
|
||||
/* Only one AIO request can be in flight. */
|
||||
if (ctx->inflight)
|
||||
return ERR_PTR(-EBUSY);
|
||||
|
||||
areq = sock_kmalloc(sk, areqlen, GFP_KERNEL);
|
||||
if (unlikely(!areq))
|
||||
return ERR_PTR(-ENOMEM);
|
||||
|
||||
ctx->inflight = true;
|
||||
|
||||
areq->areqlen = areqlen;
|
||||
areq->sk = sk;
|
||||
areq->last_rsgl = NULL;
|
||||
|
||||
@@ -124,6 +124,7 @@ static int scomp_acomp_comp_decomp(struct acomp_req *req, int dir)
|
||||
struct crypto_scomp *scomp = *tfm_ctx;
|
||||
void **ctx = acomp_request_ctx(req);
|
||||
struct scomp_scratch *scratch;
|
||||
unsigned int dlen;
|
||||
int ret;
|
||||
|
||||
if (!req->src || !req->slen || req->slen > SCOMP_SCRATCH_SIZE)
|
||||
@@ -135,6 +136,8 @@ static int scomp_acomp_comp_decomp(struct acomp_req *req, int dir)
|
||||
if (!req->dlen || req->dlen > SCOMP_SCRATCH_SIZE)
|
||||
req->dlen = SCOMP_SCRATCH_SIZE;
|
||||
|
||||
dlen = req->dlen;
|
||||
|
||||
scratch = raw_cpu_ptr(&scomp_scratch);
|
||||
spin_lock(&scratch->lock);
|
||||
|
||||
@@ -152,6 +155,9 @@ static int scomp_acomp_comp_decomp(struct acomp_req *req, int dir)
|
||||
ret = -ENOMEM;
|
||||
goto out;
|
||||
}
|
||||
} else if (req->dlen > dlen) {
|
||||
ret = -ENOSPC;
|
||||
goto out;
|
||||
}
|
||||
scatterwalk_map_and_copy(scratch->dst, req->dst, 0, req->dlen,
|
||||
1);
|
||||
|
||||
@@ -145,9 +145,14 @@ static int extlog_print(struct notifier_block *nb, unsigned long val,
|
||||
static u32 err_seq;
|
||||
|
||||
estatus = extlog_elog_entry_check(cpu, bank);
|
||||
if (estatus == NULL || (mce->kflags & MCE_HANDLED_CEC))
|
||||
if (!estatus)
|
||||
return NOTIFY_DONE;
|
||||
|
||||
if (mce->kflags & MCE_HANDLED_CEC) {
|
||||
estatus->block_status = 0;
|
||||
return NOTIFY_DONE;
|
||||
}
|
||||
|
||||
memcpy(elog_buf, (void *)estatus, ELOG_ENTRY_LEN);
|
||||
/* clear record status to enable BIOS to update it again */
|
||||
estatus->block_status = 0;
|
||||
|
||||
@@ -98,7 +98,7 @@ static void lpit_update_residency(struct lpit_residency_info *info,
|
||||
struct acpi_lpit_native *lpit_native)
|
||||
{
|
||||
info->frequency = lpit_native->counter_frequency ?
|
||||
lpit_native->counter_frequency : tsc_khz * 1000;
|
||||
lpit_native->counter_frequency : mul_u32_u32(tsc_khz, 1000U);
|
||||
if (!info->frequency)
|
||||
info->frequency = 1;
|
||||
|
||||
|
||||
@@ -439,8 +439,9 @@ static int register_device_clock(struct acpi_device *adev,
|
||||
if (!clk_name)
|
||||
return -ENOMEM;
|
||||
clk = clk_register_fractional_divider(NULL, clk_name, parent,
|
||||
0, prv_base, 1, 15, 16, 15,
|
||||
CLK_FRAC_DIVIDER_POWER_OF_TWO_PS,
|
||||
prv_base, 1, 15, 16, 15, 0, NULL);
|
||||
NULL);
|
||||
parent = clk_name;
|
||||
|
||||
clk_name = kasprintf(GFP_KERNEL, "%s-update", devname);
|
||||
|
||||
@@ -1793,12 +1793,12 @@ static void acpi_video_dev_register_backlight(struct acpi_video_device *device)
|
||||
return;
|
||||
count++;
|
||||
|
||||
acpi_get_parent(device->dev->handle, &acpi_parent);
|
||||
|
||||
pdev = acpi_get_pci_dev(acpi_parent);
|
||||
if (pdev) {
|
||||
parent = &pdev->dev;
|
||||
pci_dev_put(pdev);
|
||||
if (ACPI_SUCCESS(acpi_get_parent(device->dev->handle, &acpi_parent))) {
|
||||
pdev = acpi_get_pci_dev(acpi_parent);
|
||||
if (pdev) {
|
||||
parent = &pdev->dev;
|
||||
pci_dev_put(pdev);
|
||||
}
|
||||
}
|
||||
|
||||
memset(&props, 0, sizeof(struct backlight_properties));
|
||||
|
||||
@@ -480,6 +480,13 @@ static const struct dmi_system_id maingear_laptop[] = {
|
||||
DMI_MATCH(DMI_BOARD_NAME, "GMxXGxx"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GMxXGxx sold as Eluktronics Inc. RP-15 */
|
||||
.matches = {
|
||||
DMI_MATCH(DMI_SYS_VENDOR, "Eluktronics Inc."),
|
||||
DMI_MATCH(DMI_BOARD_NAME, "RP-15"),
|
||||
},
|
||||
},
|
||||
{
|
||||
/* TongFang GM6XGxX/TUXEDO Stellaris 16 Gen5 AMD */
|
||||
.matches = {
|
||||
|
||||
@@ -1480,11 +1480,16 @@ EXPORT_SYMBOL_GPL(pm_runtime_enable);
|
||||
|
||||
static void pm_runtime_disable_action(void *data)
|
||||
{
|
||||
pm_runtime_dont_use_autosuspend(data);
|
||||
pm_runtime_disable(data);
|
||||
}
|
||||
|
||||
/**
|
||||
* devm_pm_runtime_enable - devres-enabled version of pm_runtime_enable.
|
||||
*
|
||||
* NOTE: this will also handle calling pm_runtime_dont_use_autosuspend() for
|
||||
* you at driver exit time if needed.
|
||||
*
|
||||
* @dev: Device to handle.
|
||||
*/
|
||||
int devm_pm_runtime_enable(struct device *dev)
|
||||
|
||||
@@ -547,6 +547,9 @@ software_node_get_reference_args(const struct fwnode_handle *fwnode,
|
||||
if (nargs > NR_FWNODE_REFERENCE_ARGS)
|
||||
return -EINVAL;
|
||||
|
||||
if (!args)
|
||||
return 0;
|
||||
|
||||
args->fwnode = software_node_get(refnode);
|
||||
args->nargs = nargs;
|
||||
|
||||
|
||||
@@ -1910,12 +1910,8 @@ static int null_add_dev(struct nullb_device *dev)
|
||||
|
||||
blk_queue_logical_block_size(nullb->q, dev->blocksize);
|
||||
blk_queue_physical_block_size(nullb->q, dev->blocksize);
|
||||
if (!dev->max_sectors)
|
||||
dev->max_sectors = queue_max_hw_sectors(nullb->q);
|
||||
dev->max_sectors = min_t(unsigned int, dev->max_sectors,
|
||||
BLK_DEF_MAX_SECTORS);
|
||||
blk_queue_max_hw_sectors(nullb->q, dev->max_sectors);
|
||||
blk_queue_max_segment_size(nullb->q, dev->max_segment_size);
|
||||
if (dev->max_sectors)
|
||||
blk_queue_max_hw_sectors(nullb->q, dev->max_sectors);
|
||||
|
||||
if (dev->virt_boundary)
|
||||
blk_queue_virt_boundary(nullb->q, PAGE_SIZE - 1);
|
||||
@@ -1965,12 +1961,6 @@ static int __init null_init(void)
|
||||
g_bs = PAGE_SIZE;
|
||||
}
|
||||
|
||||
if (g_max_sectors > BLK_DEF_MAX_SECTORS) {
|
||||
pr_warn("invalid max sectors\n");
|
||||
pr_warn("defaults max sectors to %u\n", BLK_DEF_MAX_SECTORS);
|
||||
g_max_sectors = BLK_DEF_MAX_SECTORS;
|
||||
}
|
||||
|
||||
if (g_home_node != NUMA_NO_NODE && g_home_node >= nr_online_nodes) {
|
||||
pr_err("invalid home_node value\n");
|
||||
g_home_node = NUMA_NO_NODE;
|
||||
|
||||
@@ -471,7 +471,7 @@ mtk_stp_split(struct btmtkuart_dev *bdev, const unsigned char *data, int count,
|
||||
return data;
|
||||
}
|
||||
|
||||
static int btmtkuart_recv(struct hci_dev *hdev, const u8 *data, size_t count)
|
||||
static void btmtkuart_recv(struct hci_dev *hdev, const u8 *data, size_t count)
|
||||
{
|
||||
struct btmtkuart_dev *bdev = hci_get_drvdata(hdev);
|
||||
const unsigned char *p_left = data, *p_h4;
|
||||
@@ -510,25 +510,20 @@ static int btmtkuart_recv(struct hci_dev *hdev, const u8 *data, size_t count)
|
||||
bt_dev_err(bdev->hdev,
|
||||
"Frame reassembly failed (%d)", err);
|
||||
bdev->rx_skb = NULL;
|
||||
return err;
|
||||
return;
|
||||
}
|
||||
|
||||
sz_left -= sz_h4;
|
||||
p_left += sz_h4;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int btmtkuart_receive_buf(struct serdev_device *serdev, const u8 *data,
|
||||
size_t count)
|
||||
{
|
||||
struct btmtkuart_dev *bdev = serdev_device_get_drvdata(serdev);
|
||||
int err;
|
||||
|
||||
err = btmtkuart_recv(bdev->hdev, data, count);
|
||||
if (err < 0)
|
||||
return err;
|
||||
btmtkuart_recv(bdev->hdev, data, count);
|
||||
|
||||
bdev->hdev->stat.byte_rx += count;
|
||||
|
||||
|
||||
@@ -2104,13 +2104,23 @@ static int sysc_reset(struct sysc *ddata)
|
||||
sysc_val = sysc_read_sysconfig(ddata);
|
||||
sysc_val |= sysc_mask;
|
||||
sysc_write(ddata, sysc_offset, sysc_val);
|
||||
/* Flush posted write */
|
||||
|
||||
/*
|
||||
* Some devices need a delay before reading registers
|
||||
* after reset. Presumably a srst_udelay is not needed
|
||||
* for devices that use a rstctrl register reset.
|
||||
*/
|
||||
if (ddata->cfg.srst_udelay)
|
||||
fsleep(ddata->cfg.srst_udelay);
|
||||
|
||||
/*
|
||||
* Flush posted write. For devices needing srst_udelay
|
||||
* this should trigger an interconnect error if the
|
||||
* srst_udelay value is needed but not configured.
|
||||
*/
|
||||
sysc_val = sysc_read_sysconfig(ddata);
|
||||
}
|
||||
|
||||
if (ddata->cfg.srst_udelay)
|
||||
fsleep(ddata->cfg.srst_udelay);
|
||||
|
||||
if (ddata->post_reset_quirk)
|
||||
ddata->post_reset_quirk(ddata);
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@ struct asm9260_mux_clock {
|
||||
u8 mask;
|
||||
u32 *table;
|
||||
const char *name;
|
||||
const char **parent_names;
|
||||
const struct clk_parent_data *parent_data;
|
||||
u8 num_parents;
|
||||
unsigned long offset;
|
||||
unsigned long flags;
|
||||
@@ -232,10 +232,10 @@ static const struct asm9260_gate_data asm9260_ahb_gates[] __initconst = {
|
||||
HW_AHBCLKCTRL1, 16 },
|
||||
};
|
||||
|
||||
static const char __initdata *main_mux_p[] = { NULL, NULL };
|
||||
static const char __initdata *i2s0_mux_p[] = { NULL, NULL, "i2s0m_div"};
|
||||
static const char __initdata *i2s1_mux_p[] = { NULL, NULL, "i2s1m_div"};
|
||||
static const char __initdata *clkout_mux_p[] = { NULL, NULL, "rtc"};
|
||||
static struct clk_parent_data __initdata main_mux_p[] = { { .index = 0, }, { .name = "pll" } };
|
||||
static struct clk_parent_data __initdata i2s0_mux_p[] = { { .index = 0, }, { .name = "pll" }, { .name = "i2s0m_div"} };
|
||||
static struct clk_parent_data __initdata i2s1_mux_p[] = { { .index = 0, }, { .name = "pll" }, { .name = "i2s1m_div"} };
|
||||
static struct clk_parent_data __initdata clkout_mux_p[] = { { .index = 0, }, { .name = "pll" }, { .name = "rtc"} };
|
||||
static u32 three_mux_table[] = {0, 1, 3};
|
||||
|
||||
static struct asm9260_mux_clock asm9260_mux_clks[] __initdata = {
|
||||
@@ -255,9 +255,10 @@ static struct asm9260_mux_clock asm9260_mux_clks[] __initdata = {
|
||||
|
||||
static void __init asm9260_acc_init(struct device_node *np)
|
||||
{
|
||||
struct clk_hw *hw;
|
||||
struct clk_hw *hw, *pll_hw;
|
||||
struct clk_hw **hws;
|
||||
const char *ref_clk, *pll_clk = "pll";
|
||||
const char *pll_clk = "pll";
|
||||
struct clk_parent_data pll_parent_data = { .index = 0 };
|
||||
u32 rate;
|
||||
int n;
|
||||
|
||||
@@ -274,21 +275,15 @@ static void __init asm9260_acc_init(struct device_node *np)
|
||||
/* register pll */
|
||||
rate = (ioread32(base + HW_SYSPLLCTRL) & 0xffff) * 1000000;
|
||||
|
||||
/* TODO: Convert to DT parent scheme */
|
||||
ref_clk = of_clk_get_parent_name(np, 0);
|
||||
hw = __clk_hw_register_fixed_rate(NULL, NULL, pll_clk,
|
||||
ref_clk, NULL, NULL, 0, rate, 0,
|
||||
CLK_FIXED_RATE_PARENT_ACCURACY);
|
||||
|
||||
if (IS_ERR(hw))
|
||||
pll_hw = clk_hw_register_fixed_rate_parent_accuracy(NULL, pll_clk, &pll_parent_data,
|
||||
0, rate);
|
||||
if (IS_ERR(pll_hw))
|
||||
panic("%pOFn: can't register REFCLK. Check DT!", np);
|
||||
|
||||
for (n = 0; n < ARRAY_SIZE(asm9260_mux_clks); n++) {
|
||||
const struct asm9260_mux_clock *mc = &asm9260_mux_clks[n];
|
||||
|
||||
mc->parent_names[0] = ref_clk;
|
||||
mc->parent_names[1] = pll_clk;
|
||||
hw = clk_hw_register_mux_table(NULL, mc->name, mc->parent_names,
|
||||
hw = clk_hw_register_mux_table_parent_data(NULL, mc->name, mc->parent_data,
|
||||
mc->num_parents, mc->flags, base + mc->offset,
|
||||
0, mc->mask, 0, mc->table, &asm9260_clk_lock);
|
||||
}
|
||||
|
||||
@@ -49,12 +49,24 @@ const struct clk_ops clk_fixed_rate_ops = {
|
||||
};
|
||||
EXPORT_SYMBOL_GPL(clk_fixed_rate_ops);
|
||||
|
||||
static void devm_clk_hw_register_fixed_rate_release(struct device *dev, void *res)
|
||||
{
|
||||
struct clk_fixed_rate *fix = res;
|
||||
|
||||
/*
|
||||
* We can not use clk_hw_unregister_fixed_rate, since it will kfree()
|
||||
* the hw, resulting in double free. Just unregister the hw and let
|
||||
* devres code kfree() it.
|
||||
*/
|
||||
clk_hw_unregister(&fix->hw);
|
||||
}
|
||||
|
||||
struct clk_hw *__clk_hw_register_fixed_rate(struct device *dev,
|
||||
struct device_node *np, const char *name,
|
||||
const char *parent_name, const struct clk_hw *parent_hw,
|
||||
const struct clk_parent_data *parent_data, unsigned long flags,
|
||||
unsigned long fixed_rate, unsigned long fixed_accuracy,
|
||||
unsigned long clk_fixed_flags)
|
||||
unsigned long clk_fixed_flags, bool devm)
|
||||
{
|
||||
struct clk_fixed_rate *fixed;
|
||||
struct clk_hw *hw;
|
||||
@@ -62,7 +74,11 @@ struct clk_hw *__clk_hw_register_fixed_rate(struct device *dev,
|
||||
int ret = -EINVAL;
|
||||
|
||||
/* allocate fixed-rate clock */
|
||||
fixed = kzalloc(sizeof(*fixed), GFP_KERNEL);
|
||||
if (devm)
|
||||
fixed = devres_alloc(devm_clk_hw_register_fixed_rate_release,
|
||||
sizeof(*fixed), GFP_KERNEL);
|
||||
else
|
||||
fixed = kzalloc(sizeof(*fixed), GFP_KERNEL);
|
||||
if (!fixed)
|
||||
return ERR_PTR(-ENOMEM);
|
||||
|
||||
@@ -90,9 +106,13 @@ struct clk_hw *__clk_hw_register_fixed_rate(struct device *dev,
|
||||
else if (np)
|
||||
ret = of_clk_hw_register(np, hw);
|
||||
if (ret) {
|
||||
kfree(fixed);
|
||||
if (devm)
|
||||
devres_free(fixed);
|
||||
else
|
||||
kfree(fixed);
|
||||
hw = ERR_PTR(ret);
|
||||
}
|
||||
} else if (devm)
|
||||
devres_add(dev, fixed);
|
||||
|
||||
return hw;
|
||||
}
|
||||
|
||||
@@ -892,10 +892,8 @@ static int si5341_output_clk_set_rate(struct clk_hw *hw, unsigned long rate,
|
||||
r[0] = r_div ? (r_div & 0xff) : 1;
|
||||
r[1] = (r_div >> 8) & 0xff;
|
||||
r[2] = (r_div >> 16) & 0xff;
|
||||
err = regmap_bulk_write(output->data->regmap,
|
||||
return regmap_bulk_write(output->data->regmap,
|
||||
SI5341_OUT_R_REG(output), r, 3);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int si5341_output_reparent(struct clk_si5341_output *output, u8 index)
|
||||
|
||||
@@ -37,8 +37,8 @@ static struct alpha_pll_config gpu_cc_pll1_config = {
|
||||
.config_ctl_hi_val = 0x00002267,
|
||||
.config_ctl_hi1_val = 0x00000024,
|
||||
.test_ctl_val = 0x00000000,
|
||||
.test_ctl_hi_val = 0x00000002,
|
||||
.test_ctl_hi1_val = 0x00000000,
|
||||
.test_ctl_hi_val = 0x00000000,
|
||||
.test_ctl_hi1_val = 0x00000020,
|
||||
.user_ctl_val = 0x00000000,
|
||||
.user_ctl_hi_val = 0x00000805,
|
||||
.user_ctl_hi1_val = 0x000000d0,
|
||||
|
||||
@@ -33,6 +33,7 @@ static struct alpha_pll_config video_pll0_config = {
|
||||
.config_ctl_val = 0x20485699,
|
||||
.config_ctl_hi_val = 0x00002267,
|
||||
.config_ctl_hi1_val = 0x00000024,
|
||||
.test_ctl_hi1_val = 0x00000020,
|
||||
.user_ctl_val = 0x00000000,
|
||||
.user_ctl_hi_val = 0x00000805,
|
||||
.user_ctl_hi1_val = 0x000000D0,
|
||||
@@ -214,6 +215,10 @@ static const struct regmap_config video_cc_sm8150_regmap_config = {
|
||||
|
||||
static const struct qcom_reset_map video_cc_sm8150_resets[] = {
|
||||
[VIDEO_CC_MVSC_CORE_CLK_BCR] = { 0x850, 2 },
|
||||
[VIDEO_CC_INTERFACE_BCR] = { 0x8f0 },
|
||||
[VIDEO_CC_MVS0_BCR] = { 0x870 },
|
||||
[VIDEO_CC_MVS1_BCR] = { 0x8b0 },
|
||||
[VIDEO_CC_MVSC_BCR] = { 0x810 },
|
||||
};
|
||||
|
||||
static const struct qcom_cc_desc video_cc_sm8150_desc = {
|
||||
|
||||
@@ -490,7 +490,7 @@ static struct rockchip_clk_branch common_clk_branches[] __initdata = {
|
||||
GATE(HCLK_I2S_2CH, "hclk_i2s_2ch", "hclk_peri", 0, RK2928_CLKGATE_CON(7), 2, GFLAGS),
|
||||
GATE(0, "hclk_usb_peri", "hclk_peri", CLK_IGNORE_UNUSED, RK2928_CLKGATE_CON(9), 13, GFLAGS),
|
||||
GATE(HCLK_HOST2, "hclk_host2", "hclk_peri", 0, RK2928_CLKGATE_CON(7), 3, GFLAGS),
|
||||
GATE(HCLK_OTG, "hclk_otg", "hclk_peri", 0, RK2928_CLKGATE_CON(3), 13, GFLAGS),
|
||||
GATE(HCLK_OTG, "hclk_otg", "hclk_peri", 0, RK2928_CLKGATE_CON(5), 13, GFLAGS),
|
||||
GATE(0, "hclk_peri_ahb", "hclk_peri", CLK_IGNORE_UNUSED, RK2928_CLKGATE_CON(9), 14, GFLAGS),
|
||||
GATE(HCLK_SPDIF, "hclk_spdif", "hclk_peri", 0, RK2928_CLKGATE_CON(10), 9, GFLAGS),
|
||||
GATE(HCLK_TSP, "hclk_tsp", "hclk_peri", 0, RK2928_CLKGATE_CON(10), 12, GFLAGS),
|
||||
|
||||
@@ -89,7 +89,7 @@ static int zynqmp_clk_mux_set_parent(struct clk_hw *hw, u8 index)
|
||||
static const struct clk_ops zynqmp_clk_mux_ops = {
|
||||
.get_parent = zynqmp_clk_mux_get_parent,
|
||||
.set_parent = zynqmp_clk_mux_set_parent,
|
||||
.determine_rate = __clk_mux_determine_rate,
|
||||
.determine_rate = __clk_mux_determine_rate_closest,
|
||||
};
|
||||
|
||||
static const struct clk_ops zynqmp_clk_mux_ro_ops = {
|
||||
|
||||
@@ -110,49 +110,6 @@ static unsigned long zynqmp_clk_divider_recalc_rate(struct clk_hw *hw,
|
||||
return DIV_ROUND_UP_ULL(parent_rate, value);
|
||||
}
|
||||
|
||||
static void zynqmp_get_divider2_val(struct clk_hw *hw,
|
||||
unsigned long rate,
|
||||
struct zynqmp_clk_divider *divider,
|
||||
int *bestdiv)
|
||||
{
|
||||
int div1;
|
||||
int div2;
|
||||
long error = LONG_MAX;
|
||||
unsigned long div1_prate;
|
||||
struct clk_hw *div1_parent_hw;
|
||||
struct clk_hw *div2_parent_hw = clk_hw_get_parent(hw);
|
||||
struct zynqmp_clk_divider *pdivider =
|
||||
to_zynqmp_clk_divider(div2_parent_hw);
|
||||
|
||||
if (!pdivider)
|
||||
return;
|
||||
|
||||
div1_parent_hw = clk_hw_get_parent(div2_parent_hw);
|
||||
if (!div1_parent_hw)
|
||||
return;
|
||||
|
||||
div1_prate = clk_hw_get_rate(div1_parent_hw);
|
||||
*bestdiv = 1;
|
||||
for (div1 = 1; div1 <= pdivider->max_div;) {
|
||||
for (div2 = 1; div2 <= divider->max_div;) {
|
||||
long new_error = ((div1_prate / div1) / div2) - rate;
|
||||
|
||||
if (abs(new_error) < abs(error)) {
|
||||
*bestdiv = div2;
|
||||
error = new_error;
|
||||
}
|
||||
if (divider->flags & CLK_DIVIDER_POWER_OF_TWO)
|
||||
div2 = div2 << 1;
|
||||
else
|
||||
div2++;
|
||||
}
|
||||
if (pdivider->flags & CLK_DIVIDER_POWER_OF_TWO)
|
||||
div1 = div1 << 1;
|
||||
else
|
||||
div1++;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* zynqmp_clk_divider_round_rate() - Round rate of divider clock
|
||||
* @hw: handle between common and hardware-specific interfaces
|
||||
@@ -171,6 +128,7 @@ static long zynqmp_clk_divider_round_rate(struct clk_hw *hw,
|
||||
u32 div_type = divider->div_type;
|
||||
u32 bestdiv;
|
||||
int ret;
|
||||
u8 width;
|
||||
|
||||
/* if read only, just return current value */
|
||||
if (divider->flags & CLK_DIVIDER_READ_ONLY) {
|
||||
@@ -190,23 +148,12 @@ static long zynqmp_clk_divider_round_rate(struct clk_hw *hw,
|
||||
return DIV_ROUND_UP_ULL((u64)*prate, bestdiv);
|
||||
}
|
||||
|
||||
bestdiv = zynqmp_divider_get_val(*prate, rate, divider->flags);
|
||||
width = fls(divider->max_div);
|
||||
|
||||
/*
|
||||
* In case of two divisors, compute best divider values and return
|
||||
* divider2 value based on compute value. div1 will be automatically
|
||||
* set to optimum based on required total divider value.
|
||||
*/
|
||||
if (div_type == TYPE_DIV2 &&
|
||||
(clk_hw_get_flags(hw) & CLK_SET_RATE_PARENT)) {
|
||||
zynqmp_get_divider2_val(hw, rate, divider, &bestdiv);
|
||||
}
|
||||
rate = divider_round_rate(hw, rate, prate, NULL, width, divider->flags);
|
||||
|
||||
if ((clk_hw_get_flags(hw) & CLK_SET_RATE_PARENT) && divider->is_frac)
|
||||
bestdiv = rate % *prate ? 1 : bestdiv;
|
||||
|
||||
bestdiv = min_t(u32, bestdiv, divider->max_div);
|
||||
*prate = rate * bestdiv;
|
||||
if (divider->is_frac && (clk_hw_get_flags(hw) & CLK_SET_RATE_PARENT) && (rate % *prate))
|
||||
*prate = rate;
|
||||
|
||||
return rate;
|
||||
}
|
||||
|
||||
@@ -171,7 +171,7 @@ static bool __init cpu0_node_has_opp_v2_prop(void)
|
||||
struct device_node *np = of_cpu_device_node_get(0);
|
||||
bool ret = false;
|
||||
|
||||
if (of_get_property(np, "operating-points-v2", NULL))
|
||||
if (of_property_present(np, "operating-points-v2"))
|
||||
ret = true;
|
||||
|
||||
of_node_put(np);
|
||||
|
||||
@@ -89,7 +89,7 @@ static int imx_cpufreq_dt_probe(struct platform_device *pdev)
|
||||
|
||||
cpu_dev = get_cpu_device(0);
|
||||
|
||||
if (!of_find_property(cpu_dev->of_node, "cpu-supply", NULL))
|
||||
if (!of_property_present(cpu_dev->of_node, "cpu-supply"))
|
||||
return -ENODEV;
|
||||
|
||||
if (of_machine_is_compatible("fsl,imx7ulp")) {
|
||||
|
||||
@@ -230,7 +230,7 @@ static int imx6q_opp_check_speed_grading(struct device *dev)
|
||||
u32 val;
|
||||
int ret;
|
||||
|
||||
if (of_find_property(dev->of_node, "nvmem-cells", NULL)) {
|
||||
if (of_property_present(dev->of_node, "nvmem-cells")) {
|
||||
ret = nvmem_cell_read_u32(dev, "speed_grade", &val);
|
||||
if (ret)
|
||||
return ret;
|
||||
@@ -285,7 +285,7 @@ static int imx6ul_opp_check_speed_grading(struct device *dev)
|
||||
u32 val;
|
||||
int ret = 0;
|
||||
|
||||
if (of_find_property(dev->of_node, "nvmem-cells", NULL)) {
|
||||
if (of_property_present(dev->of_node, "nvmem-cells")) {
|
||||
ret = nvmem_cell_read_u32(dev, "speed_grade", &val);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
@@ -299,8 +299,11 @@ static int scmi_cpufreq_probe(struct scmi_device *sdev)
|
||||
|
||||
#ifdef CONFIG_COMMON_CLK
|
||||
/* dummy clock provider as needed by OPP if clocks property is used */
|
||||
if (of_find_property(dev->of_node, "#clock-cells", NULL))
|
||||
devm_of_clk_add_hw_provider(dev, of_clk_hw_simple_get, NULL);
|
||||
if (of_property_present(dev->of_node, "#clock-cells")) {
|
||||
ret = devm_of_clk_add_hw_provider(dev, of_clk_hw_simple_get, NULL);
|
||||
if (ret)
|
||||
return dev_err_probe(dev, ret, "%s: registering clock provider failed\n", __func__);
|
||||
}
|
||||
#endif
|
||||
|
||||
ret = cpufreq_register_driver(&scmi_cpufreq_driver);
|
||||
|
||||
@@ -25,7 +25,7 @@ static bool cpu0_node_has_opp_v2_prop(void)
|
||||
struct device_node *np = of_cpu_device_node_get(0);
|
||||
bool ret = false;
|
||||
|
||||
if (of_get_property(np, "operating-points-v2", NULL))
|
||||
if (of_property_present(np, "operating-points-v2"))
|
||||
ret = true;
|
||||
|
||||
of_node_put(np);
|
||||
|
||||
@@ -179,8 +179,11 @@ static int ccp_init_dm_workarea(struct ccp_dm_workarea *wa,
|
||||
|
||||
wa->dma.address = dma_map_single(wa->dev, wa->address, len,
|
||||
dir);
|
||||
if (dma_mapping_error(wa->dev, wa->dma.address))
|
||||
if (dma_mapping_error(wa->dev, wa->dma.address)) {
|
||||
kfree(wa->address);
|
||||
wa->address = NULL;
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
wa->dma.length = len;
|
||||
}
|
||||
|
||||
@@ -1868,9 +1868,8 @@ static int sa_aead_setkey(struct crypto_aead *authenc,
|
||||
crypto_aead_set_flags(ctx->fallback.aead,
|
||||
crypto_aead_get_flags(authenc) &
|
||||
CRYPTO_TFM_REQ_MASK);
|
||||
crypto_aead_setkey(ctx->fallback.aead, key, keylen);
|
||||
|
||||
return 0;
|
||||
return crypto_aead_setkey(ctx->fallback.aead, key, keylen);
|
||||
}
|
||||
|
||||
static int sa_aead_setauthsize(struct crypto_aead *tfm, unsigned int authsize)
|
||||
|
||||
@@ -44,7 +44,6 @@
|
||||
#define FLAGS_MODE_MASK 0x000f
|
||||
#define FLAGS_ENCRYPT BIT(0)
|
||||
#define FLAGS_CBC BIT(1)
|
||||
#define FLAGS_NEW_KEY BIT(3)
|
||||
|
||||
#define SAHARA_HDR_BASE 0x00800000
|
||||
#define SAHARA_HDR_SKHA_ALG_AES 0
|
||||
@@ -142,8 +141,6 @@ struct sahara_hw_link {
|
||||
};
|
||||
|
||||
struct sahara_ctx {
|
||||
unsigned long flags;
|
||||
|
||||
/* AES-specific context */
|
||||
int keylen;
|
||||
u8 key[AES_KEYSIZE_128];
|
||||
@@ -152,6 +149,7 @@ struct sahara_ctx {
|
||||
|
||||
struct sahara_aes_reqctx {
|
||||
unsigned long mode;
|
||||
u8 iv_out[AES_BLOCK_SIZE];
|
||||
struct skcipher_request fallback_req; // keep at the end
|
||||
};
|
||||
|
||||
@@ -447,27 +445,24 @@ static int sahara_hw_descriptor_create(struct sahara_dev *dev)
|
||||
int ret;
|
||||
int i, j;
|
||||
int idx = 0;
|
||||
u32 len;
|
||||
|
||||
/* Copy new key if necessary */
|
||||
if (ctx->flags & FLAGS_NEW_KEY) {
|
||||
memcpy(dev->key_base, ctx->key, ctx->keylen);
|
||||
ctx->flags &= ~FLAGS_NEW_KEY;
|
||||
memcpy(dev->key_base, ctx->key, ctx->keylen);
|
||||
|
||||
if (dev->flags & FLAGS_CBC) {
|
||||
dev->hw_desc[idx]->len1 = AES_BLOCK_SIZE;
|
||||
dev->hw_desc[idx]->p1 = dev->iv_phys_base;
|
||||
} else {
|
||||
dev->hw_desc[idx]->len1 = 0;
|
||||
dev->hw_desc[idx]->p1 = 0;
|
||||
}
|
||||
dev->hw_desc[idx]->len2 = ctx->keylen;
|
||||
dev->hw_desc[idx]->p2 = dev->key_phys_base;
|
||||
dev->hw_desc[idx]->next = dev->hw_phys_desc[1];
|
||||
|
||||
dev->hw_desc[idx]->hdr = sahara_aes_key_hdr(dev);
|
||||
|
||||
idx++;
|
||||
if (dev->flags & FLAGS_CBC) {
|
||||
dev->hw_desc[idx]->len1 = AES_BLOCK_SIZE;
|
||||
dev->hw_desc[idx]->p1 = dev->iv_phys_base;
|
||||
} else {
|
||||
dev->hw_desc[idx]->len1 = 0;
|
||||
dev->hw_desc[idx]->p1 = 0;
|
||||
}
|
||||
dev->hw_desc[idx]->len2 = ctx->keylen;
|
||||
dev->hw_desc[idx]->p2 = dev->key_phys_base;
|
||||
dev->hw_desc[idx]->next = dev->hw_phys_desc[1];
|
||||
dev->hw_desc[idx]->hdr = sahara_aes_key_hdr(dev);
|
||||
|
||||
idx++;
|
||||
|
||||
|
||||
dev->nb_in_sg = sg_nents_for_len(dev->in_sg, dev->total);
|
||||
if (dev->nb_in_sg < 0) {
|
||||
@@ -489,24 +484,27 @@ static int sahara_hw_descriptor_create(struct sahara_dev *dev)
|
||||
DMA_TO_DEVICE);
|
||||
if (ret != dev->nb_in_sg) {
|
||||
dev_err(dev->device, "couldn't map in sg\n");
|
||||
goto unmap_in;
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
ret = dma_map_sg(dev->device, dev->out_sg, dev->nb_out_sg,
|
||||
DMA_FROM_DEVICE);
|
||||
if (ret != dev->nb_out_sg) {
|
||||
dev_err(dev->device, "couldn't map out sg\n");
|
||||
goto unmap_out;
|
||||
goto unmap_in;
|
||||
}
|
||||
|
||||
/* Create input links */
|
||||
dev->hw_desc[idx]->p1 = dev->hw_phys_link[0];
|
||||
sg = dev->in_sg;
|
||||
len = dev->total;
|
||||
for (i = 0; i < dev->nb_in_sg; i++) {
|
||||
dev->hw_link[i]->len = sg->length;
|
||||
dev->hw_link[i]->len = min(len, sg->length);
|
||||
dev->hw_link[i]->p = sg->dma_address;
|
||||
if (i == (dev->nb_in_sg - 1)) {
|
||||
dev->hw_link[i]->next = 0;
|
||||
} else {
|
||||
len -= min(len, sg->length);
|
||||
dev->hw_link[i]->next = dev->hw_phys_link[i + 1];
|
||||
sg = sg_next(sg);
|
||||
}
|
||||
@@ -515,12 +513,14 @@ static int sahara_hw_descriptor_create(struct sahara_dev *dev)
|
||||
/* Create output links */
|
||||
dev->hw_desc[idx]->p2 = dev->hw_phys_link[i];
|
||||
sg = dev->out_sg;
|
||||
len = dev->total;
|
||||
for (j = i; j < dev->nb_out_sg + i; j++) {
|
||||
dev->hw_link[j]->len = sg->length;
|
||||
dev->hw_link[j]->len = min(len, sg->length);
|
||||
dev->hw_link[j]->p = sg->dma_address;
|
||||
if (j == (dev->nb_out_sg + i - 1)) {
|
||||
dev->hw_link[j]->next = 0;
|
||||
} else {
|
||||
len -= min(len, sg->length);
|
||||
dev->hw_link[j]->next = dev->hw_phys_link[j + 1];
|
||||
sg = sg_next(sg);
|
||||
}
|
||||
@@ -539,9 +539,6 @@ static int sahara_hw_descriptor_create(struct sahara_dev *dev)
|
||||
|
||||
return 0;
|
||||
|
||||
unmap_out:
|
||||
dma_unmap_sg(dev->device, dev->out_sg, dev->nb_out_sg,
|
||||
DMA_FROM_DEVICE);
|
||||
unmap_in:
|
||||
dma_unmap_sg(dev->device, dev->in_sg, dev->nb_in_sg,
|
||||
DMA_TO_DEVICE);
|
||||
@@ -549,8 +546,24 @@ unmap_in:
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
static void sahara_aes_cbc_update_iv(struct skcipher_request *req)
|
||||
{
|
||||
struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req);
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
unsigned int ivsize = crypto_skcipher_ivsize(skcipher);
|
||||
|
||||
/* Update IV buffer to contain the last ciphertext block */
|
||||
if (rctx->mode & FLAGS_ENCRYPT) {
|
||||
sg_pcopy_to_buffer(req->dst, sg_nents(req->dst), req->iv,
|
||||
ivsize, req->cryptlen - ivsize);
|
||||
} else {
|
||||
memcpy(req->iv, rctx->iv_out, ivsize);
|
||||
}
|
||||
}
|
||||
|
||||
static int sahara_aes_process(struct skcipher_request *req)
|
||||
{
|
||||
struct crypto_skcipher *skcipher = crypto_skcipher_reqtfm(req);
|
||||
struct sahara_dev *dev = dev_ptr;
|
||||
struct sahara_ctx *ctx;
|
||||
struct sahara_aes_reqctx *rctx;
|
||||
@@ -572,8 +585,17 @@ static int sahara_aes_process(struct skcipher_request *req)
|
||||
rctx->mode &= FLAGS_MODE_MASK;
|
||||
dev->flags = (dev->flags & ~FLAGS_MODE_MASK) | rctx->mode;
|
||||
|
||||
if ((dev->flags & FLAGS_CBC) && req->iv)
|
||||
memcpy(dev->iv_base, req->iv, AES_KEYSIZE_128);
|
||||
if ((dev->flags & FLAGS_CBC) && req->iv) {
|
||||
unsigned int ivsize = crypto_skcipher_ivsize(skcipher);
|
||||
|
||||
memcpy(dev->iv_base, req->iv, ivsize);
|
||||
|
||||
if (!(dev->flags & FLAGS_ENCRYPT)) {
|
||||
sg_pcopy_to_buffer(req->src, sg_nents(req->src),
|
||||
rctx->iv_out, ivsize,
|
||||
req->cryptlen - ivsize);
|
||||
}
|
||||
}
|
||||
|
||||
/* assign new context to device */
|
||||
dev->ctx = ctx;
|
||||
@@ -586,16 +608,20 @@ static int sahara_aes_process(struct skcipher_request *req)
|
||||
|
||||
timeout = wait_for_completion_timeout(&dev->dma_completion,
|
||||
msecs_to_jiffies(SAHARA_TIMEOUT_MS));
|
||||
if (!timeout) {
|
||||
dev_err(dev->device, "AES timeout\n");
|
||||
return -ETIMEDOUT;
|
||||
}
|
||||
|
||||
dma_unmap_sg(dev->device, dev->out_sg, dev->nb_out_sg,
|
||||
DMA_FROM_DEVICE);
|
||||
dma_unmap_sg(dev->device, dev->in_sg, dev->nb_in_sg,
|
||||
DMA_TO_DEVICE);
|
||||
|
||||
if (!timeout) {
|
||||
dev_err(dev->device, "AES timeout\n");
|
||||
return -ETIMEDOUT;
|
||||
}
|
||||
|
||||
if ((dev->flags & FLAGS_CBC) && req->iv)
|
||||
sahara_aes_cbc_update_iv(req);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -609,7 +635,6 @@ static int sahara_aes_setkey(struct crypto_skcipher *tfm, const u8 *key,
|
||||
/* SAHARA only supports 128bit keys */
|
||||
if (keylen == AES_KEYSIZE_128) {
|
||||
memcpy(ctx->key, key, keylen);
|
||||
ctx->flags |= FLAGS_NEW_KEY;
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -625,12 +650,40 @@ static int sahara_aes_setkey(struct crypto_skcipher *tfm, const u8 *key,
|
||||
return crypto_skcipher_setkey(ctx->fallback, key, keylen);
|
||||
}
|
||||
|
||||
static int sahara_aes_fallback(struct skcipher_request *req, unsigned long mode)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
|
||||
skcipher_request_set_tfm(&rctx->fallback_req, ctx->fallback);
|
||||
skcipher_request_set_callback(&rctx->fallback_req,
|
||||
req->base.flags,
|
||||
req->base.complete,
|
||||
req->base.data);
|
||||
skcipher_request_set_crypt(&rctx->fallback_req, req->src,
|
||||
req->dst, req->cryptlen, req->iv);
|
||||
|
||||
if (mode & FLAGS_ENCRYPT)
|
||||
return crypto_skcipher_encrypt(&rctx->fallback_req);
|
||||
|
||||
return crypto_skcipher_decrypt(&rctx->fallback_req);
|
||||
}
|
||||
|
||||
static int sahara_aes_crypt(struct skcipher_request *req, unsigned long mode)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
struct sahara_dev *dev = dev_ptr;
|
||||
int err = 0;
|
||||
|
||||
if (!req->cryptlen)
|
||||
return 0;
|
||||
|
||||
if (unlikely(ctx->keylen != AES_KEYSIZE_128))
|
||||
return sahara_aes_fallback(req, mode);
|
||||
|
||||
dev_dbg(dev->device, "nbytes: %d, enc: %d, cbc: %d\n",
|
||||
req->cryptlen, !!(mode & FLAGS_ENCRYPT), !!(mode & FLAGS_CBC));
|
||||
|
||||
@@ -653,81 +706,21 @@ static int sahara_aes_crypt(struct skcipher_request *req, unsigned long mode)
|
||||
|
||||
static int sahara_aes_ecb_encrypt(struct skcipher_request *req)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
|
||||
if (unlikely(ctx->keylen != AES_KEYSIZE_128)) {
|
||||
skcipher_request_set_tfm(&rctx->fallback_req, ctx->fallback);
|
||||
skcipher_request_set_callback(&rctx->fallback_req,
|
||||
req->base.flags,
|
||||
req->base.complete,
|
||||
req->base.data);
|
||||
skcipher_request_set_crypt(&rctx->fallback_req, req->src,
|
||||
req->dst, req->cryptlen, req->iv);
|
||||
return crypto_skcipher_encrypt(&rctx->fallback_req);
|
||||
}
|
||||
|
||||
return sahara_aes_crypt(req, FLAGS_ENCRYPT);
|
||||
}
|
||||
|
||||
static int sahara_aes_ecb_decrypt(struct skcipher_request *req)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
|
||||
if (unlikely(ctx->keylen != AES_KEYSIZE_128)) {
|
||||
skcipher_request_set_tfm(&rctx->fallback_req, ctx->fallback);
|
||||
skcipher_request_set_callback(&rctx->fallback_req,
|
||||
req->base.flags,
|
||||
req->base.complete,
|
||||
req->base.data);
|
||||
skcipher_request_set_crypt(&rctx->fallback_req, req->src,
|
||||
req->dst, req->cryptlen, req->iv);
|
||||
return crypto_skcipher_decrypt(&rctx->fallback_req);
|
||||
}
|
||||
|
||||
return sahara_aes_crypt(req, 0);
|
||||
}
|
||||
|
||||
static int sahara_aes_cbc_encrypt(struct skcipher_request *req)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
|
||||
if (unlikely(ctx->keylen != AES_KEYSIZE_128)) {
|
||||
skcipher_request_set_tfm(&rctx->fallback_req, ctx->fallback);
|
||||
skcipher_request_set_callback(&rctx->fallback_req,
|
||||
req->base.flags,
|
||||
req->base.complete,
|
||||
req->base.data);
|
||||
skcipher_request_set_crypt(&rctx->fallback_req, req->src,
|
||||
req->dst, req->cryptlen, req->iv);
|
||||
return crypto_skcipher_encrypt(&rctx->fallback_req);
|
||||
}
|
||||
|
||||
return sahara_aes_crypt(req, FLAGS_ENCRYPT | FLAGS_CBC);
|
||||
}
|
||||
|
||||
static int sahara_aes_cbc_decrypt(struct skcipher_request *req)
|
||||
{
|
||||
struct sahara_aes_reqctx *rctx = skcipher_request_ctx(req);
|
||||
struct sahara_ctx *ctx = crypto_skcipher_ctx(
|
||||
crypto_skcipher_reqtfm(req));
|
||||
|
||||
if (unlikely(ctx->keylen != AES_KEYSIZE_128)) {
|
||||
skcipher_request_set_tfm(&rctx->fallback_req, ctx->fallback);
|
||||
skcipher_request_set_callback(&rctx->fallback_req,
|
||||
req->base.flags,
|
||||
req->base.complete,
|
||||
req->base.data);
|
||||
skcipher_request_set_crypt(&rctx->fallback_req, req->src,
|
||||
req->dst, req->cryptlen, req->iv);
|
||||
return crypto_skcipher_decrypt(&rctx->fallback_req);
|
||||
}
|
||||
|
||||
return sahara_aes_crypt(req, FLAGS_CBC);
|
||||
}
|
||||
|
||||
@@ -784,6 +777,7 @@ static int sahara_sha_hw_links_create(struct sahara_dev *dev,
|
||||
int start)
|
||||
{
|
||||
struct scatterlist *sg;
|
||||
unsigned int len;
|
||||
unsigned int i;
|
||||
int ret;
|
||||
|
||||
@@ -805,12 +799,14 @@ static int sahara_sha_hw_links_create(struct sahara_dev *dev,
|
||||
if (!ret)
|
||||
return -EFAULT;
|
||||
|
||||
len = rctx->total;
|
||||
for (i = start; i < dev->nb_in_sg + start; i++) {
|
||||
dev->hw_link[i]->len = sg->length;
|
||||
dev->hw_link[i]->len = min(len, sg->length);
|
||||
dev->hw_link[i]->p = sg->dma_address;
|
||||
if (i == (dev->nb_in_sg + start - 1)) {
|
||||
dev->hw_link[i]->next = 0;
|
||||
} else {
|
||||
len -= min(len, sg->length);
|
||||
dev->hw_link[i]->next = dev->hw_phys_link[i + 1];
|
||||
sg = sg_next(sg);
|
||||
}
|
||||
@@ -891,24 +887,6 @@ static int sahara_sha_hw_context_descriptor_create(struct sahara_dev *dev,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int sahara_walk_and_recalc(struct scatterlist *sg, unsigned int nbytes)
|
||||
{
|
||||
if (!sg || !sg->length)
|
||||
return nbytes;
|
||||
|
||||
while (nbytes && sg) {
|
||||
if (nbytes <= sg->length) {
|
||||
sg->length = nbytes;
|
||||
sg_mark_end(sg);
|
||||
break;
|
||||
}
|
||||
nbytes -= sg->length;
|
||||
sg = sg_next(sg);
|
||||
}
|
||||
|
||||
return nbytes;
|
||||
}
|
||||
|
||||
static int sahara_sha_prepare_request(struct ahash_request *req)
|
||||
{
|
||||
struct crypto_ahash *tfm = crypto_ahash_reqtfm(req);
|
||||
@@ -945,36 +923,20 @@ static int sahara_sha_prepare_request(struct ahash_request *req)
|
||||
hash_later, 0);
|
||||
}
|
||||
|
||||
/* nbytes should now be multiple of blocksize */
|
||||
req->nbytes = req->nbytes - hash_later;
|
||||
|
||||
sahara_walk_and_recalc(req->src, req->nbytes);
|
||||
|
||||
rctx->total = len - hash_later;
|
||||
/* have data from previous operation and current */
|
||||
if (rctx->buf_cnt && req->nbytes) {
|
||||
sg_init_table(rctx->in_sg_chain, 2);
|
||||
sg_set_buf(rctx->in_sg_chain, rctx->rembuf, rctx->buf_cnt);
|
||||
|
||||
sg_chain(rctx->in_sg_chain, 2, req->src);
|
||||
|
||||
rctx->total = req->nbytes + rctx->buf_cnt;
|
||||
rctx->in_sg = rctx->in_sg_chain;
|
||||
|
||||
req->src = rctx->in_sg_chain;
|
||||
/* only data from previous operation */
|
||||
} else if (rctx->buf_cnt) {
|
||||
if (req->src)
|
||||
rctx->in_sg = req->src;
|
||||
else
|
||||
rctx->in_sg = rctx->in_sg_chain;
|
||||
/* buf was copied into rembuf above */
|
||||
rctx->in_sg = rctx->in_sg_chain;
|
||||
sg_init_one(rctx->in_sg, rctx->rembuf, rctx->buf_cnt);
|
||||
rctx->total = rctx->buf_cnt;
|
||||
/* no data from previous operation */
|
||||
} else {
|
||||
rctx->in_sg = req->src;
|
||||
rctx->total = req->nbytes;
|
||||
req->src = rctx->in_sg;
|
||||
}
|
||||
|
||||
/* on next call, we only have the remaining data in the buffer */
|
||||
@@ -995,7 +957,10 @@ static int sahara_sha_process(struct ahash_request *req)
|
||||
return ret;
|
||||
|
||||
if (rctx->first) {
|
||||
sahara_sha_hw_data_descriptor_create(dev, rctx, req, 0);
|
||||
ret = sahara_sha_hw_data_descriptor_create(dev, rctx, req, 0);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
dev->hw_desc[0]->next = 0;
|
||||
rctx->first = 0;
|
||||
} else {
|
||||
@@ -1003,7 +968,10 @@ static int sahara_sha_process(struct ahash_request *req)
|
||||
|
||||
sahara_sha_hw_context_descriptor_create(dev, rctx, req, 0);
|
||||
dev->hw_desc[0]->next = dev->hw_phys_desc[1];
|
||||
sahara_sha_hw_data_descriptor_create(dev, rctx, req, 1);
|
||||
ret = sahara_sha_hw_data_descriptor_create(dev, rctx, req, 1);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
dev->hw_desc[1]->next = 0;
|
||||
}
|
||||
|
||||
@@ -1016,18 +984,19 @@ static int sahara_sha_process(struct ahash_request *req)
|
||||
|
||||
timeout = wait_for_completion_timeout(&dev->dma_completion,
|
||||
msecs_to_jiffies(SAHARA_TIMEOUT_MS));
|
||||
if (!timeout) {
|
||||
dev_err(dev->device, "SHA timeout\n");
|
||||
return -ETIMEDOUT;
|
||||
}
|
||||
|
||||
if (rctx->sg_in_idx)
|
||||
dma_unmap_sg(dev->device, dev->in_sg, dev->nb_in_sg,
|
||||
DMA_TO_DEVICE);
|
||||
|
||||
if (!timeout) {
|
||||
dev_err(dev->device, "SHA timeout\n");
|
||||
return -ETIMEDOUT;
|
||||
}
|
||||
|
||||
memcpy(rctx->context, dev->context_base, rctx->context_size);
|
||||
|
||||
if (req->result)
|
||||
if (req->result && rctx->last)
|
||||
memcpy(req->result, rctx->context, rctx->digest_size);
|
||||
|
||||
return 0;
|
||||
@@ -1171,8 +1140,7 @@ static int sahara_sha_import(struct ahash_request *req, const void *in)
|
||||
static int sahara_sha_cra_init(struct crypto_tfm *tfm)
|
||||
{
|
||||
crypto_ahash_set_reqsize(__crypto_ahash_cast(tfm),
|
||||
sizeof(struct sahara_sha_reqctx) +
|
||||
SHA_BUFFER_LEN + SHA256_BLOCK_SIZE);
|
||||
sizeof(struct sahara_sha_reqctx));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -255,7 +255,7 @@ static int virtio_crypto_alg_skcipher_close_session(
|
||||
vcrypto->ctrl_status.status,
|
||||
destroy_session->session_id);
|
||||
|
||||
return -EINVAL;
|
||||
err = -EINVAL;
|
||||
}
|
||||
spin_unlock(&vcrypto->ctrl_lock);
|
||||
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
#include <linux/virtio.h>
|
||||
#include <linux/crypto.h>
|
||||
#include <linux/spinlock.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <crypto/aead.h>
|
||||
#include <crypto/aes.h>
|
||||
#include <crypto/engine.h>
|
||||
@@ -27,6 +28,7 @@ struct data_queue {
|
||||
char name[32];
|
||||
|
||||
struct crypto_engine *engine;
|
||||
struct tasklet_struct done_task;
|
||||
};
|
||||
|
||||
struct virtio_crypto {
|
||||
|
||||
@@ -22,27 +22,28 @@ virtcrypto_clear_request(struct virtio_crypto_request *vc_req)
|
||||
}
|
||||
}
|
||||
|
||||
static void virtcrypto_dataq_callback(struct virtqueue *vq)
|
||||
static void virtcrypto_done_task(unsigned long data)
|
||||
{
|
||||
struct virtio_crypto *vcrypto = vq->vdev->priv;
|
||||
struct data_queue *data_vq = (struct data_queue *)data;
|
||||
struct virtqueue *vq = data_vq->vq;
|
||||
struct virtio_crypto_request *vc_req;
|
||||
unsigned long flags;
|
||||
unsigned int len;
|
||||
unsigned int qid = vq->index;
|
||||
|
||||
spin_lock_irqsave(&vcrypto->data_vq[qid].lock, flags);
|
||||
do {
|
||||
virtqueue_disable_cb(vq);
|
||||
while ((vc_req = virtqueue_get_buf(vq, &len)) != NULL) {
|
||||
spin_unlock_irqrestore(
|
||||
&vcrypto->data_vq[qid].lock, flags);
|
||||
if (vc_req->alg_cb)
|
||||
vc_req->alg_cb(vc_req, len);
|
||||
spin_lock_irqsave(
|
||||
&vcrypto->data_vq[qid].lock, flags);
|
||||
}
|
||||
} while (!virtqueue_enable_cb(vq));
|
||||
spin_unlock_irqrestore(&vcrypto->data_vq[qid].lock, flags);
|
||||
}
|
||||
|
||||
static void virtcrypto_dataq_callback(struct virtqueue *vq)
|
||||
{
|
||||
struct virtio_crypto *vcrypto = vq->vdev->priv;
|
||||
struct data_queue *dq = &vcrypto->data_vq[vq->index];
|
||||
|
||||
tasklet_schedule(&dq->done_task);
|
||||
}
|
||||
|
||||
static int virtcrypto_find_vqs(struct virtio_crypto *vi)
|
||||
@@ -99,6 +100,8 @@ static int virtcrypto_find_vqs(struct virtio_crypto *vi)
|
||||
ret = -ENOMEM;
|
||||
goto err_engine;
|
||||
}
|
||||
tasklet_init(&vi->data_vq[i].done_task, virtcrypto_done_task,
|
||||
(unsigned long)&vi->data_vq[i]);
|
||||
}
|
||||
|
||||
kfree(names);
|
||||
@@ -431,11 +434,14 @@ static void virtcrypto_free_unused_reqs(struct virtio_crypto *vcrypto)
|
||||
static void virtcrypto_remove(struct virtio_device *vdev)
|
||||
{
|
||||
struct virtio_crypto *vcrypto = vdev->priv;
|
||||
int i;
|
||||
|
||||
dev_info(&vdev->dev, "Start virtcrypto_remove.\n");
|
||||
|
||||
if (virtcrypto_dev_started(vcrypto))
|
||||
virtcrypto_dev_stop(vcrypto);
|
||||
for (i = 0; i < vcrypto->max_data_queues; i++)
|
||||
tasklet_kill(&vcrypto->data_vq[i].done_task);
|
||||
vdev->config->reset(vdev);
|
||||
virtcrypto_free_unused_reqs(vcrypto);
|
||||
virtcrypto_clear_crypto_engines(vcrypto);
|
||||
|
||||
@@ -1133,7 +1133,7 @@ static irqreturn_t thunderx_ocx_com_threaded_isr(int irq, void *irq_id)
|
||||
decode_register(other, OCX_OTHER_SIZE,
|
||||
ocx_com_errors, ctx->reg_com_int);
|
||||
|
||||
strncat(msg, other, OCX_MESSAGE_SIZE);
|
||||
strlcat(msg, other, OCX_MESSAGE_SIZE);
|
||||
|
||||
for (lane = 0; lane < OCX_RX_LANES; lane++)
|
||||
if (ctx->reg_com_int & BIT(lane)) {
|
||||
@@ -1142,12 +1142,12 @@ static irqreturn_t thunderx_ocx_com_threaded_isr(int irq, void *irq_id)
|
||||
lane, ctx->reg_lane_int[lane],
|
||||
lane, ctx->reg_lane_stat11[lane]);
|
||||
|
||||
strncat(msg, other, OCX_MESSAGE_SIZE);
|
||||
strlcat(msg, other, OCX_MESSAGE_SIZE);
|
||||
|
||||
decode_register(other, OCX_OTHER_SIZE,
|
||||
ocx_lane_errors,
|
||||
ctx->reg_lane_int[lane]);
|
||||
strncat(msg, other, OCX_MESSAGE_SIZE);
|
||||
strlcat(msg, other, OCX_MESSAGE_SIZE);
|
||||
}
|
||||
|
||||
if (ctx->reg_com_int & OCX_COM_INT_CE)
|
||||
@@ -1217,7 +1217,7 @@ static irqreturn_t thunderx_ocx_lnk_threaded_isr(int irq, void *irq_id)
|
||||
decode_register(other, OCX_OTHER_SIZE,
|
||||
ocx_com_link_errors, ctx->reg_com_link_int);
|
||||
|
||||
strncat(msg, other, OCX_MESSAGE_SIZE);
|
||||
strlcat(msg, other, OCX_MESSAGE_SIZE);
|
||||
|
||||
if (ctx->reg_com_link_int & OCX_COM_LINK_INT_UE)
|
||||
edac_device_handle_ue(ocx->edac_dev, 0, 0, msg);
|
||||
@@ -1896,7 +1896,7 @@ static irqreturn_t thunderx_l2c_threaded_isr(int irq, void *irq_id)
|
||||
|
||||
decode_register(other, L2C_OTHER_SIZE, l2_errors, ctx->reg_int);
|
||||
|
||||
strncat(msg, other, L2C_MESSAGE_SIZE);
|
||||
strlcat(msg, other, L2C_MESSAGE_SIZE);
|
||||
|
||||
if (ctx->reg_int & mask_ue)
|
||||
edac_device_handle_ue(l2c->edac_dev, 0, 0, msg);
|
||||
|
||||
@@ -279,6 +279,51 @@ static char ohci_driver_name[] = KBUILD_MODNAME;
|
||||
#define QUIRK_TI_SLLZ059 0x20
|
||||
#define QUIRK_IR_WAKE 0x40
|
||||
|
||||
// On PCI Express Root Complex in any type of AMD Ryzen machine, VIA VT6306/6307/6308 with Asmedia
|
||||
// ASM1083/1085 brings an inconvenience that the read accesses to 'Isochronous Cycle Timer' register
|
||||
// (at offset 0xf0 in PCI I/O space) often causes unexpected system reboot. The mechanism is not
|
||||
// clear, since the read access to the other registers is enough safe; e.g. 'Node ID' register,
|
||||
// while it is probable due to detection of any type of PCIe error.
|
||||
#define QUIRK_REBOOT_BY_CYCLE_TIMER_READ 0x80000000
|
||||
|
||||
#if IS_ENABLED(CONFIG_X86)
|
||||
|
||||
static bool has_reboot_by_cycle_timer_read_quirk(const struct fw_ohci *ohci)
|
||||
{
|
||||
return !!(ohci->quirks & QUIRK_REBOOT_BY_CYCLE_TIMER_READ);
|
||||
}
|
||||
|
||||
#define PCI_DEVICE_ID_ASMEDIA_ASM108X 0x1080
|
||||
|
||||
static bool detect_vt630x_with_asm1083_on_amd_ryzen_machine(const struct pci_dev *pdev)
|
||||
{
|
||||
const struct pci_dev *pcie_to_pci_bridge;
|
||||
|
||||
// Detect any type of AMD Ryzen machine.
|
||||
if (!static_cpu_has(X86_FEATURE_ZEN))
|
||||
return false;
|
||||
|
||||
// Detect VIA VT6306/6307/6308.
|
||||
if (pdev->vendor != PCI_VENDOR_ID_VIA)
|
||||
return false;
|
||||
if (pdev->device != PCI_DEVICE_ID_VIA_VT630X)
|
||||
return false;
|
||||
|
||||
// Detect Asmedia ASM1083/1085.
|
||||
pcie_to_pci_bridge = pdev->bus->self;
|
||||
if (pcie_to_pci_bridge->vendor != PCI_VENDOR_ID_ASMEDIA)
|
||||
return false;
|
||||
if (pcie_to_pci_bridge->device != PCI_DEVICE_ID_ASMEDIA_ASM108X)
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
#else
|
||||
#define has_reboot_by_cycle_timer_read_quirk(ohci) false
|
||||
#define detect_vt630x_with_asm1083_on_amd_ryzen_machine(pdev) false
|
||||
#endif
|
||||
|
||||
/* In case of multiple matches in ohci_quirks[], only the first one is used. */
|
||||
static const struct {
|
||||
unsigned short vendor, device, revision, flags;
|
||||
@@ -1713,6 +1758,9 @@ static u32 get_cycle_time(struct fw_ohci *ohci)
|
||||
s32 diff01, diff12;
|
||||
int i;
|
||||
|
||||
if (has_reboot_by_cycle_timer_read_quirk(ohci))
|
||||
return 0;
|
||||
|
||||
c2 = reg_read(ohci, OHCI1394_IsochronousCycleTimer);
|
||||
|
||||
if (ohci->quirks & QUIRK_CYCLE_TIMER) {
|
||||
@@ -3615,6 +3663,9 @@ static int pci_probe(struct pci_dev *dev,
|
||||
if (param_quirks)
|
||||
ohci->quirks = param_quirks;
|
||||
|
||||
if (detect_vt630x_with_asm1083_on_amd_ryzen_machine(dev))
|
||||
ohci->quirks |= QUIRK_REBOOT_BY_CYCLE_TIMER_READ;
|
||||
|
||||
/*
|
||||
* Because dma_alloc_coherent() allocates at least one page,
|
||||
* we save space by using a common buffer for the AR request/
|
||||
|
||||
@@ -313,11 +313,14 @@ static int __init meson_sm_probe(struct platform_device *pdev)
|
||||
|
||||
platform_set_drvdata(pdev, fw);
|
||||
|
||||
pr_info("secure-monitor enabled\n");
|
||||
if (devm_of_platform_populate(dev))
|
||||
goto out_in_base;
|
||||
|
||||
if (sysfs_create_group(&pdev->dev.kobj, &meson_sm_sysfs_attr_group))
|
||||
goto out_in_base;
|
||||
|
||||
pr_info("secure-monitor enabled\n");
|
||||
|
||||
return 0;
|
||||
|
||||
out_in_base:
|
||||
|
||||
@@ -161,7 +161,7 @@ static int ti_sci_debugfs_create(struct platform_device *pdev,
|
||||
{
|
||||
struct device *dev = &pdev->dev;
|
||||
struct resource *res;
|
||||
char debug_name[50] = "ti_sci_debug@";
|
||||
char debug_name[50];
|
||||
|
||||
/* Debug region is optional */
|
||||
res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
|
||||
@@ -178,10 +178,10 @@ static int ti_sci_debugfs_create(struct platform_device *pdev,
|
||||
/* Setup NULL termination */
|
||||
info->debug_buffer[info->debug_region_size] = 0;
|
||||
|
||||
info->d = debugfs_create_file(strncat(debug_name, dev_name(dev),
|
||||
sizeof(debug_name) -
|
||||
sizeof("ti_sci_debug@")),
|
||||
0444, NULL, info, &ti_sci_debug_fops);
|
||||
snprintf(debug_name, sizeof(debug_name), "ti_sci_debug@%s",
|
||||
dev_name(dev));
|
||||
info->d = debugfs_create_file(debug_name, 0444, NULL, info,
|
||||
&ti_sci_debug_fops);
|
||||
if (IS_ERR(info->d))
|
||||
return PTR_ERR(info->d);
|
||||
|
||||
|
||||
@@ -277,13 +277,15 @@ static void dwapb_irq_enable(struct irq_data *d)
|
||||
{
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(d);
|
||||
struct dwapb_gpio *gpio = to_dwapb_gpio(gc);
|
||||
irq_hw_number_t hwirq = irqd_to_hwirq(d);
|
||||
unsigned long flags;
|
||||
u32 val;
|
||||
|
||||
raw_spin_lock_irqsave(&gc->bgpio_lock, flags);
|
||||
val = dwapb_read(gpio, GPIO_INTEN);
|
||||
val |= BIT(irqd_to_hwirq(d));
|
||||
val = dwapb_read(gpio, GPIO_INTEN) | BIT(hwirq);
|
||||
dwapb_write(gpio, GPIO_INTEN, val);
|
||||
val = dwapb_read(gpio, GPIO_INTMASK) & ~BIT(hwirq);
|
||||
dwapb_write(gpio, GPIO_INTMASK, val);
|
||||
raw_spin_unlock_irqrestore(&gc->bgpio_lock, flags);
|
||||
}
|
||||
|
||||
@@ -291,12 +293,14 @@ static void dwapb_irq_disable(struct irq_data *d)
|
||||
{
|
||||
struct gpio_chip *gc = irq_data_get_irq_chip_data(d);
|
||||
struct dwapb_gpio *gpio = to_dwapb_gpio(gc);
|
||||
irq_hw_number_t hwirq = irqd_to_hwirq(d);
|
||||
unsigned long flags;
|
||||
u32 val;
|
||||
|
||||
raw_spin_lock_irqsave(&gc->bgpio_lock, flags);
|
||||
val = dwapb_read(gpio, GPIO_INTEN);
|
||||
val &= ~BIT(irqd_to_hwirq(d));
|
||||
val = dwapb_read(gpio, GPIO_INTMASK) | BIT(hwirq);
|
||||
dwapb_write(gpio, GPIO_INTMASK, val);
|
||||
val = dwapb_read(gpio, GPIO_INTEN) & ~BIT(hwirq);
|
||||
dwapb_write(gpio, GPIO_INTEN, val);
|
||||
raw_spin_unlock_irqrestore(&gc->bgpio_lock, flags);
|
||||
}
|
||||
|
||||
@@ -2224,10 +2224,7 @@ static int lineinfo_unwatch(struct gpio_chardev_data *cdev, void __user *ip)
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* gpio_ioctl() - ioctl handler for the GPIO chardev
|
||||
*/
|
||||
static long gpio_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
||||
static long gpio_ioctl_unlocked(struct file *file, unsigned int cmd, unsigned long arg)
|
||||
{
|
||||
struct gpio_chardev_data *cdev = file->private_data;
|
||||
struct gpio_device *gdev = cdev->gdev;
|
||||
@@ -2264,6 +2261,17 @@ static long gpio_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gpio_ioctl() - ioctl handler for the GPIO chardev
|
||||
*/
|
||||
static long gpio_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
||||
{
|
||||
struct gpio_chardev_data *cdev = file->private_data;
|
||||
|
||||
return call_ioctl_locked(file, cmd, arg, cdev->gdev,
|
||||
gpio_ioctl_unlocked);
|
||||
}
|
||||
|
||||
#ifdef CONFIG_COMPAT
|
||||
static long gpio_ioctl_compat(struct file *file, unsigned int cmd,
|
||||
unsigned long arg)
|
||||
|
||||
@@ -342,6 +342,9 @@ static ssize_t amdgpu_debugfs_regs_didt_read(struct file *f, char __user *buf,
|
||||
if (size & 0x3 || *pos & 0x3)
|
||||
return -EINVAL;
|
||||
|
||||
if (!adev->didt_rreg)
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
r = pm_runtime_get_sync(adev_to_drm(adev)->dev);
|
||||
if (r < 0) {
|
||||
pm_runtime_put_autosuspend(adev_to_drm(adev)->dev);
|
||||
@@ -401,6 +404,9 @@ static ssize_t amdgpu_debugfs_regs_didt_write(struct file *f, const char __user
|
||||
if (size & 0x3 || *pos & 0x3)
|
||||
return -EINVAL;
|
||||
|
||||
if (!adev->didt_wreg)
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
r = pm_runtime_get_sync(adev_to_drm(adev)->dev);
|
||||
if (r < 0) {
|
||||
pm_runtime_put_autosuspend(adev_to_drm(adev)->dev);
|
||||
@@ -459,7 +465,7 @@ static ssize_t amdgpu_debugfs_regs_smc_read(struct file *f, char __user *buf,
|
||||
int r;
|
||||
|
||||
if (!adev->smc_rreg)
|
||||
return -EPERM;
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
if (size & 0x3 || *pos & 0x3)
|
||||
return -EINVAL;
|
||||
@@ -521,7 +527,7 @@ static ssize_t amdgpu_debugfs_regs_smc_write(struct file *f, const char __user *
|
||||
int r;
|
||||
|
||||
if (!adev->smc_wreg)
|
||||
return -EPERM;
|
||||
return -EOPNOTSUPP;
|
||||
|
||||
if (size & 0x3 || *pos & 0x3)
|
||||
return -EINVAL;
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user