From rvsaldana2@netzero.com  Wed Aug 18 17:54:00 2004
Return-Path: <rvsaldana2@netzero.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 2D15016A4CE
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 18 Aug 2004 17:54:00 +0000 (GMT)
Received: from outbound28-2.lax.untd.com (outbound28-2.lax.untd.com [64.136.28.160])
	by mx1.FreeBSD.org (Postfix) with SMTP id DB1F343D41
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 18 Aug 2004 17:53:59 +0000 (GMT)
	(envelope-from rvsaldana2@netzero.com)
Received: from outbound29-sr.lax.untd.com (webmail02.lax.untd.com [10.130.30.142])
	by smtpout02.lax.untd.com with SMTP id AABAUHF6EA7WNAZA
	for <freebsd-gnats-submit@FreeBSD.org> (sender <rvsaldana2@netzero.com>);
	Wed, 18 Aug 2004 10:53:08 -0700 (PDT)
Received: (from rvsaldana2@netzero.com) 
 by webmail02.lax.untd.com (jqueuemail) id J5B7JXNH; Wed, 18 Aug 2004 10:53:03 PDT
Received: from [216.177.2.219] by webmail02.lax.untd.com with HTTP:
	Wed, 18 Aug 2004 17:52:28 GMT
Message-Id: <20040818.105303.11674.464546@webmail02.lax.untd.com>
Date: Wed, 18 Aug 2004 17:52:28 GMT
From: "rvsaldana2@netzero.com" <rvsaldana2@netzero.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: RE:3Com CXM756 PCMCIA card modem

>Number:         70639
>Category:       kern
>Synopsis:       [patch] 3Com CXM756 PCMCIA card modem
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    imp
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Aug 18 18:00:34 GMT 2004
>Closed-Date:    Mon Jan 10 17:33:10 MST 2005
>Last-Modified:  Mon Jan 10 17:33:10 MST 2005
>Originator:     
>Release:        
>Organization:
>Environment:
>Description:
              3Com 3CXM756 problem on FreeBSD 5.2.1-Release
 
 Summary: 3Com CXM756 PCMCIA PCCard works but needs configuration.
