sync
This commit is contained in:
parent
f609457dcf
commit
62073e0295
318 changed files with 8112 additions and 4346 deletions
12
sys/dev/pci/drm/include/linux/apple-gmux.h
Normal file
12
sys/dev/pci/drm/include/linux/apple-gmux.h
Normal file
|
@ -0,0 +1,12 @@
|
|||
/* Public domain. */
|
||||
|
||||
#ifndef _LINUX_APPLE_GMUX_H
|
||||
#define _LINUX_APPLE_GMUX_H
|
||||
|
||||
static inline bool
|
||||
apple_gmux_detect(void *a, void *b)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
#endif
|
|
@ -2,7 +2,7 @@
|
|||
/**
|
||||
* \file drm_atomic.h
|
||||
* Atomic operations used in the DRM which may or may not be provided by the OS.
|
||||
*
|
||||
*
|
||||
* \author Eric Anholt <anholt@FreeBSD.org>
|
||||
*/
|
||||
|
||||
|
@ -298,7 +298,7 @@ __test_and_set_bit(u_int b, volatile void *p)
|
|||
volatile u_int *ptr = (volatile u_int *)p;
|
||||
unsigned int prev = ptr[b >> 5];
|
||||
ptr[b >> 5] |= m;
|
||||
|
||||
|
||||
return (prev & m) != 0;
|
||||
}
|
||||
|
||||
|
@ -428,7 +428,7 @@ find_next_bit(const volatile void *p, int max, int b)
|
|||
#define wmb() __membar("dsb sy")
|
||||
#define mb() __membar("dsb sy")
|
||||
#elif defined(__mips64__)
|
||||
#define rmb() mips_sync()
|
||||
#define rmb() mips_sync()
|
||||
#define wmb() mips_sync()
|
||||
#define mb() mips_sync()
|
||||
#elif defined(__powerpc64__)
|
||||
|
|
|
@ -12,8 +12,8 @@
|
|||
#define CAP_SYS_NICE 0x2
|
||||
|
||||
static inline bool
|
||||
capable(int cap)
|
||||
{
|
||||
capable(int cap)
|
||||
{
|
||||
switch (cap) {
|
||||
case CAP_SYS_ADMIN:
|
||||
case CAP_SYS_NICE:
|
||||
|
@ -21,7 +21,7 @@ capable(int cap)
|
|||
default:
|
||||
panic("unhandled capability");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static inline bool
|
||||
perfmon_capable(void)
|
||||
|
|
|
@ -61,7 +61,7 @@ struct dma_buf_export_info {
|
|||
struct dma_resv *resv;
|
||||
};
|
||||
|
||||
#define DEFINE_DMA_BUF_EXPORT_INFO(x) struct dma_buf_export_info x
|
||||
#define DEFINE_DMA_BUF_EXPORT_INFO(x) struct dma_buf_export_info x
|
||||
|
||||
struct dma_buf *dma_buf_export(const struct dma_buf_export_info *);
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
#define _LINUX_FILE_H
|
||||
|
||||
/* both for printf */
|
||||
#include <sys/types.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/systm.h>
|
||||
|
||||
void fd_install(int, struct file *);
|
||||
|
|
|
@ -106,7 +106,7 @@ tasklet_hi_schedule(struct tasklet_struct *ts)
|
|||
task_add(taskletq, &ts->task);
|
||||
}
|
||||
|
||||
static inline void
|
||||
static inline void
|
||||
tasklet_disable_nosync(struct tasklet_struct *ts)
|
||||
{
|
||||
atomic_inc(&ts->count);
|
||||
|
|
|
@ -119,7 +119,7 @@ static inline u32
|
|||
ioread32(const volatile void __iomem *addr)
|
||||
{
|
||||
uint32_t val;
|
||||
|
||||
|
||||
iobarrier();
|
||||
val = lemtoh32(addr);
|
||||
rmb();
|
||||
|
|
|
@ -135,7 +135,7 @@ pci_read_config_dword(struct pci_dev *pdev, int reg, u32 *val)
|
|||
{
|
||||
*val = pci_conf_read(pdev->pc, pdev->tag, reg);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static inline int
|
||||
pci_read_config_word(struct pci_dev *pdev, int reg, u16 *val)
|
||||
|
@ -145,7 +145,7 @@ pci_read_config_word(struct pci_dev *pdev, int reg, u16 *val)
|
|||
v = pci_conf_read(pdev->pc, pdev->tag, (reg & ~0x2));
|
||||
*val = (v >> ((reg & 0x2) * 8));
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static inline int
|
||||
pci_read_config_byte(struct pci_dev *pdev, int reg, u8 *val)
|
||||
|
@ -155,14 +155,14 @@ pci_read_config_byte(struct pci_dev *pdev, int reg, u8 *val)
|
|||
v = pci_conf_read(pdev->pc, pdev->tag, (reg & ~0x3));
|
||||
*val = (v >> ((reg & 0x3) * 8));
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static inline int
|
||||
pci_write_config_dword(struct pci_dev *pdev, int reg, u32 val)
|
||||
{
|
||||
pci_conf_write(pdev->pc, pdev->tag, reg, val);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static inline int
|
||||
pci_write_config_word(struct pci_dev *pdev, int reg, u16 val)
|
||||
|
@ -174,7 +174,7 @@ pci_write_config_word(struct pci_dev *pdev, int reg, u16 val)
|
|||
v |= (val << ((reg & 0x2) * 8));
|
||||
pci_conf_write(pdev->pc, pdev->tag, (reg & ~0x2), v);
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static inline int
|
||||
pci_write_config_byte(struct pci_dev *pdev, int reg, u8 val)
|
||||
|
@ -319,7 +319,7 @@ static inline int
|
|||
pcie_set_readrq(struct pci_dev *pdev, int rrq)
|
||||
{
|
||||
uint16_t val;
|
||||
|
||||
|
||||
pcie_capability_read_word(pdev, PCI_PCIE_DCSR, &val);
|
||||
val &= ~PCI_PCIE_DCSR_MPS;
|
||||
val |= (ffs(rrq) - 8) << 12;
|
||||
|
|
|
@ -99,7 +99,7 @@ __rb_deepest_left(struct rb_node *node)
|
|||
else
|
||||
node = RB_RIGHT(node, __entry);
|
||||
}
|
||||
return parent;
|
||||
return parent;
|
||||
}
|
||||
|
||||
static inline struct rb_node *
|
||||
|
|
|
@ -77,7 +77,7 @@ static inline bool
|
|||
__sg_page_iter_next(struct sg_page_iter *iter)
|
||||
{
|
||||
iter->sg_pgoffset++;
|
||||
while (iter->__nents > 0 &&
|
||||
while (iter->__nents > 0 &&
|
||||
iter->sg_pgoffset >= (iter->sg->length / PAGE_SIZE)) {
|
||||
iter->sg_pgoffset -= (iter->sg->length / PAGE_SIZE);
|
||||
iter->sg++;
|
||||
|
|
|
@ -91,7 +91,7 @@ typedef struct {
|
|||
|
||||
static inline void
|
||||
seqlock_init(seqlock_t *sl, int wantipl)
|
||||
{
|
||||
{
|
||||
sl->seq = 0;
|
||||
mtx_init(&sl->lock, wantipl);
|
||||
}
|
||||
|
|
|
@ -74,7 +74,7 @@ match_string(const char * const *array, size_t n, const char *str)
|
|||
for (i = 0; i < n; i++) {
|
||||
if (array[i] == NULL)
|
||||
break;
|
||||
if (!strcmp(array[i], str))
|
||||
if (!strcmp(array[i], str))
|
||||
return i;
|
||||
}
|
||||
|
||||
|
|
|
@ -30,11 +30,11 @@
|
|||
|
||||
static inline long
|
||||
get_nr_swap_pages(void)
|
||||
{
|
||||
{
|
||||
return uvmexp.swpages - uvmexp.swpginuse;
|
||||
}
|
||||
|
||||
/*
|
||||
/*
|
||||
* XXX For now, we don't want the shrinker to be too aggressive, so
|
||||
* pretend we're not called from the pagedaemon even if we are.
|
||||
*/
|
||||
|
|
|
@ -30,12 +30,12 @@ typedef uint32_t u32;
|
|||
typedef int64_t s64;
|
||||
typedef uint64_t u64;
|
||||
|
||||
typedef uint16_t __le16;
|
||||
typedef uint16_t __be16;
|
||||
typedef uint32_t __le32;
|
||||
typedef uint16_t __le16;
|
||||
typedef uint16_t __be16;
|
||||
typedef uint32_t __le32;
|
||||
typedef uint32_t __be32;
|
||||
typedef uint64_t __le64;
|
||||
typedef uint64_t __be64;
|
||||
typedef uint64_t __le64;
|
||||
typedef uint64_t __be64;
|
||||
|
||||
typedef bus_addr_t dma_addr_t;
|
||||
typedef paddr_t phys_addr_t;
|
||||
|
|
|
@ -221,7 +221,7 @@ wake_up(wait_queue_head_t *wqh)
|
|||
wait_queue_entry_t *wqe;
|
||||
wait_queue_entry_t *tmp;
|
||||
mtx_enter(&wqh->lock);
|
||||
|
||||
|
||||
list_for_each_entry_safe(wqe, tmp, &wqh->head, entry) {
|
||||
KASSERT(wqe->func != NULL);
|
||||
if (wqe->func != NULL)
|
||||
|
@ -255,7 +255,7 @@ wake_up_all_locked(wait_queue_head_t *wqh)
|
|||
.private = curproc, \
|
||||
.func = autoremove_wake_function, \
|
||||
.entry = LIST_HEAD_INIT((name).entry), \
|
||||
}
|
||||
}
|
||||
|
||||
static inline void
|
||||
prepare_to_wait(wait_queue_head_t *wqh, wait_queue_entry_t *wqe, int state)
|
||||
|
|
|
@ -209,7 +209,7 @@ static inline int
|
|||
ww_mutex_lock(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) {
|
||||
return __ww_mutex_lock(lock, ctx, false, false);
|
||||
}
|
||||
|
||||
|
||||
static inline void
|
||||
ww_mutex_lock_slow(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) {
|
||||
(void)__ww_mutex_lock(lock, ctx, true, false);
|
||||
|
@ -219,7 +219,7 @@ static inline int
|
|||
ww_mutex_lock_interruptible(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) {
|
||||
return __ww_mutex_lock(lock, ctx, false, true);
|
||||
}
|
||||
|
||||
|
||||
static inline int __must_check
|
||||
ww_mutex_lock_slow_interruptible(struct ww_mutex *lock, struct ww_acquire_ctx *ctx) {
|
||||
return __ww_mutex_lock(lock, ctx, true, true);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue