* Re: Radeon FB troubles with recent kernels
[not found] <3xVku-kH-15@gated-at.bofh.it>
@ 2005-02-15 3:14 ` Vincent C Jones
2005-02-15 12:46 ` Benjamin Herrenschmidt
2005-02-15 12:50 ` Benjamin Herrenschmidt
0 siblings, 2 replies; 5+ messages in thread
From: Vincent C Jones @ 2005-02-15 3:14 UTC (permalink / raw)
To: linux-kernel; +Cc: mpm
In article <3xVku-kH-15@gated-at.bofh.it> you write:
>On my Thinkpad T30 with a Radeon Mobility M7 LW, I get interesting
>console video corruption if I start GDM, switch back to text mode,
>then stop it again. X is Xfree86 from Debian/unstable or X.org 6.8.2.
>
>The corruption shows up whenever the console scrolls after X has been
>shut down and manifests as horizontal lines spaced about 4 pixel rows
>apart containing contents recognizable as the X display. Switch from
>vt1 to vt2 and back or visual bell clears things back to normal, but
>corruption will reappear on the next scroll.
>
>This has appeared in at least 2.6.11-rc3-mm2 and rc4.
On my Thinkpad X31 with a Radeon Mobility M6 LY I see a major
regression going from 2.6.11-rc3 to rc4. With rc-4, the frame
buffer console (using "video=radeonfb:1024x768-24@60") comes up as
640x480 expanded to 1024x768. The inability of ACPI suspend to turn
off the backlight also returns. Using rc-3, frame buffer console
works fine and suspend/resume appears to work reliably without
needing radeontool to turn off the backlight (as long as I do it
from X.org X).
--
Dr. Vincent C. Jones, PE Expert advice and a helping hand
Computer Network Consultant for those who want to manage and
Networking Unlimited, Inc. control their networking destiny
Phone: +1 201 568-7810
14 Dogwood Lane, Tenafly, NJ 07670
VCJones@NetworkingUnlimited.com http://www.networkingunlimited.com
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Radeon FB troubles with recent kernels
2005-02-15 3:14 ` Radeon FB troubles with recent kernels Vincent C Jones
@ 2005-02-15 12:46 ` Benjamin Herrenschmidt
2005-02-15 12:50 ` Benjamin Herrenschmidt
1 sibling, 0 replies; 5+ messages in thread
From: Benjamin Herrenschmidt @ 2005-02-15 12:46 UTC (permalink / raw)
To: Vincent C Jones; +Cc: linux-kernel, mpm
On Mon, 2005-02-14 at 22:14 -0500, Vincent C Jones wrote:
> In article <3xVku-kH-15@gated-at.bofh.it> you write:
> >On my Thinkpad T30 with a Radeon Mobility M7 LW, I get interesting
> >console video corruption if I start GDM, switch back to text mode,
> >then stop it again. X is Xfree86 from Debian/unstable or X.org 6.8.2.
> >
> >The corruption shows up whenever the console scrolls after X has been
> >shut down and manifests as horizontal lines spaced about 4 pixel rows
> >apart containing contents recognizable as the X display. Switch from
> >vt1 to vt2 and back or visual bell clears things back to normal, but
> >corruption will reappear on the next scroll.
> >
> >This has appeared in at least 2.6.11-rc3-mm2 and rc4.
>
> On my Thinkpad X31 with a Radeon Mobility M6 LY I see a major
> regression going from 2.6.11-rc3 to rc4. With rc-4, the frame
> buffer console (using "video=radeonfb:1024x768-24@60") comes up as
> 640x480 expanded to 1024x768. The inability of ACPI suspend to turn
> off the backlight also returns. Using rc-3, frame buffer console
> works fine and suspend/resume appears to work reliably without
> needing radeontool to turn off the backlight (as long as I do it
> from X.org X).
Ok, so, about half of users are reporting an improvement, and half are
reporting a regression... this is getting nasty...
As far as the mode is concerned, can you send me a complete dmesg log
with the radeonfb debug output enabled in your .config ?
Now, regarding backlight and suspend, it's a more complicated problem.
So far, I managed to "isolate" the issue to the type of flat panel
connected to the chip. In some cases, it seems, the panel uses an
inverted signal to drive the backlight. So depending on the type of
panel, a given bit of code will work ... or not.
I'm in contact with ATI to try to figure out how to get some proper
infos about the backlight from the BIOS (if possible at all), and some
other folks are working on adapting my power management code to various
model of thinkpads.
Unfortunately, I can't promise a version of radeonfb that will fix
everything for everybody by 2.6.11... there are still a few "gray areas"
in there, that I'm trying to clear up, hopefully ATI will provide me
with the proper infos soon...
Ben.
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Radeon FB troubles with recent kernels
2005-02-15 3:14 ` Radeon FB troubles with recent kernels Vincent C Jones
2005-02-15 12:46 ` Benjamin Herrenschmidt
@ 2005-02-15 12:50 ` Benjamin Herrenschmidt
2005-02-15 12:58 ` sigwait() and 2.6 Yves Crespin
1 sibling, 1 reply; 5+ messages in thread
From: Benjamin Herrenschmidt @ 2005-02-15 12:50 UTC (permalink / raw)
To: Vincent C Jones; +Cc: linux-kernel, mpm
> On my Thinkpad X31 with a Radeon Mobility M6 LY I see a major
> regression going from 2.6.11-rc3 to rc4. With rc-4, the frame
> buffer console (using "video=radeonfb:1024x768-24@60") comes up as
> 640x480 expanded to 1024x768. The inability of ACPI suspend to turn
> off the backlight also returns. Using rc-3, frame buffer console
> works fine and suspend/resume appears to work reliably without
> needing radeontool to turn off the backlight (as long as I do it
> from X.org X).
Ok, this is getting complicated. So far, I'm getting a bit more success
reports that regression reports, so I'm keen to keep this new radeonfb
for 2.6.11...
There are several issues involved
As far as the mode setting is concerned, I'm not sure what's going on
whith your specific model, could you please enable radeonfb debug output
in the kernel config and send me the complete dmesg log ?
As far as the panel blanking is concerned (either during suspend or
normal console blanking), this is a tricky matter. It seems that a bit
of code that works for some panels won't work with others. So far, I
managed to isolate the issue to some panels relying on an inverted
signal out of the chip. I'm in contact with ATI to try to solve that
problem, it might be possible to get proper infos about the type of
panel connected via the BIOS ROM image. Unfortunately, I don't think
I'll get a definitive answer before 2.6.11 is released.
Note that some users have successfully enabled the powerbook/ibook
specific power management code I have in there for thinkpads. I intend t
o merge some of that stuff after 2.6.11 is done.
Ben.
^ permalink raw reply [flat|nested] 5+ messages in thread
* sigwait() and 2.6
2005-02-15 12:50 ` Benjamin Herrenschmidt
@ 2005-02-15 12:58 ` Yves Crespin
2005-02-15 23:59 ` Ulrich Drepper
0 siblings, 1 reply; 5+ messages in thread
From: Yves Crespin @ 2005-02-15 12:58 UTC (permalink / raw)
To: linux-kernel; +Cc: Yves Crespin
[-- Attachment #1: Type: text/plain, Size: 3116 bytes --]
Hi,
Going on a 2.6 kernel, I have a trouble with sigwait()
When I send a kill to this program, the exit code is 143 (signal 15 and
core)!
Is there a workaround ?
Thanks,
Yves
gcc -g -Wall -D_REENTRANT=1 -D_THREAD_SAFE=1 s.c -lpthread -o s
/===== début du code =====/
#include <unistd.h>
#include <stdio.h>
#include <signal.h>
#include <pthread.h>
typedef void Sigfunc(int);
#define ThreadBlockSignal() ThreadSignalAction(SIG_BLOCK)
#define ThreadUnblockSignal() ThreadSignalAction(SIG_UNBLOCK)
/*----------STATIC------------------*/
extern void ThreadSignalAction(const int how)
{
sigset_t newmask;
if (sigemptyset(&newmask)<0){
printf("sigemptyset failed");
return;
}
if (sigaddset(&newmask,SIGTERM)<0){
printf("sigaddset failed");
return;
}
if (pthread_sigmask(how,&newmask,NULL)){
printf("pthread_sigmask SIG_BLOCK failed"); return;
}
}
extern Sigfunc * signal_intr(int signo,Sigfunc *func)
{
struct sigaction act, oact;
act.sa_handler = func;
sigemptyset(&act.sa_mask);
act.sa_flags = 0;
if (signo == SIGALRM){
#ifdef SA_INTERRUPT
act.sa_flags |= SA_INTERRUPT; /* Interrupt mode */
#endif /* SA_INTERRUPT */
}else{
#ifdef SA_RESTART
/*
* automatic restart of interrupted system calls except
* if they are operating on a slow device.
* For select():
* Under BSD, even if SA_RESTART is specified, select() was
* never restarted.
* Under SVR4, if SA_RESTART is specified, even select() and
* pool() are automatically restarted.
*/
act.sa_flags |= SA_RESTART;
#endif /* SA_RESTART */
if (signo == SIGCHLD){
act.sa_flags |= SA_NOCLDSTOP; /* Don't send SIGCHLD when
children stop*/
}
}
#ifdef SA_RESETHAND
act.sa_flags &= ~SA_RESETHAND; /* signal handle remains installed */
#endif /* SA_RESETHAND */
if (sigaction(signo, &act, &oact) < 0){
return(SIG_ERR);
}
return(oact.sa_handler);
}
extern int WaitSignal(void)
{
sigset_t newmask;
int ret;
int sig;
if (sigemptyset(&newmask)<0){
printf("sigemptyset failed");
return -1;
}
if (sigaddset(&newmask,SIGTERM)<0){
printf("sigaddset failed");
return -1;
}
printf("Waiting signal ..."); fflush(stdout);
ret = sigwait(&newmask,&sig);
if (ret!=0){
printf("WaitSignal: sigwait failed %d",ret);
}else{
printf("WaitSignal: sigwait sig %d",sig);
}
return sig;
}
int main(int argc,char * const argv[])
{
if (signal_intr(SIGTERM,SIG_DFL) == SIG_ERR){
printf("signal %d (set handle) failed",SIGTERM);
}
/* -- Main loop */
printf("%lu ready ...",(unsigned long)getpid()); fflush(stdout);
int signo;
ThreadUnblockSignal();
signo = WaitSignal();
ThreadBlockSignal();
if (signo==SIGTERM){
printf("\nSIGTERM in main\n"); fflush(stdout);
}else{
printf("\n%d in main\n",signo); fflush(stdout);
}
return 0;
}
/===== fin du code =====/
[-- Attachment #2: crespin.quartz.vcf --]
[-- Type: text/x-vcard, Size: 295 bytes --]
begin:vcard
fn:Yves Crespin
n:Crespin;Yves
org:Quartz
adr:Hameau du Pra - CIDEX 322;;39, rue Victor Hugo;CROLLES;;38920;France
email;internet:Crespin.Quartz@Wanadoo.fr
tel;work:04.76.92.21.91
tel;cell:06.86.42.86.81
x-mozilla-html:FALSE
url:http://crespin.quartz.free.fr/
version:2.1
end:vcard
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: sigwait() and 2.6
2005-02-15 12:58 ` sigwait() and 2.6 Yves Crespin
@ 2005-02-15 23:59 ` Ulrich Drepper
0 siblings, 0 replies; 5+ messages in thread
From: Ulrich Drepper @ 2005-02-15 23:59 UTC (permalink / raw)
To: Yves Crespin; +Cc: linux-kernel, Yves Crespin
On Tue, 15 Feb 2005 13:58:28 +0100, Yves Crespin
<crespin.quartz@wanadoo.fr> wrote:
> ThreadUnblockSignal();
> signo = WaitSignal();
> ThreadBlockSignal();
You expect this to work? Just read the POSIX spec or even the man
pages. All signals sigwait() waits for must be blocked before the
call. You deliberately do the opposite. Swap the ThreadUnblockSignal
and ThreadBlockSignal lines and suddenly the program doesn't crash
anymore.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-02-15 23:59 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <3xVku-kH-15@gated-at.bofh.it>
2005-02-15 3:14 ` Radeon FB troubles with recent kernels Vincent C Jones
2005-02-15 12:46 ` Benjamin Herrenschmidt
2005-02-15 12:50 ` Benjamin Herrenschmidt
2005-02-15 12:58 ` sigwait() and 2.6 Yves Crespin
2005-02-15 23:59 ` Ulrich Drepper
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox