Re: Intel Pro/Wireless 3945ABG - if_ipw not working

2007-05-19 Thread Gilbert Cao
On Sat, May 19, 2007 at 03:23:03PM +1000, fbsd wrote:
  Vince wrote:
  Justin Muir wrote:

  Hello,
 
  I load the module and I'm not getting the ipw0 device.
  If I'm reading the instructions
  (damien.bergamini.free.fr/ipw/ipw-freebsd.html)
  correctly, I should be able to:
 
  1. load the driver
  2. see the ipw0 device 3. load the firmware into the device with 
  ipwcontrol.
 
  
 
  The 3945ABG needs the wpi driver (ipw is for 2100 chipset)
  Damien's freebsd wpi driver has been discontinued (for some time see
  http://kerneltrap.org/node/6497/ .)
  The page for the driver currently being developed is
  http://www.clearchain.com/wiki/Wpi but sadly
  a) the tarballed versions are old and wont compile on -STABLE or
  -CURRENT (dont know about 6.2-RELEASE though)
  b) Unless you have perforce access you can only download the more recent
  development version file by file (from
  http://perforce.freebsd.org/depotTreeBrowser.cgi?FSPC=//depot/user/benjsc/wpi)
  c) it doesnt work for me anyway ;)
 
  sorry its not better news
 
  regards,
  Vince
 
  I agree with Vince that the latest drivers do not work at least on FreeBSD 
  6.1 (I'm using PC-BSD 1.3 which is based on 6.1). I tried them all with no 
  luck. But I tried an older version which does, albeit with some error 
  messages. I don't remember where I found it and I don't remember how I 
  installed it (That will teach me to document everything properly!) but 
  please find it attached and good luck!
 
  Ron

  Hi,

As I have posted a message here:
http://lists.freebsd.org/pipermail/freebsd-questions/2007-January/140475.html
I have put a custom version of mine from Benjamin's package here, months ago:
http://www.bsdmon.com/download/20070121-wpi-freebsd.tar.gz

I confirmed the latest driver from Benjamin Clearchain does not work for
me on FreeBSD 6.2. (I hope there will be more news, btw).

Maybe Ron is talking about my custom version ? ^^
Anyway, it is certainly not complete, but at least, it works for me for
months, now ... However, I didn't success in making it work with
wpa_supplicant, sorry ...

Hope this helps !

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgpgiUT1n9Ex8.pgp
Description: PGP signature


Re: How to install the 3945ABG Driver on a fresh FreeBSD 6.2 install?

2007-01-21 Thread Gilbert Cao
On Thu, Jan 18, 2007 at 12:36:04AM +, Vince Hoffman wrote:
 I hate to say this but this driver only seems to compile on -CURRENT as 
 far as i can tell (and as far as the conversation at 
 http://docs.freebsd.org/cgi/getmsg.cgi?fetch=0+0+archive/2007/freebsd-drivers/20070107.freebsd-drivers
  
 leads me to believe.)
 There is another less complete driver floating around that is usable on 
 6.x although it only works for some people and even then only at 6 meg 
 (i believe the conversation i linked contains links to that driver if 
 you dont fancy running current.)
 
 Vince

  Hi,

I think you are talking about that one
http://people.freebsd.org/~flz/local/wpi/wpi-freebsd-20061109.tgz
about a less complete driver usable on 6.x.
And, yes, I have tried it, but it did not work for me. (I don't know yet
how it works for some people).
In my case, with ifconfig, the status is still on no carrier.
No associated status.


About the following,
http://www.clearchain.com/~benjsc/download/20070107-wpi-freebsd.tar.gz
basically yes, it only compiles on -CURRENT. I have tried it and it
works for me.


As I wanted to stay on 6.x, I have installed a 6.2-RELEASE, and tried to
make the 20070107-wpi-freebsd.tar.gz compiles.
Here, you will find the result of my work :
http://www.bsdmon.com/download/20070121-wpi-freebsd.tar.gz

To make it compiles, I basically started from 20070107-wpi-freebsd.tar.gz
and took some code on wpi-freebsd-20061109.tgz.

Now, this new one compiles and it works for me :
status: associated on ifconfig output.
Don't ask why I do this or that, in the code. I don't really know :p.
First, I just wanted to make the latest package I found, compile.
And, on the plus side, it works for me.
In the package, I have kept the original file as .orig, so you will see
what I have added and changed.

I have intentionally commented WPI_DEBUG and WPI_CURRENT.
About WPI_CURRENT, this have to be commented, on 6.x.
About WPI_DEBUG, it is just that I wanted to get rid of lots of output,
in my daily use.


Hope it helps ;)

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgp5JhV2gepa5.pgp
Description: PGP signature


Incorrect kernel time on laptop boot

2007-01-18 Thread Gilbert Cao

Hi the list,

I currently experienced a problem with my Sony Vaio VGN-FE31B laptop.
Each time I boot, the kernel time seems to be set with the wrong date time.
When I poweroff the machine, wait for some minutes and reboot again, the
kernel time is set with a few seconds after the wrong time on shutdown.

Is it some kind of wrong bios clock used, that completely stopped when
poweroff ?

I use a FreeBSD 7.0-CURRENT, from the 14th of January 2007.
I tried the snapshot FreeBSD 7.0-CURRENT-200610, no time problem.
With snapshot FreeBSD 7.0-CURRENT-200611, the time problem appears.

I will provide you the dmesg output, when I will come back home.
I have also followed the instructions at
http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/troubleshoot.html#LAPTOP-CLOCK-SKEW
with no success.

Any ideas ?
Thanks.



___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Incorrect kernel time on laptop boot

2007-01-18 Thread Gilbert Cao
On Fri, Jan 19, 2007 at 07:41:49AM +1300, Jonathan Chen wrote:
 On Thu, Jan 18, 2007 at 09:35:43AM +0100, Gilbert Cao wrote:
  
  Hi the list,
  
  I currently experienced a problem with my Sony Vaio VGN-FE31B laptop.
  Each time I boot, the kernel time seems to be set with the wrong date time.
  When I poweroff the machine, wait for some minutes and reboot again, the
  kernel time is set with a few seconds after the wrong time on shutdown.
 
 If you're dual-booting with Windows, the cause is that Windows will
 set the BIOS to wall-time, while FreeBSD sets the BIOS to UTC. One way
 to fix this is to run tzsetup and set FreeBSD to run with wall-time.

Well, yes, I have dual boot with Windows, and I know it needs to have
BIOS clock set to local time. My FreeBSD is tzsetup to local time, no
UTC, and it has a /etc/wall_cmos_clock file and adjkerntz -i running.

At the time I wrote, my laptop still has its date and time set to
yesterday evening (local time), and it was powered off the whole day, today.


However, if I boot it with a FreeBSD 7.0-CURRENT-200610 kernel, its date
and time is set correctly. So, I might concluded that something has
changed between 200610 and 200611 snapshots.


Anyway, I don't know if it can help but here is a result from :
$ sysctl kern.timecounter
 
kern.timecounter.tc.i8254.mask: 65535
kern.timecounter.tc.i8254.counter: 17348
kern.timecounter.tc.i8254.frequency: 1193182
kern.timecounter.tc.i8254.quality: 0
kern.timecounter.tc.ACPI-fast.mask: 16777215
kern.timecounter.tc.ACPI-fast.counter: 15466075
kern.timecounter.tc.ACPI-fast.frequency: 3579545
kern.timecounter.tc.ACPI-fast.quality: 1000
kern.timecounter.tc.TSC.mask: 4294967295
kern.timecounter.tc.TSC.counter: 886479930
kern.timecounter.tc.TSC.frequency: 1662511500
kern.timecounter.tc.TSC.quality: -100
kern.timecounter.stepwarnings: 0
kern.timecounter.nbinuptime: 1387464
kern.timecounter.nnanouptime: 8
kern.timecounter.nmicrouptime: 74273
kern.timecounter.nbintime: 92905
kern.timecounter.nnanotime: 13
kern.timecounter.nmicrotime: 92892
kern.timecounter.ngetbinuptime: 120493
kern.timecounter.ngetnanouptime: 173
kern.timecounter.ngetmicrouptime: 174462
kern.timecounter.ngetbintime: 0
kern.timecounter.ngetnanotime: 2
kern.timecounter.ngetmicrotime: 330562
kern.timecounter.nsetclock: 3
kern.timecounter.hardware: ACPI-fast
kern.timecounter.choice: TSC(-100) ACPI-fast(1000) i8254(0) dummy(-100)
kern.timecounter.tick: 1
kern.timecounter.smp_tsc: 0


.. and a dmesg output from my laptop:
 
Copyright (c) 1992-2007 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 7.0-CURRENT #0: Sun Jan 14 15:35:13 CET 2007
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/VAIO
WARNING: WITNESS option enabled, expect reduced performance.
WARNING: MPSAFE network stack disabled, expect reduced performance.
ACPI APIC Table: SONY J3
Timecounter i8254 frequency 1193182 Hz quality 0
CPU: Intel(R) Core(TM)2 CPU T5500  @ 1.66GHz (1662.51-MHz 686-class CPU)
  Origin = GenuineIntel  Id = 0x6f6  Stepping = 6
  
