Commit 7f265b00 authored by Dave Jones's avatar Dave Jones

[AGPGART] Name & Shame the apps passing bad flags.

(Basically a distinction between XFree and Xorg)
Signed-off-by: default avatarDave Jones <davej@redhat.com>
parent 5b0a5e84
...@@ -415,15 +415,15 @@ static void agp_v2_parse_one(u32 *requested_mode, u32 *bridge_agpstat, u32 *vga_ ...@@ -415,15 +415,15 @@ static void agp_v2_parse_one(u32 *requested_mode, u32 *bridge_agpstat, u32 *vga_
/* Check the speed bits make sense. Only one should be set. */ /* Check the speed bits make sense. Only one should be set. */
tmp = *requested_mode & 7; tmp = *requested_mode & 7;
if (tmp == 0) { if (tmp == 0) {
printk (KERN_INFO PFX "Userspace tried to set rate=x0. Setting to x1 mode.\n"); printk (KERN_INFO PFX "%s tried to set rate=x0. Setting to x1 mode.\n", current->comm);
*requested_mode |= AGPSTAT2_1X; *requested_mode |= AGPSTAT2_1X;
} }
if (tmp == 3) { if (tmp == 3) {
printk (KERN_INFO PFX "Userspace tried to set rate=x3. Setting to x2 mode.\n"); printk (KERN_INFO PFX "%s tried to set rate=x3. Setting to x2 mode.\n", current->comm);
*requested_mode |= AGPSTAT2_2X; *requested_mode |= AGPSTAT2_2X;
} }
if (tmp >4) { if (tmp >4) {
printk (KERN_INFO PFX "Userspace tried to set rate=x%d. Setting to x4 mode.\n", tmp); printk (KERN_INFO PFX "%s tried to set rate=x%d. Setting to x4 mode.\n", current->comm, tmp);
*requested_mode |= AGPSTAT2_4X; *requested_mode |= AGPSTAT2_4X;
} }
...@@ -470,15 +470,15 @@ static void agp_v3_parse_one(u32 *requested_mode, u32 *bridge_agpstat, u32 *vga_ ...@@ -470,15 +470,15 @@ static void agp_v3_parse_one(u32 *requested_mode, u32 *bridge_agpstat, u32 *vga_
/* Check the speed bits make sense. */ /* Check the speed bits make sense. */
tmp = *requested_mode & 7; tmp = *requested_mode & 7;
if (tmp == 0) { if (tmp == 0) {
printk (KERN_INFO PFX "Userspace tried to set rate=x0. Setting to AGP3 x4 mode.\n"); printk (KERN_INFO PFX "%s tried to set rate=x0. Setting to AGP3 x4 mode.\n", current->comm);
*requested_mode |= AGPSTAT3_4X; *requested_mode |= AGPSTAT3_4X;
} }
if (tmp == 3) { if (tmp == 3) {
printk (KERN_INFO PFX "Userspace tried to set rate=x3. Setting to AGP3 x4 mode.\n"); printk (KERN_INFO PFX "%s tried to set rate=x3. Setting to AGP3 x4 mode.\n", current->comm);
*requested_mode |= AGPSTAT3_4X; *requested_mode |= AGPSTAT3_4X;
} }
if (tmp >3) { if (tmp >3) {
printk (KERN_INFO PFX "Userspace tried to set rate=x%d. Setting to AGP3 x8 mode.\n", tmp); printk (KERN_INFO PFX "%s tried to set rate=x%d. Setting to AGP3 x8 mode.\n", current->comm, tmp);
*requested_mode |= AGPSTAT3_8X; *requested_mode |= AGPSTAT3_8X;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment