@@ -16,18 +16,13 @@ static int bochs_modeset = -1;
1616module_param_named (modeset , bochs_modeset , int , 0444 );
1717MODULE_PARM_DESC (modeset , "enable/disable kernel modesetting" );
1818
19- static bool enable_fbdev = true;
20- module_param_named (fbdev , enable_fbdev , bool , 0444 );
21- MODULE_PARM_DESC (fbdev , "register fbdev device" );
22-
2319/* ---------------------------------------------------------------------- */
2420/* drm interface */
2521
2622static void bochs_unload (struct drm_device * dev )
2723{
2824 struct bochs_device * bochs = dev -> dev_private ;
2925
30- bochs_fbdev_fini (bochs );
3126 bochs_kms_fini (bochs );
3227 bochs_mm_fini (bochs );
3328 bochs_hw_fini (dev );
@@ -58,9 +53,6 @@ static int bochs_load(struct drm_device *dev)
5853 if (ret )
5954 goto err ;
6055
61- if (enable_fbdev )
62- bochs_fbdev_init (bochs );
63-
6456 return 0 ;
6557
6658err :
@@ -110,19 +102,15 @@ static int bochs_pm_suspend(struct device *dev)
110102{
111103 struct pci_dev * pdev = to_pci_dev (dev );
112104 struct drm_device * drm_dev = pci_get_drvdata (pdev );
113- struct bochs_device * bochs = drm_dev -> dev_private ;
114105
115- drm_fb_helper_set_suspend_unlocked (& bochs -> fb .helper , 1 );
116106 return drm_mode_config_helper_suspend (drm_dev );
117107}
118108
119109static int bochs_pm_resume (struct device * dev )
120110{
121111 struct pci_dev * pdev = to_pci_dev (dev );
122112 struct drm_device * drm_dev = pci_get_drvdata (pdev );
123- struct bochs_device * bochs = drm_dev -> dev_private ;
124113
125- drm_fb_helper_set_suspend_unlocked (& bochs -> fb .helper , 0 );
126114 return drm_mode_config_helper_resume (drm_dev );
127115}
128116#endif
@@ -167,6 +155,7 @@ static int bochs_pci_probe(struct pci_dev *pdev,
167155 if (ret )
168156 goto err_unload ;
169157
158+ drm_fbdev_generic_setup (dev , 32 );
170159 return ret ;
171160
172161err_unload :
0 commit comments