mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-04-24 14:07:52 -04:00
console: Use explicit pointer type for vc_uni_pagedir* fields
The vc_data.vc_uni_pagedir filed is currently long int, supposedly to be served generically. This, however, leads to lots of cast to pointer, and rather it worsens the readability significantly. Actually, we have now only a single uni_pagedir map implementation, and this won't change likely. So, it'd be much more simple and error-prone to just use the exact pointer for struct uni_pagedir instead of long. Ditto for vc_uni_pagedir_loc. It's a pointer to the uni_pagedir, thus it can be changed similarly to the exact type. Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
0f2893f0d1
commit
e4bdab70dd
4 changed files with 25 additions and 24 deletions
|
@ -17,6 +17,7 @@
|
|||
#include <linux/workqueue.h>
|
||||
|
||||
struct vt_struct;
|
||||
struct uni_pagedir;
|
||||
|
||||
#define NPAR 16
|
||||
|
||||
|
@ -104,8 +105,8 @@ struct vc_data {
|
|||
unsigned int vc_bell_pitch; /* Console bell pitch */
|
||||
unsigned int vc_bell_duration; /* Console bell duration */
|
||||
struct vc_data **vc_display_fg; /* [!] Ptr to var holding fg console for this display */
|
||||
unsigned long vc_uni_pagedir;
|
||||
unsigned long *vc_uni_pagedir_loc; /* [!] Location of uni_pagedir variable for this console */
|
||||
struct uni_pagedir *vc_uni_pagedir;
|
||||
struct uni_pagedir **vc_uni_pagedir_loc; /* [!] Location of uni_pagedir variable for this console */
|
||||
bool vc_panic_force_write; /* when oops/panic this VC can accept forced output/blanking */
|
||||
/* additional information is in vt_kern.h */
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue