Short summary of fixes pull:
- i915: Fix applying placement flags - fbdev: Fix build on PowerMacs after header cleanup -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEchf7rIzpz2NEoWjlaA3BHVMLeiMFAmXptvEACgkQaA3BHVML eiPY3wgAhbc4uC/BupzWLnuO+ENQcQdpy9JERqmsBGdFge8LljElWINjzK3oSEDI dvIJ0+pPaPKDGh8nBAHwQ8hA93DmpWx3cuaYRLdX1IUi5+sImy5w+a6xHKk9uxoi EaSHnnaxLoKsy4DgA1KNLx+llc7VSkxUPCOigLE0UtL+bzEFW6E92OsCU6IP/AIY TuRu3NPbzkA6rYKfBibYzAeR4Jm9rftLG/6TGlPb+gIa7JgCAKXR+mkPcliHNWK+ W0YO5BQk6lt1dpHdj6PsAzNgMIaBuBiq1uR+ogRjQmtJIhB3h0QxiZ54fND7me0C XYB/tnxO34k2S8hTDsYUHATVGeBGAg== =JomR -----END PGP SIGNATURE----- Merge tag 'drm-misc-next-fixes-2024-03-07' of https://anongit.freedesktop.org/git/drm/drm-misc into drm-next Short summary of fixes pull: - i915: Fix applying placement flags - fbdev: Fix build on PowerMacs after header cleanup Signed-off-by: Dave Airlie <airlied@redhat.com> From: Thomas Zimmermann <tzimmermann@suse.de> Link: https://patchwork.freedesktop.org/patch/msgid/20240307124640.GA18593@localhost.localdomain
This commit is contained in:
commit
098ca7655e
@ -10,15 +10,14 @@
|
||||
#define __ASM_POWERPC_BACKLIGHT_H
|
||||
#ifdef __KERNEL__
|
||||
|
||||
#include <linux/fb.h>
|
||||
#include <linux/mutex.h>
|
||||
|
||||
struct backlight_device;
|
||||
|
||||
/* For locking instructions, see the implementation file */
|
||||
extern struct backlight_device *pmac_backlight;
|
||||
extern struct mutex pmac_backlight_mutex;
|
||||
|
||||
extern int pmac_backlight_curve_lookup(struct fb_info *info, int value);
|
||||
|
||||
extern int pmac_has_backlight_type(const char *type);
|
||||
|
||||
extern void pmac_backlight_key(int direction);
|
||||
|
@ -9,7 +9,6 @@
|
||||
*/
|
||||
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/fb.h>
|
||||
#include <linux/backlight.h>
|
||||
#include <linux/adb.h>
|
||||
#include <linux/pmu.h>
|
||||
@ -72,31 +71,6 @@ int pmac_has_backlight_type(const char *type)
|
||||
return 0;
|
||||
}
|
||||
|
||||
int pmac_backlight_curve_lookup(struct fb_info *info, int value)
|
||||
{
|
||||
int level = (FB_BACKLIGHT_LEVELS - 1);
|
||||
|
||||
if (info && info->bl_dev) {
|
||||
int i, max = 0;
|
||||
|
||||
/* Look for biggest value */
|
||||
for (i = 0; i < FB_BACKLIGHT_LEVELS; i++)
|
||||
max = max((int)info->bl_curve[i], max);
|
||||
|
||||
/* Look for nearest value */
|
||||
for (i = 0; i < FB_BACKLIGHT_LEVELS; i++) {
|
||||
int diff = abs(info->bl_curve[i] - value);
|
||||
if (diff < max) {
|
||||
max = diff;
|
||||
level = i;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return level;
|
||||
}
|
||||
|
||||
static void pmac_backlight_key_worker(struct work_struct *work)
|
||||
{
|
||||
if (atomic_read(&kernel_backlight_disabled))
|
||||
|
@ -162,10 +162,10 @@ i915_ttm_placement_from_obj(const struct drm_i915_gem_object *obj,
|
||||
unsigned int flags = obj->flags;
|
||||
unsigned int i;
|
||||
|
||||
places[0].flags |= TTM_PL_FLAG_DESIRED;
|
||||
i915_ttm_place_from_region(num_allowed ? obj->mm.placements[0] :
|
||||
obj->mm.region, &places[0], obj->bo_offset,
|
||||
obj->base.size, flags);
|
||||
places[0].flags |= TTM_PL_FLAG_DESIRED;
|
||||
|
||||
/* Cache this on object? */
|
||||
for (i = 0; i < num_allowed; ++i) {
|
||||
|
@ -10,6 +10,7 @@
|
||||
|
||||
#include <asm/ptrace.h>
|
||||
#include <linux/adb.h>
|
||||
#include <linux/backlight.h>
|
||||
#include <linux/pmu.h>
|
||||
#include <asm/backlight.h>
|
||||
|
||||
|
@ -15,6 +15,7 @@
|
||||
*/
|
||||
|
||||
#include <linux/aperture.h>
|
||||
#include <linux/backlight.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/errno.h>
|
||||
|
Loading…
x
Reference in New Issue
Block a user