This is my attempt to help anyone who is having trouble configuring their
card on FreeBSD 5.2.1-Release. Modem works unsure about the ethernet.
This is a multifunction card.
 
 Raymond V Saldana	
 rvsaldana2@netzero.com
 
 card tested on a:
 
 Dell Inspiron 8000 laptop
 1 Ghz 128MB
 15 inch LCD screen
 Linksys 10/100 EtherFast PCCard
 3Com 3CXM756 56K Global GSM & Cellular
 Modem PC Card with X-jack connector
 Model 3CXM756
 
 Operating System:
 FreeBSD 5.2.1-Release
 
 note:
 				
 This work is based on the patch that was sent to me by Andrew Belashov<bela@orel.ru>
 many thanks Andrew.
 
 When I first installed this card on the FreeBSD 5.2.1-Release I received the following output from the dmesg report.
 
 <#dmesg report before the patch applied#>
 
 CIS is too long ------truncating
 pccard1: Card has no functions
 cbb1:PCCard card activation failed
 
 I contacted freebsd-mobile@freebsd.org and Andrew Belashov responded with the following patch included below. 
 
 Once the patch was applied to the newly rebuilt kernel, the 3Com CXM756. 
 
 FreeBSD5.2.1-Release was now able to detect the 3Com CXM756 card,
 
  but with one problem I was unable to get the modem to respond until I edited the /etc/remote file and added the following line below. Make sure pccard is enabled in /etc/pccard.conf
 
 <#insert the dmesg report after card now detects the 3Com PCMCIA card#>
 
 sio0 port 0x3f8-0x3ff irq 4 on acpi0
 sio0: type 16550A
 
 sio4: <3Com Megahertz 3CXM756/3CCM756> at port 0x2f8-0x2ff irq 10 function 0 config 33 on pccard1
 sio4: type 16550A
 sio4: unable to activate interrupt in fast mode - using normal mode
 
 
 
 First of all you will need to patch and compile a new kernel with pccard enabled:
 
 Install the source code for FreeBSD on your computer and apply the following patch
 below. It should be installed in the /usr/src/sys directory. Use the command below to patch your source code. I assume you know how to compile your FreeBSD kernel
 and patch source code if you don't, read the FreeBSD handbook. Run the command below to patch your source code as root of course.
 
 
    patch - p1 </usr/src/sys/dev/exca
 
 #Copy the file below and save it into a file called exca.c.diff
 
 --- exca.c.diff begins here ---
 --- sys/dev/exca/exca.c.orig    Tue Oct  7 08:29:04 2003
 +++ sys/dev/exca/exca.c Thu Jul 15 22:51:02 2004
 @@ -180,9 +180,12 @@
  {
         struct mem_map_index_st *map;
         struct pccard_mem_handle *mem;
 +       uint32_t offset;
 
         map = &mem_map_index[win];
         mem = &sc->mem[win];
 +       offset = ((mem->cardaddr >> EXCA_CARDMEM_ADDRX_SHIFT) -
 +           (mem->addr >> EXCA_SYSMEM_ADDRX_SHIFT)) & 0x3fff;
         exca_putb(sc, map->sysmem_start_lsb,
             (mem->addr >> EXCA_SYSMEM_ADDRX_SHIFT) & 0xff);
         exca_putb(sc, map->sysmem_start_msb,
 @@ -201,9 +204,9 @@
             (mem->addr >> EXCA_MEMREG_WIN_SHIFT) & 0xff);
 
         exca_putb(sc, map->cardmem_lsb,
 -           (mem->cardaddr >> EXCA_CARDMEM_ADDRX_SHIFT) & 0xff);
 +           offset & 0xff);
         exca_putb(sc, map->cardmem_msb,
 -           ((mem->cardaddr >> (EXCA_CARDMEM_ADDRX_SHIFT + 8)) &
 +           ((offset >> 8) &
             EXCA_CARDMEM_ADDRX_MSB_ADDR_MASK) |
             ((mem->kind == PCCARD_A_MEM_ATTR) ?
             EXCA_CARDMEM_ADDRX_MSB_REGACTIVE_ATTR : 0));
 --- exca.c.diff ends here ---
 
 After code is patched then compile and install the newly built kernel
 
 On my laptop which is a Dell Inspiron 8000 this card was now recognized
 on sio4 so after looking at the documentation in the FreeBSD Handbook section 17.5.2
 you must edit the following section in /etc/remote below to enable FreeBSD 5.2.1-Release to be able to open your 3Com CCXM756 modem for PPPD dialout. Otherwise KPPP would just hang on the operating system.
 
 <#edit /etc/remote file and insert the following line below in bold type to the following section#>
 
 Finger friendly shortcuts
 sio0|com1:dv=/dev/cuaa0:br#9600:pa=none:
 sio1|com2:dv=/dev/cuaa1:br#9600:pa=none:
 sio2|com3:dv=/dev/cuaa2:br#9600:pa=none:
 sio3|com4:dv=/dev/cuaa3:br#9600:pa=none:
 
 #I inserted the following line below to refelect the outcome of my dmesg report or
 what ever sio serial port number the 3CXM756 comes up on. Check your dmesg output to see which sio number your modem is detected on and modify it accordingly.
 
 sio4|com5:dv=/dev/cuaa4:br#9600:pa=none:
 
 I used the command stty -f /dev/cuaa4 -a, to detect the location of the modem.
 
 Then you should be able to use the modem to dialout. I hope this patch gets included in future releases of FreeBSD.
 
 Additional information:
 
 I use KPPP to connect to the internet:
 
 Make sure you create /etc/ppp/options file
 
 #touch /etc/ppp/options
 
 Also add your internet service providers nameserver and dns information in
 the /etc/resolv.conf file.
 
 Good Luck,
 
 Raymond V Saldana	
 rvsaldana2@netzero.com
 
 
 recommended  reading:
 
 The Complete FreeBSD by Greg Lehey
 Unix Adminstration Handbook by Evi Nemeth
 The Free BSD Handbook by the FreeBSD project
 
 
 
 
 ________________________________________________________________
 The best thing to hit the Internet in years - NetZero HiSpeed!
 Surf the Web up to FIVE TIMES FASTER!
 Only $14.95/ month -visit www.netzero.com to sign up today!
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: gnats-admin->freebsd-bugs 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Aug 19 07:06:09 GMT 2004 
Responsible-Changed-Why:  
Reclassify from the 'pending' category.  There was no annotation 
as to which PR this initially applied to so GNATS places it there. 

Also, in the future, please wrap text lines at less than 80 
characters.  Thanks. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=70639 
Responsible-Changed-From-To: freebsd-bugs->imp 
Responsible-Changed-By: arved 
Responsible-Changed-When: Sat Aug 28 17:04:21 GMT 2004 
Responsible-Changed-Why:  
Over to imp, who wrote exca(4). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=70639 
State-Changed-From-To: open->closed 
State-Changed-By: imp 
State-Changed-When: Mon Jan 10 17:30:53 MST 2005 
State-Changed-Why:  
Committed patch, it fixes my 3com cards, but I Don't have a 3com modem. 


http://www.freebsd.org/cgi/query-pr.cgi?pr=70639 
>Unformatted:
