mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-07 23:20:32 -04:00
Merge branch 'master' into mm-hotfixes-stable
This commit is contained in:
@@ -542,6 +542,7 @@ int acpi_device_set_power(struct acpi_device *device, int state);
|
||||
int acpi_bus_init_power(struct acpi_device *device);
|
||||
int acpi_device_fix_up_power(struct acpi_device *device);
|
||||
void acpi_device_fix_up_power_extended(struct acpi_device *adev);
|
||||
void acpi_device_fix_up_power_children(struct acpi_device *adev);
|
||||
int acpi_bus_update_power(acpi_handle handle, int *state_p);
|
||||
int acpi_device_update_power(struct acpi_device *device, int *state_p);
|
||||
bool acpi_bus_power_manageable(acpi_handle handle);
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/* SPDX-License-Identifier: GPL-2.0 OR MIT */
|
||||
/* SPDX-License-Identifier: GPL-2.0-only OR MIT */
|
||||
|
||||
#ifndef __DRM_GPUVM_H__
|
||||
#define __DRM_GPUVM_H__
|
||||
|
||||
@@ -60,12 +60,19 @@ enum dma_data_direction;
|
||||
|
||||
struct drm_device;
|
||||
struct drm_gem_object;
|
||||
struct drm_file;
|
||||
|
||||
/* core prime functions */
|
||||
struct dma_buf *drm_gem_dmabuf_export(struct drm_device *dev,
|
||||
struct dma_buf_export_info *exp_info);
|
||||
void drm_gem_dmabuf_release(struct dma_buf *dma_buf);
|
||||
|
||||
int drm_gem_prime_fd_to_handle(struct drm_device *dev,
|
||||
struct drm_file *file_priv, int prime_fd, uint32_t *handle);
|
||||
int drm_gem_prime_handle_to_fd(struct drm_device *dev,
|
||||
struct drm_file *file_priv, uint32_t handle, uint32_t flags,
|
||||
int *prime_fd);
|
||||
|
||||
/* helper functions for exporting */
|
||||
int drm_gem_map_attach(struct dma_buf *dma_buf,
|
||||
struct dma_buf_attachment *attach);
|
||||
|
||||
@@ -15,7 +15,6 @@
|
||||
#include <linux/mod_devicetable.h>
|
||||
#include <linux/property.h>
|
||||
#include <linux/uuid.h>
|
||||
#include <linux/fw_table.h>
|
||||
|
||||
struct irq_domain;
|
||||
struct irq_domain_ops;
|
||||
@@ -25,6 +24,20 @@ struct irq_domain_ops;
|
||||
#endif
|
||||
#include <acpi/acpi.h>
|
||||
|
||||
#ifdef CONFIG_ACPI
|
||||
|
||||
#include <linux/list.h>
|
||||
#include <linux/dynamic_debug.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/mutex.h>
|
||||
#include <linux/fw_table.h>
|
||||
|
||||
#include <acpi/acpi_bus.h>
|
||||
#include <acpi/acpi_drivers.h>
|
||||
#include <acpi/acpi_numa.h>
|
||||
#include <acpi/acpi_io.h>
|
||||
#include <asm/acpi.h>
|
||||
|
||||
#ifdef CONFIG_ACPI_TABLE_LIB
|
||||
#define EXPORT_SYMBOL_ACPI_LIB(x) EXPORT_SYMBOL_NS_GPL(x, ACPI)
|
||||
#define __init_or_acpilib
|
||||
@@ -35,19 +48,6 @@ struct irq_domain_ops;
|
||||
#define __initdata_or_acpilib __initdata
|
||||
#endif
|
||||
|
||||
#ifdef CONFIG_ACPI
|
||||
|
||||
#include <linux/list.h>
|
||||
#include <linux/dynamic_debug.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/mutex.h>
|
||||
|
||||
#include <acpi/acpi_bus.h>
|
||||
#include <acpi/acpi_drivers.h>
|
||||
#include <acpi/acpi_numa.h>
|
||||
#include <acpi/acpi_io.h>
|
||||
#include <asm/acpi.h>
|
||||
|
||||
static inline acpi_handle acpi_device_handle(struct acpi_device *adev)
|
||||
{
|
||||
return adev ? adev->handle : NULL;
|
||||
|
||||
@@ -70,6 +70,10 @@ struct amd_cpudata {
|
||||
u32 nominal_perf;
|
||||
u32 lowest_nonlinear_perf;
|
||||
u32 lowest_perf;
|
||||
u32 min_limit_perf;
|
||||
u32 max_limit_perf;
|
||||
u32 min_limit_freq;
|
||||
u32 max_limit_freq;
|
||||
|
||||
u32 max_freq;
|
||||
u32 min_freq;
|
||||
|
||||
@@ -49,9 +49,10 @@ struct block_device {
|
||||
bool bd_write_holder;
|
||||
bool bd_has_submit_bio;
|
||||
dev_t bd_dev;
|
||||
struct inode *bd_inode; /* will die */
|
||||
|
||||
atomic_t bd_openers;
|
||||
spinlock_t bd_size_lock; /* for bd_inode->i_size updates */
|
||||
struct inode * bd_inode; /* will die */
|
||||
void * bd_claiming;
|
||||
void * bd_holder;
|
||||
const struct blk_holder_ops *bd_holder_ops;
|
||||
@@ -69,6 +70,7 @@ struct block_device {
|
||||
#ifdef CONFIG_FAIL_MAKE_REQUEST
|
||||
bool bd_make_it_fail;
|
||||
#endif
|
||||
bool bd_ro_warned;
|
||||
/*
|
||||
* keep this out-of-line as it's both big and not needed in the fast
|
||||
* path
|
||||
|
||||
@@ -104,7 +104,7 @@
|
||||
|
||||
struct closure;
|
||||
struct closure_syncer;
|
||||
typedef void (closure_fn) (struct closure *);
|
||||
typedef void (closure_fn) (struct work_struct *);
|
||||
extern struct dentry *bcache_debug;
|
||||
|
||||
struct closure_waitlist {
|
||||
@@ -254,7 +254,7 @@ static inline void closure_queue(struct closure *cl)
|
||||
INIT_WORK(&cl->work, cl->work.func);
|
||||
BUG_ON(!queue_work(wq, &cl->work));
|
||||
} else
|
||||
cl->fn(cl);
|
||||
cl->fn(&cl->work);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -309,6 +309,11 @@ static inline void closure_wake_up(struct closure_waitlist *list)
|
||||
__closure_wake_up(list);
|
||||
}
|
||||
|
||||
#define CLOSURE_CALLBACK(name) void name(struct work_struct *ws)
|
||||
#define closure_type(name, type, member) \
|
||||
struct closure *cl = container_of(ws, struct closure, work); \
|
||||
type *name = container_of(cl, type, member)
|
||||
|
||||
/**
|
||||
* continue_at - jump to another function with barrier
|
||||
*
|
||||
|
||||
@@ -171,6 +171,25 @@ ssize_t debugfs_write_file_bool(struct file *file, const char __user *user_buf,
|
||||
ssize_t debugfs_read_file_str(struct file *file, char __user *user_buf,
|
||||
size_t count, loff_t *ppos);
|
||||
|
||||
/**
|
||||
* struct debugfs_cancellation - cancellation data
|
||||
* @list: internal, for keeping track
|
||||
* @cancel: callback to call
|
||||
* @cancel_data: extra data for the callback to call
|
||||
*/
|
||||
struct debugfs_cancellation {
|
||||
struct list_head list;
|
||||
void (*cancel)(struct dentry *, void *);
|
||||
void *cancel_data;
|
||||
};
|
||||
|
||||
void __acquires(cancellation)
|
||||
debugfs_enter_cancellation(struct file *file,
|
||||
struct debugfs_cancellation *cancellation);
|
||||
void __releases(cancellation)
|
||||
debugfs_leave_cancellation(struct file *file,
|
||||
struct debugfs_cancellation *cancellation);
|
||||
|
||||
#else
|
||||
|
||||
#include <linux/err.h>
|
||||
|
||||
@@ -498,6 +498,21 @@ static inline bool dma_fence_is_later(struct dma_fence *f1,
|
||||
return __dma_fence_is_later(f1->seqno, f2->seqno, f1->ops);
|
||||
}
|
||||
|
||||
/**
|
||||
* dma_fence_is_later_or_same - return true if f1 is later or same as f2
|
||||
* @f1: the first fence from the same context
|
||||
* @f2: the second fence from the same context
|
||||
*
|
||||
* Returns true if f1 is chronologically later than f2 or the same fence. Both
|
||||
* fences must be from the same context, since a seqno is not re-used across
|
||||
* contexts.
|
||||
*/
|
||||
static inline bool dma_fence_is_later_or_same(struct dma_fence *f1,
|
||||
struct dma_fence *f2)
|
||||
{
|
||||
return f1 == f2 || dma_fence_is_later(f1, f2);
|
||||
}
|
||||
|
||||
/**
|
||||
* dma_fence_later - return the chronologically later fence
|
||||
* @f1: the first fence from the same context
|
||||
|
||||
@@ -25,9 +25,6 @@ struct acpi_subtable_proc {
|
||||
int count;
|
||||
};
|
||||
|
||||
#include <linux/acpi.h>
|
||||
#include <acpi/acpi.h>
|
||||
|
||||
union acpi_subtable_headers {
|
||||
struct acpi_subtable_header common;
|
||||
struct acpi_hmat_structure hmat;
|
||||
|
||||
@@ -2830,12 +2830,14 @@ ieee80211_he_oper_size(const u8 *he_oper_ie)
|
||||
static inline const struct ieee80211_he_6ghz_oper *
|
||||
ieee80211_he_6ghz_oper(const struct ieee80211_he_operation *he_oper)
|
||||
{
|
||||
const u8 *ret = (const void *)&he_oper->optional;
|
||||
const u8 *ret;
|
||||
u32 he_oper_params;
|
||||
|
||||
if (!he_oper)
|
||||
return NULL;
|
||||
|
||||
ret = (const void *)&he_oper->optional;
|
||||
|
||||
he_oper_params = le32_to_cpu(he_oper->he_oper_params);
|
||||
|
||||
if (!(he_oper_params & IEEE80211_HE_OPERATION_6GHZ_OP_INFO))
|
||||
|
||||
@@ -340,6 +340,9 @@ struct io_ring_ctx {
|
||||
|
||||
struct list_head io_buffers_cache;
|
||||
|
||||
/* deferred free list, protected by ->uring_lock */
|
||||
struct hlist_head io_buf_list;
|
||||
|
||||
/* Keep this last, we don't need it for the fast path */
|
||||
struct wait_queue_head poll_wq;
|
||||
struct io_restriction restrictions;
|
||||
|
||||
@@ -845,6 +845,7 @@ static inline void dev_iommu_priv_set(struct device *dev, void *priv)
|
||||
dev->iommu->priv = priv;
|
||||
}
|
||||
|
||||
extern struct mutex iommu_probe_device_lock;
|
||||
int iommu_probe_device(struct device *dev);
|
||||
|
||||
int iommu_dev_enable_feature(struct device *dev, enum iommu_dev_features f);
|
||||
|
||||
@@ -139,7 +139,7 @@ static inline bool kprobe_ftrace(struct kprobe *p)
|
||||
*
|
||||
*/
|
||||
struct kretprobe_holder {
|
||||
struct kretprobe *rp;
|
||||
struct kretprobe __rcu *rp;
|
||||
struct objpool_head pool;
|
||||
};
|
||||
|
||||
@@ -197,10 +197,8 @@ extern int arch_trampoline_kprobe(struct kprobe *p);
|
||||
#ifdef CONFIG_KRETPROBE_ON_RETHOOK
|
||||
static nokprobe_inline struct kretprobe *get_kretprobe(struct kretprobe_instance *ri)
|
||||
{
|
||||
RCU_LOCKDEP_WARN(!rcu_read_lock_any_held(),
|
||||
"Kretprobe is accessed from instance under preemptive context");
|
||||
|
||||
return (struct kretprobe *)READ_ONCE(ri->node.rethook->data);
|
||||
/* rethook::data is non-changed field, so that you can access it freely. */
|
||||
return (struct kretprobe *)ri->node.rethook->data;
|
||||
}
|
||||
static nokprobe_inline unsigned long get_kretprobe_retaddr(struct kretprobe_instance *ri)
|
||||
{
|
||||
@@ -245,10 +243,7 @@ unsigned long kretprobe_trampoline_handler(struct pt_regs *regs,
|
||||
|
||||
static nokprobe_inline struct kretprobe *get_kretprobe(struct kretprobe_instance *ri)
|
||||
{
|
||||
RCU_LOCKDEP_WARN(!rcu_read_lock_any_held(),
|
||||
"Kretprobe is accessed from instance under preemptive context");
|
||||
|
||||
return READ_ONCE(ri->rph->rp);
|
||||
return rcu_dereference_check(ri->rph->rp, rcu_read_lock_any_held());
|
||||
}
|
||||
|
||||
static nokprobe_inline unsigned long get_kretprobe_retaddr(struct kretprobe_instance *ri)
|
||||
|
||||
@@ -28,7 +28,12 @@ typedef void (*rethook_handler_t) (struct rethook_node *, void *, unsigned long,
|
||||
*/
|
||||
struct rethook {
|
||||
void *data;
|
||||
rethook_handler_t handler;
|
||||
/*
|
||||
* To avoid sparse warnings, this uses a raw function pointer with
|
||||
* __rcu, instead of rethook_handler_t. But this must be same as
|
||||
* rethook_handler_t.
|
||||
*/
|
||||
void (__rcu *handler) (struct rethook_node *, void *, unsigned long, struct pt_regs *);
|
||||
struct objpool_head pool;
|
||||
struct rcu_head rcu;
|
||||
};
|
||||
|
||||
@@ -106,6 +106,7 @@ struct sk_psock {
|
||||
struct mutex work_mutex;
|
||||
struct sk_psock_work_state work_state;
|
||||
struct delayed_work work;
|
||||
struct sock *sk_pair;
|
||||
struct rcu_work rwork;
|
||||
};
|
||||
|
||||
|
||||
@@ -144,10 +144,6 @@ struct usb_phy {
|
||||
*/
|
||||
int (*set_wakeup)(struct usb_phy *x, bool enabled);
|
||||
|
||||
/* notify phy port status change */
|
||||
int (*notify_port_status)(struct usb_phy *x, int port,
|
||||
u16 portstatus, u16 portchange);
|
||||
|
||||
/* notify phy connect status change */
|
||||
int (*notify_connect)(struct usb_phy *x,
|
||||
enum usb_device_speed speed);
|
||||
@@ -320,15 +316,6 @@ usb_phy_set_wakeup(struct usb_phy *x, bool enabled)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline int
|
||||
usb_phy_notify_port_status(struct usb_phy *x, int port, u16 portstatus, u16 portchange)
|
||||
{
|
||||
if (x && x->notify_port_status)
|
||||
return x->notify_port_status(x, port, portstatus, portchange);
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
|
||||
static inline int
|
||||
usb_phy_notify_connect(struct usb_phy *x, enum usb_device_speed speed)
|
||||
{
|
||||
|
||||
@@ -289,16 +289,12 @@ void vfio_combine_iova_ranges(struct rb_root_cached *root, u32 cur_nodes,
|
||||
/*
|
||||
* External user API
|
||||
*/
|
||||
#if IS_ENABLED(CONFIG_VFIO_GROUP)
|
||||
struct iommu_group *vfio_file_iommu_group(struct file *file);
|
||||
|
||||
#if IS_ENABLED(CONFIG_VFIO_GROUP)
|
||||
bool vfio_file_is_group(struct file *file);
|
||||
bool vfio_file_has_dev(struct file *file, struct vfio_device *device);
|
||||
#else
|
||||
static inline struct iommu_group *vfio_file_iommu_group(struct file *file)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static inline bool vfio_file_is_group(struct file *file)
|
||||
{
|
||||
return false;
|
||||
|
||||
@@ -75,6 +75,7 @@ struct unix_sock {
|
||||
};
|
||||
|
||||
#define unix_sk(ptr) container_of_const(ptr, struct unix_sock, sk)
|
||||
#define unix_peer(sk) (unix_sk(sk)->peer)
|
||||
|
||||
#define peer_wait peer_wq.wait
|
||||
|
||||
|
||||
@@ -9299,4 +9299,50 @@ bool cfg80211_valid_disable_subchannel_bitmap(u16 *bitmap,
|
||||
*/
|
||||
void cfg80211_links_removed(struct net_device *dev, u16 link_mask);
|
||||
|
||||
#ifdef CONFIG_CFG80211_DEBUGFS
|
||||
/**
|
||||
* wiphy_locked_debugfs_read - do a locked read in debugfs
|
||||
* @wiphy: the wiphy to use
|
||||
* @file: the file being read
|
||||
* @buf: the buffer to fill and then read from
|
||||
* @bufsize: size of the buffer
|
||||
* @userbuf: the user buffer to copy to
|
||||
* @count: read count
|
||||
* @ppos: read position
|
||||
* @handler: the read handler to call (under wiphy lock)
|
||||
* @data: additional data to pass to the read handler
|
||||
*/
|
||||
ssize_t wiphy_locked_debugfs_read(struct wiphy *wiphy, struct file *file,
|
||||
char *buf, size_t bufsize,
|
||||
char __user *userbuf, size_t count,
|
||||
loff_t *ppos,
|
||||
ssize_t (*handler)(struct wiphy *wiphy,
|
||||
struct file *file,
|
||||
char *buf,
|
||||
size_t bufsize,
|
||||
void *data),
|
||||
void *data);
|
||||
|
||||
/**
|
||||
* wiphy_locked_debugfs_write - do a locked write in debugfs
|
||||
* @wiphy: the wiphy to use
|
||||
* @file: the file being written to
|
||||
* @buf: the buffer to copy the user data to
|
||||
* @bufsize: size of the buffer
|
||||
* @userbuf: the user buffer to copy from
|
||||
* @count: read count
|
||||
* @handler: the write handler to call (under wiphy lock)
|
||||
* @data: additional data to pass to the write handler
|
||||
*/
|
||||
ssize_t wiphy_locked_debugfs_write(struct wiphy *wiphy, struct file *file,
|
||||
char *buf, size_t bufsize,
|
||||
const char __user *userbuf, size_t count,
|
||||
ssize_t (*handler)(struct wiphy *wiphy,
|
||||
struct file *file,
|
||||
char *buf,
|
||||
size_t count,
|
||||
void *data),
|
||||
void *data);
|
||||
#endif
|
||||
|
||||
#endif /* __NET_CFG80211_H */
|
||||
|
||||
@@ -162,7 +162,7 @@ struct neighbour {
|
||||
struct rcu_head rcu;
|
||||
struct net_device *dev;
|
||||
netdevice_tracker dev_tracker;
|
||||
u8 primary_key[0];
|
||||
u8 primary_key[];
|
||||
} __randomize_layout;
|
||||
|
||||
struct neigh_ops {
|
||||
|
||||
@@ -167,19 +167,25 @@ struct scsi_device {
|
||||
* power state for system suspend/resume (suspend to RAM and
|
||||
* hibernation) operations.
|
||||
*/
|
||||
bool manage_system_start_stop;
|
||||
unsigned manage_system_start_stop:1;
|
||||
|
||||
/*
|
||||
* If true, let the high-level device driver (sd) manage the device
|
||||
* power state for runtime device suspand and resume operations.
|
||||
*/
|
||||
bool manage_runtime_start_stop;
|
||||
unsigned manage_runtime_start_stop:1;
|
||||
|
||||
/*
|
||||
* If true, let the high-level device driver (sd) manage the device
|
||||
* power state for system shutdown (power off) operations.
|
||||
*/
|
||||
bool manage_shutdown;
|
||||
unsigned manage_shutdown:1;
|
||||
|
||||
/*
|
||||
* If set and if the device is runtime suspended, ask the high-level
|
||||
* device driver (sd) to force a runtime resume of the device.
|
||||
*/
|
||||
unsigned force_runtime_start_on_system_start:1;
|
||||
|
||||
unsigned removable:1;
|
||||
unsigned changed:1; /* Data invalid due to media change */
|
||||
|
||||
@@ -906,6 +906,6 @@ int cs35l41_init_boost(struct device *dev, struct regmap *regmap,
|
||||
bool cs35l41_safe_reset(struct regmap *regmap, enum cs35l41_boost_type b_type);
|
||||
int cs35l41_mdsync_up(struct regmap *regmap);
|
||||
int cs35l41_global_enable(struct device *dev, struct regmap *regmap, enum cs35l41_boost_type b_type,
|
||||
int enable, bool firmware_running);
|
||||
int enable, struct cs_dsp *dsp);
|
||||
|
||||
#endif /* __CS35L41_H */
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
union { \
|
||||
struct { MEMBERS } ATTRS; \
|
||||
struct TAG { MEMBERS } ATTRS NAME; \
|
||||
}
|
||||
} ATTRS
|
||||
|
||||
#ifdef __cplusplus
|
||||
/* sizeof(struct{}) is 1 in C++, not 0, can't use C version of the macro. */
|
||||
|
||||
@@ -239,7 +239,7 @@ struct v4l2_subdev_routing {
|
||||
* set (which is the default), the 'stream' fields will be forced to 0 by the
|
||||
* kernel.
|
||||
*/
|
||||
#define V4L2_SUBDEV_CLIENT_CAP_STREAMS (1U << 0)
|
||||
#define V4L2_SUBDEV_CLIENT_CAP_STREAMS (1ULL << 0)
|
||||
|
||||
/**
|
||||
* struct v4l2_subdev_client_capability - Capabilities of the client accessing
|
||||
|
||||
Reference in New Issue
Block a user