Re: NULL pointer dereference

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



List,

 This is an improved [hopefully] version of the agrsm-test tool.
 More info gathering routines are added for the failure mode.
 The script is also modified to print to stdout by default
 instead of a dedicated logfile (this is what most Unix utilities
 do -- they act as filters, so their output can be piped to something
 else).

 Run it as follows:
 sudo ./agrsm-test 2>&1 | tee /tmp/my.log

 BTW Why agrsm-tool is a separate package? Wouldn't it be easier to
 merge it with the driver *.deb and distribute them as just one *.deb
 package?

-- 
Nick Zhuravlev
www.auriga.com

On Fri, Feb 19, 2010 at 02:33:32AM +0300, Nikolay Zhuravlev <xxor@xxxxxxx> wrote:

> Kevin,
> 
>  What does the following command say:
>  $ grep CONFIG_SND_HDA_POWER_SAVE /boot/config-`uname -r`
> 
>  Also, did you try to rebuild the driver under the new kernel?
>  I think portions of the driver depend on the
>  CONFIG_SND_HDA_POWER_SAVE option too. So the driver needs to
>  be rebuilt.
> 
> cd <where the sources are>
> make clean
> make
> sudo make modules_install
> sudo modprobe agrmodem
> sudo modprobe agrserial
> sudo ln -sf /dev/ttyAGS3 /dev/modem
> sudo ln -sf /dev/ttyAGS3 /dev/ttySAGR
> sudo wvdialconf /etc/wvdial.conf
> 
> -- 
> Nick Zhuravlev
> www.auriga.com
> 
> On Wed, Feb 17, 2010 at 02:24:31AM -0200, Kevin Fernandez <siegfri3d@xxxxxxxxx> wrote:
> 
> > Hello Nikolay,
> > First thanks for helping!
> > 
> > I tried to recompile the kernel (2.6.31 of the ubuntu sources), i
> > disabled the SMP support, CONFIG_SND_HDA_POWER_SAVE was already unset
> > so i tried to set it as 0, using the new kernel i brought done all
> > interfaces, unloaded many modules, connected successfully, i could
> > ping and send 10 icmp packets but then the network stopped again and
> > pppd crashed (just like before), when reconnecting it gave me a
> > segfault (so again, just like before), the dmesg output is a bit
> > different:
> > 
> > [  539.463626] ------------[ cut here ]------------
> > [  539.463629] kernel BUG at kernel/timer.c:762!
> > [  539.463631] invalid opcode: 0000 [#1]
> > [  539.463634] last sysfs file:
> > /sys/devices/LNXSYSTM:00/device:00/PNP0A08:00/device:0b/PNP0C09:00/PNP0C0A:00/power_supply/BAT1/voltage_now
> > [  539.463638] Modules linked in: ppp_async crc_ccitt agrserial
> > agrmodem isofs binfmt_misc snd_hda_codec_realtek snd_hda_intel
> > snd_hda_codec snd_hwdep snd_pcm snd_timer snd psmouse soundcore
> > snd_page_alloc fbcon tileblit font bitblit softcursor i915 drm
> > i2c_algo_bit intel_agp agpgart video output [last unloaded: mii]
> > [  539.463658]
> > [  539.463662] Pid: 9361, comm: wvdial Tainted: P           (2.6.31.9
> > #3) MSI Notebook VR601
> > [  539.463665] EIP: 0060:[<c013be43>] EFLAGS: 00210286 CPU: 0
> > [  539.463673] EIP is at add_timer+0x13/0x20
> > [  539.463675] EAX: fb576ae0 EBX: f97bed7c ECX: 00000000 EDX: f97beac0
> > [  539.463678] ESI: f97bed7c EDI: fffffff4 EBP: efb41d88 ESP: efb41d88
> > [  539.463680]  DS: 007b ES: 007b FS: 0000 GS: 00e0 SS: 0068
> > [  539.463684] Process wvdial (pid: 9361, ti=efb40000 task=efb38c80
> > task.ti=efb40000)
> > [  539.463686] Stack:
> > [  539.463687]  efb41d90 fb44e04e efb41da0 fb508e7c fb508e37 f97bed7c
> > efb41dc0 fb508f05
> > [  539.463693] <0> 000003e8 00000000 00000000 00000000 12345678
> > f97bed7c efb41dc8 fb44e2b8
> > [  539.463698] <0> efb41dd0 fb44e2cd efb41de8 f97bcf60 fffffff4
> > efb41de8 f1bd61a4 f97bed7c
> > [  539.463704] Call Trace:
> > [  539.463739]  [<fb44e04e>] ? lt_add_timer+0x2e/0x30 [agrmodem]
> > [  539.463782]  [<fb508e7c>] ? VMODEM_Start_Timer+0x28/0x33 [agrmodem]
> > [  539.463822]  [<fb508e37>] ? timertick_function+0x0/0x1d [agrmodem]
> > [  539.463863]  [<fb508f05>] ? vxdPortOpen+0x3b/0x42 [agrmodem]
> > [  539.463893]  [<fb44e2b8>] ? wrap_vxdPortOpen+0x8/0x10 [agrmodem]
> > [  539.463921]  [<fb44e2cd>] ? modemPortOpen+0xd/0x20 [agrmodem]
> > [  539.463927]  [<f97bcf60>] ? serial8250_startup+0x1b0/0x370 [agrserial]
> > [  539.463933]  [<c0363792>] ? uart_startup+0x42/0x130
> > [  539.463937]  [<c0363d68>] ? uart_open+0xd8/0x340
> > [  539.463941]  [<c034bbb6>] ? tty_init_dev+0x76/0x140
> > [  539.463946]  [<c01d8a06>] ? mntput_no_expire+0x16/0x80
> > [  539.463949]  [<c034be1f>] ? tty_open+0x19f/0x430
> > [  539.463953]  [<c01c6f7a>] ? chrdev_open+0x8a/0x120
> > [  539.463958]  [<c01c241a>] ? __dentry_open+0xaa/0x220
> > [  539.463962]  [<c01c2675>] ? nameidata_to_filp+0x55/0x70
> > [  539.463965]  [<c01c6ef0>] ? chrdev_open+0x0/0x120
> > [  539.463969]  [<c01cf7e5>] ? do_filp_open+0x535/0x8f0
> > [  539.463973]  [<c01cc465>] ? getname+0x25/0xf0
> > [  539.463977]  [<c01c21b0>] ? do_sys_open+0x50/0x160
> > [  539.463981]  [<c01c5a45>] ? fput+0x15/0x20
> > [  539.463984]  [<c01c2329>] ? sys_open+0x29/0x40
> > [  539.463988]  [<c010332c>] ? syscall_call+0x7/0xb
> > [  539.463990] Code: 40 2b 6e c0 8b 80 08 02 00 00 89 41 2c e9 36 ff
> > ff ff 8d b6 00 00 00 00 55 8b 10 89 e5 85 d2 75 0a 8b 50 08 e8 ef fe
> > ff ff 5d c3 <0f> 0b eb fe 89 f6 8d bc 27 00 00 00 00 55 89 e5 e8 18 97
> > ff ff
> > [  539.464019] EIP: [<c013be43>] add_timer+0x13/0x20 SS:ESP 0068:efb41d88
> > [  539.464060] ---[ end trace c38ee2fc1c238c35 ]---
> > 
> > I'll try to see if i can get some logs of pppd when it crashes.
> > 
> > Any idea would be appreciated!
> > Thanks,
> > Kevin
> > 
> > 2010/2/16, Nikolay Zhuravlev <xxor@xxxxxxx>:
> > > Things to try that come to my mind:
> > >
> > > - try a non-SMP kernel
> > > - try to build the kernel with the
> > >   CONFIG_SND_HDA_POWER_SAVE unset
> > > - try to bring down other interfaces (eth0, wlan0)
> > >   before using the modem
> > >
> > > --
> > > Nick Zhuravlev
> > > www.auriga.com
> > >
> > > On Sun, Feb 14, 2010 at 08:51:02PM -0200, Kevin Fernandez
> > > <siegfri3d@xxxxxxxxx> wrote:
> > >
> > >> Almost there!
> > >> I don't know if it's your change (probably!); as i also upgraded to
> > >> the variant 2.6.31-20-generic.
> > >> I could run wvdialconf without problem, then i tried multiple times to
> > >> connect but right after connecting to the first site it was always
> > >> crashing wvdial/pppd (i could see that it resolved the site in firefox
> > >> and was trying to connect to it).
> > >> After trying another time i got a segmentation fault:
> > >>
> > >> --> WvDial: Internet dialer version 1.60
> > >> --> Initializing modem.
> > >> --> Sending: ATZ
> > >> ATZ
> > >> OK
> > >> --> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
> > >> ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
> > >> OK
> > >> --> Modem initialized.
> > >> --> Sending: ATDT17003131
> > >> --> Waiting for carrier.
> > >> ATDT17003131
> > >> BUSY
> > >> --> The line is busy. Trying again.
> > >> --> Sending: ATDT17003131
> > >> --> Waiting for carrier.
> > >> ATDT17003131
> > >> CONNECT 40000 V44
> > >> --> Carrier detected.  Waiting for prompt.
> > >> ~[7f]}#@!}!}!} }8}"}&} }*} } }#}$@#}%}&(BAh}'}"}(}"[0c]J~
> > >> --> PPP negotiation detected.
> > >> --> Starting pppd at Sun Feb 14 20:17:40 2010
> > >> --> Pid of pppd: 16639
> > >> --> Using interface ppp0
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> local  IP address 189.48.97.120
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> remote IP address 201.4.82.93
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> primary   DNS address 200.202.193.75
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> secondary DNS address 200.222.0.34
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> Connect time 1.1 minutes.
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> pppd: px2[08]@[7f]2[08]
> > >> --> Disconnecting at Sun Feb 14 20:18:47 2010
> > >> --> The PPP daemon has died: A modem hung up the phone (exit code = 16)
> > >> --> man pppd explains pppd error codes in more detail.
> > >> --> Try again and look into /var/log/messages and the wvdial and pppd
> > >> man pages for more information.
> > >> --> Auto Reconnect will be attempted in 5 seconds
> > >> --> Initializing modem.
> > >> --> Sending: ATZ
> > >> ATZ
> > >> OK
> > >> --> Sending: ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
> > >> ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
> > >> OK
> > >> --> Modem initialized.
> > >> Erreur de segmentation
> > >>
> > >>
> > >>
> > >> dmesg:
> > >>
> > >> [ 1348.660145] ------------[ cut here ]------------
> > >> [ 1348.660150] kernel BUG at
> > >> /build/buildd/linux-2.6.31/kernel/timer.c:762!
> > >> [ 1348.660154] invalid opcode: 0000 [#1] SMP
> > >> [ 1348.660159] last sysfs file:
> > >> /sys/devices/system/cpu/cpu1/topology/core_id
> > >> [ 1348.660162] Modules linked in: ppp_deflate zlib_deflate bsd_comp
> > >> ppp_async crc_ccitt agrserial agrmodem isofs udf crc_itu_t binfmt_misc
> > >> ppdev vboxnetflt vboxnetadp vboxdrv joydev snd_hda_codec_realtek
> > >> wlan_scan_sta ath_rate_sample iptable_nat nf_nat nf_conntrack_ipv4
> > >> nf_conntrack nf_defrag_ipv4 iptable_mangle snd_hda_intel snd_hda_codec
> > >> snd_hwdep iptable_filter pcmcia ip_tables x_tables snd_pcm_oss
> > >> snd_mixer_oss snd_pcm snd_seq_dummy snd_seq_oss sdhci_pci sdhci
> > >> led_class yenta_socket rsrc_nonstatic pcmcia_core snd_seq_midi
> > >> snd_rawmidi snd_seq_midi_event snd_seq snd_timer snd_seq_device snd
> > >> ath_pci wlan ath_hal psmouse serio_raw soundcore snd_page_alloc sbp2
> > >> lp parport dm_raid45 xor fbcon tileblit font bitblit softcursor i915
> > >> drm i2c_algo_bit ohci1394 ieee1394 r8169 mii intel_agp agpgart video
> > >> output
> > >> [ 1348.660246]
> > >> [ 1348.660251] Pid: 16129, comm: wvdial Tainted: P
> > >> (2.6.31-20-generic #57-Ubuntu) MSI Notebook VR601
> > >> [ 1348.660255] EIP: 0060:[<c0150bb3>] EFLAGS: 00010286 CPU: 1
> > >> [ 1348.660262] EIP is at add_timer+0x13/0x20
> > >> [ 1348.660265] EAX: fbaaebc0 EBX: f851ae28 ECX: 00000000 EDX: f851ab60
> > >> [ 1348.660268] ESI: f851ae28 EDI: fffffff4 EBP: ec82dd88 ESP: ec82dd88
> > >> [ 1348.660272]  DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
> > >> [ 1348.660275] Process wvdial (pid: 16129, ti=ec82c000 task=ec838000
> > >> task.ti=ec82c000)
> > >> [ 1348.660278] Stack:
> > >> [ 1348.660280]  ec82dd90 fb98604e ec82dda0 fba40ebc fba40e77 f851ae28
> > >> ec82ddc0 fba40f45
> > >> [ 1348.660289] <0> 000003e8 00000000 00000000 00000000 12345678
> > >> f851ae28 ec82ddc8 fb9862f8
> > >> [ 1348.660298] <0> ec82ddd0 fb98630d ec82dde8 f8518fe0 fffffff4
> > >> ec82dde8 ef86be04 f851ae28
> > >> [ 1348.660309] Call Trace:
> > >> [ 1348.660346]  [<fb98604e>] ? lt_add_timer+0x2e/0x30 [agrmodem]
> > >> [ 1348.660389]  [<fba40ebc>] ? VMODEM_Start_Timer+0x28/0x33 [agrmodem]
> > >> [ 1348.660432]  [<fba40e77>] ? timertick_function+0x0/0x1d [agrmodem]
> > >> [ 1348.660473]  [<fba40f45>] ? vxdPortOpen+0x3b/0x42 [agrmodem]
> > >> [ 1348.660504]  [<fb9862f8>] ? wrap_vxdPortOpen+0x8/0x10 [agrmodem]
> > >> [ 1348.660533]  [<fb98630d>] ? modemPortOpen+0xd/0x20 [agrmodem]
> > >> [ 1348.660540]  [<f8518fe0>] ? serial8250_startup+0x210/0x380 [agrserial]
> > >> [ 1348.660548]  [<c039d0d6>] ? uart_startup+0x46/0x140
> > >> [ 1348.660552]  [<c039dc12>] ? uart_open+0x102/0x220
> > >> [ 1348.660557]  [<c0384d13>] ? __tty_open+0x1a3/0x460
> > >> [ 1348.660562]  [<c0384fef>] ? tty_open+0x1f/0x40
> > >> [ 1348.660568]  [<c01eae1d>] ? chrdev_open+0xcd/0x190
> > >> [ 1348.660572]  [<c01e5df9>] ? __dentry_open+0xb9/0x230
> > >> [ 1348.660577]  [<c01e6055>] ? nameidata_to_filp+0x55/0x70
> > >> [ 1348.660581]  [<c01ead50>] ? chrdev_open+0x0/0x190
> > >> [ 1348.660587]  [<c01f3daa>] ? do_filp_open+0x53a/0x890
> > >> [ 1348.660592]  [<c01e5b90>] ? do_sys_open+0x50/0x150
> > >> [ 1348.660597]  [<c01e9645>] ? fput+0x15/0x20
> > >> [ 1348.660601]  [<c01e5a67>] ? filp_close+0x47/0x70
> > >> [ 1348.660605]  [<c01e5cf9>] ? sys_open+0x29/0x40
> > >> [ 1348.660610]  [<c01033ac>] ? syscall_call+0x7/0xb
> > >> [ 1348.660612] Code: 8b 80 08 02 00 00 89 43 2c e9 fa fe ff ff 0f 0b
> > >> eb fe 8d b6 00 00 00 00 55 8b 10 89 e5 85 d2 75 0a 8b 50 08 e8 af fe
> > >> ff ff 5d c3 <0f> 0b eb fe 89 f6 8d bc 27 00 00 00 00 55 89 e5 e8 98 8c
> > >> ff ff
> > >> [ 1348.660669] EIP: [<c0150bb3>] add_timer+0x13/0x20 SS:ESP 0068:ec82dd88
> > >> [ 1348.660677] ---[ end trace e3d2e7c757a613b0 ]---
> > >>
> > >>
> > >> Any idea?
> > >> Thanks for the help!
> > >>
> > >> 2010/2/14, Nikolay Zhuravlev <xxor@xxxxxxx>:
> > >> > I am not sure. I think power_save=0 means that
> > >> > there is no timeout and snd-hda-intel never sleeps.
> > >> >
> > >> > My previous kernel (vanilla 2.6.32) did not have
> > >> > CONFIG_SND_HDA_POWER_SAVE set, so the power_save was
> > >> > not even an option, and it all worked fine.
> > >> >
> > >> > There are also bug reports of some high pitch noise
> > >> > related to the power_save=10 setting, both in Fedora
> > >> > and in Ubuntu.
> > >> >
> > >> > --
> > >> > Nick Zhuravlev
> > >> > www.auriga.com
> > >> >
> > >> > On Sun, Feb 14, 2010 at 02:26:08PM -0400, Bjorn Wielens
> > >> > <Uniacke1@xxxxxxxx>
> > >> > wrote:
> > >> >
> > >> >> so it looks like if the hda driver is in a sleep state, the agrsm
> > >> >> driver
> > >> >> has a fit.
> > >> >>
> > >> >>
> > >> >> I just verified that my SuSE distro does not set the power save in
> > >> >> modprobe, hence it worked fine out of the box for me.
> > >> >>
> > >> >> That said, it must be possible to modify the driver code to "wake" the
> > >> >> sound card properly- I know for a fact that it has function prototypes
> > >> >> for powerup/powerdown functions.
> > >> >>
> > >> >> Bjorn.
> > >> >>
> > >> >>
> > >> >> On 02/14/2010 01:57 PM, Nikolay Zhuravlev wrote:
> > >> >> > Valera,
> > >> >> >
> > >> >> > Glad it worked for you.  It is amazing how much difference a single
> > >> >> > bit of information can make ;)
> > >> >> >
> > >> >>
> > >> >
> > >> >
> > >> >
> > >
#!/bin/sh
# Version 0.0.1
# Marvin.stodolsky@xxxxxxxxx

echo "All installed agr* modules"
find /lib/modules/ -name "agr*" -ls

  echo "Trying to unload the drivers:"
modprobe -v -r agrserial || echo FAILED
  echo "Trying to load the drivers:"
  modprobe -v agrserial || echo FAILED
  if test -L /dev/ttySAGR ; then
    echo
    echo "Agere drivers loaded:"
echo "===================="
echo "lsmod | grep agr"
echo "===================="
	lsmod | grep agr
echo "===================="
echo "modinfo agrserial agrmodem"
echo "===================="
	modinfo agrserial agrmodem
    echo
    echo "Testing for the symlink:"
    ls -l /dev/ttySAGR
  fi 
  echo
  echo "Checking for utility wvdialconf"
  if test -x /usr/bin/wvdialconf ; then
    echo "Found /usr/bin/wvdialconf, preparing to run:"
    echo 	"	wvdialconf /etc/wvdial.conf"
    if test -f /etc/wvdial.conf ; then
      echo "A file /etc/wvdial.conf already exists, first renaming to /etc/wvdial.$(date +%Y%m%d%M%m)"
      cp /etc/wvdial.conf /etc/wvdial.$(date +%Y%m%d%M%m)
    fi
	if wvdialconf /etc/wvdial.conf; then
      cat<<END

Modem detection successful
Read wvdial.txt produced by scanModem
Then edit /etc/wvdial.conf  with:
  sudo gedit /etc/wvdial.conf
at the lines beginning with ; and deleting the ; < >  "
Then try a dialout with:
   sudo wvdial

END
    else
echo "===================="
echo "cat /proc/interrupts"
echo "===================="
cat /proc/interrupts
echo "===================="
echo "cat /proc/asound/cards"
echo "===================="
cat /proc/asound/cards
echo "===================="
echo "cat /proc/asound/card0/codec#1"
echo "===================="
cat /proc/asound/card0/codec#1
echo "===================="
echo "lsmod"
echo "===================="
lsmod 
echo "===================="
echo "lsusb"
echo "===================="
lsusb
echo "===================="
echo "lsb_release -a"
echo "===================="
lsb_release -a
echo "===================="
echo "dmesg | tail -70"
echo "===================="
dmesg | tail -70
echo "===================="
      cat<<END

Summary: Modem detection failed.
A reboot may be necessary before modem detection through:
	sudo modprobe agrserial
Which will load agrmodem, agrserial and create the symbolic link needed for:
	sudo wvdialconf

END
    fi
  else
    echo "Utility wvdialconf not found"
  if test -f /etc/wvdial.conf ; then
    echo "Read wvdial.txt produced by scanModem for guidance in doing the edit:"
    echo "sudo gedit /etc/wvdial.conf"
  fi 
  fi
echo
exit 0

[Index of Archives]     [Linux Media Development]     [Asterisk]     [DCCP]     [Netdev]     [X.org]     [Xfree86]     [Fedora Women]     [Linux USB]

  Powered by Linux