mirror of
				https://github.com/torvalds/linux.git
				synced 2025-11-04 10:40:15 +02:00 
			
		
		
		
	fbcon: Fix typo and bogus logic in get_default_font
Reported in: Bugzilla Bug 8727 Fix typo and bogus logic in get_default_font(). The bug results in get_default_font() returning a font that may not be displayed properly by a framebuffer driver. Signed-off-by: Antonino Daplas <adaplas@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
		
							parent
							
								
									bb029c67e4
								
							
						
					
					
						commit
						c81f717cb9
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
					@ -133,8 +133,8 @@ const struct font_desc *get_default_font(int xres, int yres, u32 font_w,
 | 
				
			||||||
	if ((yres < 400) == (f->height <= 8))
 | 
						if ((yres < 400) == (f->height <= 8))
 | 
				
			||||||
	    c += 1000;
 | 
						    c += 1000;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (!(font_w & (1 << (f->width - 1))) ||
 | 
						if ((font_w & (1 << (f->width - 1))) &&
 | 
				
			||||||
	    !(font_w & (1 << (f->height - 1))))
 | 
						    (font_h & (1 << (f->height - 1))))
 | 
				
			||||||
	    c += 1000;
 | 
						    c += 1000;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (c > cc) {
 | 
						if (c > cc) {
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in a new issue