Features=0xbfebfbffFPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE
  Features2=0xe39dSSE3,RSVD2,MON,DS_CPL,EST,TM2,SSSE3,CX16,XTPR,b15
  AMD Features=0x2010NX,LM
  AMD Features2=0x1LAHF
  Cores per package: 2
real memory  = 1609105408 (1534 MB)
avail memory = 1558872064 (1486 MB)
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
ioapic0: Changing APIC ID to 1
ioapic0 Version 2.0 irqs 0-23 on motherboard
kbd1 at kbdmux0
ath_hal: 0.9.20.3 (AR5210, AR5211, AR5212, RF5111, RF5112, RF2413, RF5413)
acpi0: SONY on motherboard
acpi_bus_number: can't get _ADR
acpi_bus_number: can't get _ADR
acpi_bus_number: can't get _ADR
acpi_bus_number: can't get _ADR
Timecounter ACPI-fast frequency 3579545 Hz quality 1000
acpi_timer0: 24-bit timer at 3.579545MHz port 0x1008-0x100b on acpi0
acpi_ec0: Embedded Controller: GPE 0x17 port 0x62,0x66 on acpi0
cpu0: ACPI CPU on acpi0
acpi_throttle0: ACPI CPU Throttling on cpu0
cpu1: ACPI CPU on acpi0
acpi_throttle1: ACPI CPU Throttling on cpu1
acpi_throttle1: failed to attach P_CNT
device_attach: acpi_throttle1 attach returned 6
acpi_acad0: AC Adapter on acpi0
battery0: ACPI Control Method Battery on acpi0
acpi_lid0: Control Method Lid Switch on acpi0
acpi_button0: Power Button on acpi0
pcib0: ACPI Host-PCI bridge port 0xcf8-0xcff on acpi0
pci0: ACPI PCI bus on pcib0
pcib1: ACPI PCI-PCI bridge irq 16 at device 1.0 on pci0
pci1: ACPI PCI bus on pcib1
nvidia0: GeForce Go 7400 mem 
0xd100-0xd1ff,0xb000-0xbfff,0xd000-0xd0ff irq 16 at 
device 0.0 on pci1
nvidia0: [GIANT

Re: Preserve date when cp over smbfs

2005-12-30 Thread Gilbert Cao
On Thu, Dec 29, 2005 at 04:51:56PM +0100, Gilbert Cao wrote:
 On Wed, Dec 28, 2005 at 12:25:58PM +0100, Gilbert Cao wrote:
  
  I have quickly looked into the source code of both cp and gqview, and it 
  seems
  that cp relies on utimes(), and gqview relies on utime().
  
 
 Hi,
 I have finally done my little investigation when applying utime() or utimes()
 to a SMB file path :
 
 In both case, the access and modification times are preserved.
 So it seems that the cp and tar utilities does not its job about
 preserving times over SMB path (I still don't know why ...).
 
 I have a source code example available, if anyone is interested.

Hi, again.
This time, I have done more investigation in the src/bin/cp source code
and I have finally found the problem :

In SMB only case, when utimes() is called *BEFORE* the fd of the newly
created file is close(), it does not do anything.

I have made a little patch to correct this.
So please, committers, can the correction be applied to the cp utility
(Perhaps it is the same problem in the tar utility) ?

I will be very grateful.

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network

--- ./src/bin/cp/utils.c.orig   Sat Nov 12 22:21:45 2005
+++ ./src/bin/cp/utils.cFri Dec 30 19:23:04 2005
@@ -204,8 +204,6 @@
 * to remove it if we created it and its length is 0.
 */
 
-   if (pflag  setfile(fs, to_fd))
-   rval = 1;
if (pflag  preserve_fd_acls(from_fd, to_fd) != 0)
rval = 1;
(void)close(from_fd);
@@ -213,6 +211,14 @@
warn(%s, to.p_path);
rval = 1;
}
+   /*
+* To preserve times in SMB to.p_path, 
+* setfile() should be call *AFTER* we have closed the file
+* descriptors. As we have closed the descriptors, we should
+* pass -1 instead of the `to_fd` value
+*/
+   if (pflag  setfile(fs, -1))
+   rval = 1;
return (rval);
 }
 


pgpUxT0IgiDs8.pgp
Description: PGP signature


One hour offset with smbfs

2005-12-30 Thread Gilbert Cao
Hi,

