Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-14 Thread Bill Davidsen
Andrew Morton wrote: Generally speaking, if sysfs file creation went wrong, it's due to a bug. The result is that the driver isn't working as intended: tunables or instrumentation which it is designed to make available are not present. We want to know about that bug asap so we can get it

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-14 Thread Bill Davidsen
Andrew Morton wrote: Generally speaking, if sysfs file creation went wrong, it's due to a bug. The result is that the driver isn't working as intended: tunables or instrumentation which it is designed to make available are not present. We want to know about that bug asap so we can get it

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
> And (ultimately) make the function return void. > > Yes, that's probably a valid approach - we've discussed it before but nobody > has > taken it further. I would have preferred that approach (with a WARN_ON rather than a BUG though). On the other hand that would make it slightly harder for

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sat, 9 Dec 2006 23:34:19 +0100 Olivier Galibert <[EMAIL PROTECTED]> wrote: > On Sat, Dec 09, 2006 at 01:58:29PM -0800, Andrew Morton wrote: > > On Sat, 9 Dec 2006 22:44:53 +0100 > > Olivier Galibert <[EMAIL PROTECTED]> wrote: > > > Hmmm, I don't understand. Which is the bug, having a sysfs

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Olivier Galibert
On Sat, Dec 09, 2006 at 01:58:29PM -0800, Andrew Morton wrote: > On Sat, 9 Dec 2006 22:44:53 +0100 > Olivier Galibert <[EMAIL PROTECTED]> wrote: > > Hmmm, I don't understand. Which is the bug, having a sysfs file > > creation fail or going on if it happens? > > Probably the former, probably the

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sat, 9 Dec 2006 22:44:53 +0100 Olivier Galibert <[EMAIL PROTECTED]> wrote: > On Sat, Dec 09, 2006 at 12:38:17PM -0800, Andrew Morton wrote: > > On Sun, 10 Dec 2006 06:59:10 +1100 > > Benjamin Herrenschmidt <[EMAIL PROTECTED]> wrote: > > > Why would I prevent the framebuffer from initializing

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Olivier Galibert
On Sat, Dec 09, 2006 at 12:38:17PM -0800, Andrew Morton wrote: > On Sun, 10 Dec 2006 06:59:10 +1100 > Benjamin Herrenschmidt <[EMAIL PROTECTED]> wrote: > > Why would I prevent the framebuffer from initializing (and thus a > > console to be displayed at all on many machines) just because for some >

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
> > Why would I prevent the framebuffer from initializing (and thus a > > console to be displayed at all on many machines) just because for some > > reason, I couldn't create a pair of EDID files in sysfs that are not > > even very useful anymore ? > > Because there's a bug in your kernel. We

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
On Sat, 2006-12-09 at 22:22 +0200, Muli Ben-Yehuda wrote: > On Sun, Dec 10, 2006 at 06:59:10AM +1100, Benjamin Herrenschmidt wrote: > > > I'd really like to have some kind of macro or attribute or whatever I > > can put on a function call to say that I'm purposefully ignoring the > > error. Is

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sun, 10 Dec 2006 06:59:10 +1100 Benjamin Herrenschmidt <[EMAIL PROTECTED]> wrote: > On Sat, 2006-12-09 at 16:56 +0100, Jean Delvare wrote: > > > Check for error on radeonfb device sysfs files creation. This fixes the > > following warnings: > > (Moving to LKML as I think that's a generic

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Muli Ben-Yehuda
On Sun, Dec 10, 2006 at 06:59:10AM +1100, Benjamin Herrenschmidt wrote: > I'd really like to have some kind of macro or attribute or whatever I > can put on a function call to say that I'm purposefully ignoring the > error. Is there some gcc magic that can do that ? (void)bla()? Cheers, Muli -

sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
On Sat, 2006-12-09 at 16:56 +0100, Jean Delvare wrote: > Check for error on radeonfb device sysfs files creation. This fixes the > following warnings: (Moving to LKML as I think that's a generic issue) As usual with most of that crap about return values from sysfs_create_file, I disagree.

sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
On Sat, 2006-12-09 at 16:56 +0100, Jean Delvare wrote: Check for error on radeonfb device sysfs files creation. This fixes the following warnings: (Moving to LKML as I think that's a generic issue) As usual with most of that crap about return values from sysfs_create_file, I disagree.

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Muli Ben-Yehuda
On Sun, Dec 10, 2006 at 06:59:10AM +1100, Benjamin Herrenschmidt wrote: I'd really like to have some kind of macro or attribute or whatever I can put on a function call to say that I'm purposefully ignoring the error. Is there some gcc magic that can do that ? (void)bla()? Cheers, Muli - To

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sun, 10 Dec 2006 06:59:10 +1100 Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: On Sat, 2006-12-09 at 16:56 +0100, Jean Delvare wrote: Check for error on radeonfb device sysfs files creation. This fixes the following warnings: (Moving to LKML as I think that's a generic issue) As

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
On Sat, 2006-12-09 at 22:22 +0200, Muli Ben-Yehuda wrote: On Sun, Dec 10, 2006 at 06:59:10AM +1100, Benjamin Herrenschmidt wrote: I'd really like to have some kind of macro or attribute or whatever I can put on a function call to say that I'm purposefully ignoring the error. Is there some

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
Why would I prevent the framebuffer from initializing (and thus a console to be displayed at all on many machines) just because for some reason, I couldn't create a pair of EDID files in sysfs that are not even very useful anymore ? Because there's a bug in your kernel. We don't hide

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Olivier Galibert
On Sat, Dec 09, 2006 at 12:38:17PM -0800, Andrew Morton wrote: On Sun, 10 Dec 2006 06:59:10 +1100 Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: Why would I prevent the framebuffer from initializing (and thus a console to be displayed at all on many machines) just because for some reason,

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sat, 9 Dec 2006 22:44:53 +0100 Olivier Galibert [EMAIL PROTECTED] wrote: On Sat, Dec 09, 2006 at 12:38:17PM -0800, Andrew Morton wrote: On Sun, 10 Dec 2006 06:59:10 +1100 Benjamin Herrenschmidt [EMAIL PROTECTED] wrote: Why would I prevent the framebuffer from initializing (and thus a

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Olivier Galibert
On Sat, Dec 09, 2006 at 01:58:29PM -0800, Andrew Morton wrote: On Sat, 9 Dec 2006 22:44:53 +0100 Olivier Galibert [EMAIL PROTECTED] wrote: Hmmm, I don't understand. Which is the bug, having a sysfs file creation fail or going on if it happens? Probably the former, probably the latter.

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Andrew Morton
On Sat, 9 Dec 2006 23:34:19 +0100 Olivier Galibert [EMAIL PROTECTED] wrote: On Sat, Dec 09, 2006 at 01:58:29PM -0800, Andrew Morton wrote: On Sat, 9 Dec 2006 22:44:53 +0100 Olivier Galibert [EMAIL PROTECTED] wrote: Hmmm, I don't understand. Which is the bug, having a sysfs file

Re: sysfs file creation result nightmare (WAS radeonfb: Fix sysfs_create_bin_file warnings)

2006-12-09 Thread Benjamin Herrenschmidt
And (ultimately) make the function return void. Yes, that's probably a valid approach - we've discussed it before but nobody has taken it further. I would have preferred that approach (with a WARN_ON rather than a BUG though). On the other hand that would make it slightly harder for the