mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/
synced 2026-04-23 08:55:56 -04:00
drm/i915: move and group fbdev under display.fbdev
Move display fbdev related members under drm_i915_private display sub-struct. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com> Reviewed-by: Arun R Murthy <arun.r.murthy@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/7eb563bc88623bd3f12b9a00efec85e6a78d5800.1661346845.git.jani.nikula@intel.com
This commit is contained in:
@@ -500,7 +500,7 @@ static void intel_fbdev_suspend_worker(struct work_struct *work)
|
||||
{
|
||||
intel_fbdev_set_suspend(&container_of(work,
|
||||
struct drm_i915_private,
|
||||
fbdev_suspend_work)->drm,
|
||||
display.fbdev.suspend_work)->drm,
|
||||
FBINFO_STATE_RUNNING,
|
||||
true);
|
||||
}
|
||||
@@ -530,8 +530,8 @@ int intel_fbdev_init(struct drm_device *dev)
|
||||
return ret;
|
||||
}
|
||||
|
||||
dev_priv->fbdev = ifbdev;
|
||||
INIT_WORK(&dev_priv->fbdev_suspend_work, intel_fbdev_suspend_worker);
|
||||
dev_priv->display.fbdev.fbdev = ifbdev;
|
||||
INIT_WORK(&dev_priv->display.fbdev.suspend_work, intel_fbdev_suspend_worker);
|
||||
|
||||
return 0;
|
||||
}
|
||||
@@ -548,7 +548,7 @@ static void intel_fbdev_initial_config(void *data, async_cookie_t cookie)
|
||||
|
||||
void intel_fbdev_initial_config_async(struct drm_device *dev)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->fbdev;
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->display.fbdev.fbdev;
|
||||
|
||||
if (!ifbdev)
|
||||
return;
|
||||
@@ -568,12 +568,12 @@ static void intel_fbdev_sync(struct intel_fbdev *ifbdev)
|
||||
|
||||
void intel_fbdev_unregister(struct drm_i915_private *dev_priv)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = dev_priv->fbdev;
|
||||
struct intel_fbdev *ifbdev = dev_priv->display.fbdev.fbdev;
|
||||
|
||||
if (!ifbdev)
|
||||
return;
|
||||
|
||||
cancel_work_sync(&dev_priv->fbdev_suspend_work);
|
||||
cancel_work_sync(&dev_priv->display.fbdev.suspend_work);
|
||||
if (!current_is_async())
|
||||
intel_fbdev_sync(ifbdev);
|
||||
|
||||
@@ -582,7 +582,7 @@ void intel_fbdev_unregister(struct drm_i915_private *dev_priv)
|
||||
|
||||
void intel_fbdev_fini(struct drm_i915_private *dev_priv)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = fetch_and_zero(&dev_priv->fbdev);
|
||||
struct intel_fbdev *ifbdev = fetch_and_zero(&dev_priv->display.fbdev.fbdev);
|
||||
|
||||
if (!ifbdev)
|
||||
return;
|
||||
@@ -596,7 +596,7 @@ void intel_fbdev_fini(struct drm_i915_private *dev_priv)
|
||||
*/
|
||||
static void intel_fbdev_hpd_set_suspend(struct drm_i915_private *i915, int state)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = i915->fbdev;
|
||||
struct intel_fbdev *ifbdev = i915->display.fbdev.fbdev;
|
||||
bool send_hpd = false;
|
||||
|
||||
mutex_lock(&ifbdev->hpd_lock);
|
||||
@@ -614,7 +614,7 @@ static void intel_fbdev_hpd_set_suspend(struct drm_i915_private *i915, int state
|
||||
void intel_fbdev_set_suspend(struct drm_device *dev, int state, bool synchronous)
|
||||
{
|
||||
struct drm_i915_private *dev_priv = to_i915(dev);
|
||||
struct intel_fbdev *ifbdev = dev_priv->fbdev;
|
||||
struct intel_fbdev *ifbdev = dev_priv->display.fbdev.fbdev;
|
||||
struct fb_info *info;
|
||||
|
||||
if (!ifbdev || !ifbdev->vma)
|
||||
@@ -631,7 +631,7 @@ void intel_fbdev_set_suspend(struct drm_device *dev, int state, bool synchronous
|
||||
* ourselves, so only flush outstanding work upon suspend!
|
||||
*/
|
||||
if (state != FBINFO_STATE_RUNNING)
|
||||
flush_work(&dev_priv->fbdev_suspend_work);
|
||||
flush_work(&dev_priv->display.fbdev.suspend_work);
|
||||
|
||||
console_lock();
|
||||
} else {
|
||||
@@ -645,7 +645,7 @@ void intel_fbdev_set_suspend(struct drm_device *dev, int state, bool synchronous
|
||||
/* Don't block our own workqueue as this can
|
||||
* be run in parallel with other i915.ko tasks.
|
||||
*/
|
||||
schedule_work(&dev_priv->fbdev_suspend_work);
|
||||
schedule_work(&dev_priv->display.fbdev.suspend_work);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -666,7 +666,7 @@ void intel_fbdev_set_suspend(struct drm_device *dev, int state, bool synchronous
|
||||
|
||||
void intel_fbdev_output_poll_changed(struct drm_device *dev)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->fbdev;
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->display.fbdev.fbdev;
|
||||
bool send_hpd;
|
||||
|
||||
if (!ifbdev)
|
||||
@@ -685,7 +685,7 @@ void intel_fbdev_output_poll_changed(struct drm_device *dev)
|
||||
|
||||
void intel_fbdev_restore_mode(struct drm_device *dev)
|
||||
{
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->fbdev;
|
||||
struct intel_fbdev *ifbdev = to_i915(dev)->display.fbdev.fbdev;
|
||||
|
||||
if (!ifbdev)
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user