I just ran into a small problem with modification time with smbfs :
My smb client machine is a FreeBSD 6.0 with GMT+1.
My smb server machine is a FreeBSD 5.4 with also GMT+1.

I have noticed a one hour offset between a file's modification time when
I `ls -l file` from the smb client machine and the same file's
modification time when I `ls -l file` from the smb server machine.
That file stands in a smb shared directory, on the smb server.

More, I have noticed this, only for a datetime like 1st April, 2005.
For a datetime like 1st December 2005, the problem does not occur.

For example,
from the smb client side, I see a modification time of
2005-04-01 00:00:00, and
from the smb server side, I see a modification time of
2005-03-31 23:00:00.

When I do a `touch -t 20050401.00 file` from the smb server side,
I see 2005-04-01 01:00:00, from the smb client side.
When I do a `touch -t 20050401.00 file` from the smb client side,
I see 2005-03-31 23:00:00, from the smb server side.

It seems that it is only a matter with summer time.

Anyone know if something can be done about this ?
I guess the problem is on the smbfs client side ...

Thanks in advance.

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgpb1AsML73cW.pgp
Description: PGP signature


Re: Preserve date when cp over smbfs

2005-12-29 Thread Gilbert Cao
On Wed, Dec 28, 2005 at 12:25:58PM +0100, Gilbert Cao wrote:
 
 I have quickly looked into the source code of both cp and gqview, and it seems
 that cp relies on utimes(), and gqview relies on utime().
 

Hi,
I have finally done my little investigation when applying utime() or utimes()
to a SMB file path :

In both case, the access and modification times are preserved.
So it seems that the cp and tar utilities does not its job about
preserving times over SMB path (I still don't know why ...).

I have a source code example available, if anyone is interested.

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgpIq0Z68l8pw.pgp
Description: PGP signature


Preserve date when cp over smbfs

2005-12-28 Thread Gilbert Cao
Hi, the list.

I have noticed some small problem when copying files over SMB.
My samba server (port version 3.0.8,1) is running on a FreeBSD 5.4
STABLE.
My samba client is running on a FreeBSD 6.0 STABLE.

When I copy a single file with the cp utility, with -p flag, to
a smbfs mounted directory, the modification datetime is not preserved and it
is set to the current datetime :
$ cp -p myfile /path/to/smbmountdir/

The same thing occurred with the tar utility :
$ tar cpf - myfile | tar xpvf - -C /path/to/smbmountdir/

However, I have tried to copy the same file to the same smbfs mounted
directory, with gqview (port version 2.0.1_1) and the modification datetime is 
preserved.

I have quickly looked into the source code of both cp and gqview, and it seems
that cp relies on utimes(), and gqview relies on utime().

Is there any other way for the cp and tar utilities to preserve file
datetime over SMB ?
In the problem comes from the smbfs kernel module ? or the cp and tar
utility ?

In the future, I would just like to avoid loading gqview, just to copy
files with preserve datetime :
cp and tar seems more natural :p

Regards.

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgpInPzKgenBL.pgp
Description: PGP signature


Re: Preserve date when cp over smbfs

2005-12-28 Thread Gilbert Cao
Hi,

On Wed, Dec 28, 2005 at 10:53:53PM +0100, Martin P. Hansen wrote:
 On Wed, 28 Dec 2005, Gilbert Cao wrote:
  When I copy a single file with the cp utility, with -p flag, to
  a smbfs mounted directory, the modification datetime is not preserved and it
  is set to the current datetime :
 
 I've had this problem too, cp was also emitting a warning about utimes:
 
 mph# mount -t smbfs -o-Eiso8859-1:cp850,-f660 //[EMAIL PROTECTED]/e$ /mnt
 mph% cp -p INFO /mnt
 cp: utimes: /mnt/INFO: Operation not permitted

I don't have this warning when copying files.
All my mount directories are owned by my current (the one who does the
copy)

 
 This was because I wasn't ``owner'' of the files. Adding the -u flag fixed 
 this.

so, according to the mount_smbfs(8), the -u flag is not needed in my
case.

 
 mph# mount -t smbfs -o-Eiso8859-1:cp850,-f660,-umph //[EMAIL PROTECTED]/e$ 
 /mnt
 
 Now my modification time is preserved.

The problem still persists in my case :
My samba server is a FreeBSD machine (//[EMAIL PROTECTED]/e$ - I guess it is a
Windows machine)

But I still don't know why modification time is preserved when copying
with gqview ...

-- 

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network



pgpBVTO5UEYlm.pgp
Description: PGP signature