mmap and MAP_NOSYNC

2002-06-18 Thread joy ganguly
Hi all, Hi, I want to use mmap as a means of doing IPC between unrelated processes. I do *not* want the data to hit the disk. So this is what I do :- fd = open(file, O_RDWR); p = mmap(fd, MAP_NOSYNC | MAP_SHARED); mlock(p, len); /* Whack around with shmem */ Now my question is , once I have

Adaptec 3950 and SMP...

2000-07-10 Thread Joy Ganguly
hi all, i have a L440GX+ intel server motherboard running 2 P3. The motherboard has an on-board scsi controller aic7896 (ahc0, ahc1). Additionally i have added an "Adaptec 3950 scsi controller" board(ahc2, ahc3). When i boot an uniprocessor kernel everything works fine. However when i boot a mu

Adaptec 3950 and SMP...

2000-07-10 Thread Joy Ganguly
hi all, i have a L440GX+ intel server motherboard running 2 P3. The motherboard has an on-board scsi controller aic7896 (ahc0, ahc1). Additionally i have added an "Adaptec 3950 scsi controller" board(ahc2, ahc3). When i boot an uniprocessor kernel everything works fine. However when i boot a mul

Tigon firmware...

2000-06-27 Thread Joy Ganguly
hi all, I have been looking into the Tigon firmware code and i am totalyy puzzled about this: there is no place in the code where trp->local_mem_conf.rx_buf_consumer is incremented. (except in h_mac_rx_comp_nohost() which is not called) The tigon documentation says that it should be incremented b

mmap and file writes...???

2000-06-16 Thread Joy Ganguly
hi all, i have a question regarding mmap and file write. a file is mmap'ed and data is written into the mapped region. now the same region is written. (as shown below) buf = mmap(NULL, len, PROT_READ | PROT_WRITE, MAP_SHARED, fd, 0); . . /* some data put in buf */ . write(fd, buf, len); now

question abt top...

2000-06-14 Thread Joy Ganguly
hi all, what does CPU0 in the STATE field of "top" mean. i am running a SMP kernel. a process utilizes 99% of cpu and shows CPU0 in its STATE field. thanx in advance joy To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message

Freeing PQ_CACHE pages at interrupt time??

2000-06-02 Thread Joy Ganguly
hi all, Why cant pages in the PQ_CACHE queue be freed at interrupt time. as far as i could see these pages are clean, though they are still associated with the object. So what prevents us from dissociating them from the object . we dont have to do any io and hence not block. well maybe i am miss

Re: S5933 PCI Adapter..??

2000-06-01 Thread Joy Ganguly
Dennis wrote: > At 12:13 PM 6/1/00 -0600, Warner Losh wrote: > >In message <[EMAIL PROTECTED]> Dennis writes: > >: Have you done bus performance testing with this card? Given the > >: architechture of the AMCC part, it seems highly improbable that you will be > >: able to get high throughput with

QUEUE_VMIO...???

2000-05-31 Thread Joy Ganguly
hi all, what is the significance of QUEUE_VMIO buffer (struct buf) queue ?? as far as i could see they are not used at allbut maybe i am wrong. thanx in advance joy To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message

S5933 PCI Adapter..??

2000-05-26 Thread Joy Ganguly
hi all, i have a atm oc3 care which uses the amcc S5933 PCI adapter. however the driver reports "unable to map mem" at boot time. i used pciconf to read the configuration space base address registers and all of them showed 0x. however when i write all 1's t the base registers they give me

blocks and fragments???

2000-05-23 Thread Joy Ganguly
hi all, do disk addresses in struct dinode ( di_db[] array) address block addresses or fragment addresses?? the comment in dinode.h says they are block addresses. but fs.h says addresses are capable of addressing fragments. will somebody please explain this?? thanx all joy To Unsubscribe: se

disk buffer allocation??

2000-05-23 Thread Joy Ganguly
hi all, i am working on a project to do a zero copy tranfer from a netwrok buffer to a file. i need to know about buffer allocation in freeBSD. ive read the source but there are a few queries: i) what is meant by the B_MALLOC flag?? it seems if this flag is set the buffers memory is malloced and

Re: SMP and APIC???

2000-05-22 Thread Joy Ganguly
[EMAIL PROTECTED] wrote: > > i have compiled freeBSD 3.4 SMP. but when i try to boot it the kernel > > shows "Testing APIC 8254" and then it hangs. earlier i had run mptable > > and it showed:I/O APICs: > > -- > > {Lots of stuff} > > > > APIC ID Version State Ad

SMP and APIC???

2000-05-22 Thread Joy Ganguly
hi i have compiled freeBSD 3.4 SMP. but when i try to boot it the kernel shows "Testing APIC 8254" and then it hangs. earlier i had run mptable and it showed:I/O APICs: -- {Lots of stuff} APIC ID Version State Address 2 0x20usable

SMP kernel compilation??

2000-05-22 Thread Joy Ganguly
hi all, i tried to compile a SMP kernel . but when it tries to load the kernel it gives me " undefined symbol" messages. the messages are:- intr_machdep.o(.data+0xc0): undefined reference to `Xtsintr0' intr_machdep.o(.data+0xc4): undefined reference to `Xtsintr1' intr_machdep.o(.data+0xc8): unde

OBJ_OPT???

2000-05-19 Thread Joy Ganguly
hi all what does the flag OBJ_OPT mean?? i read it deals with some sort of IO optimization. but i dont know what it actually does. any insights on this?? thanx joy To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message

Re: Question about file write????

2000-05-19 Thread Joy Ganguly
Matthew Dillon wrote: > :I am sorry that i missed this point in my previous post. well the problem with > :the mmap is that my device does not have a buffer always. earlier the 'read' > :ioctl on the device used to sleep till a buffer was available. what does the > :mmap do?? can it block?? i am

contigmalloc and mmap??

2000-05-18 Thread Joy Ganguly
hi i have a buffer obtained from contigmalloc. now i want to mmap it to user space. i have done this in linux but unfortunately i am a freebsd newbie. i read the code and it appeared that the device mmap routine is passed an offset and it has to return the physical page frame no so that the neces

KVA to physical address

2000-05-18 Thread Joy Ganguly
hi all how to get a physical address from a kernel virtual address (the KVA is obtained from contigmalloc() ) thanx in advance -joy To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message

KVA to physical???

2000-05-18 Thread Joy Ganguly
hi all how to get a physical address from a kernel virtual address (the KVA is obtained from contigmalloc() ) thanx in advance -joy To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message

Re: Question about file write????

2000-05-18 Thread Joy Ganguly
Matthew Dillon wrote: > > I think it would be a whole lot easier to implement mmap() on the > device, then allow the user process to mmap() the device buffer > and read() and write() it directly. I don't think you need to > implement any ioctl's for this problem. > > fd = ope

Re: Question about file write????

2000-05-18 Thread Joy Ganguly
Matthew Dillon wrote: > I think it would be a whole lot easier to implement mmap() on the > device, then allow the user process to mmap() the device buffer > and read() and write() it directly. I don't think you need to > implement any ioctl's for this problem. > > fd = open

Re: Question about file write????

2000-05-17 Thread Joy Ganguly
Alfred Perlstein wrote: > bcopy should be using the hand optimized code, I think you may have > to explain more of what you're doing if anyone is going to be able > to help. well this is what i am doing: i have a device buffer in contiguous physical memory. i want to write that buffer into a fi

Re: Question about file write????

2000-05-17 Thread Joy Ganguly
Alfred Perlstein wrote: > * Joy Ganguly <[EMAIL PROTECTED]> [000517 09:41] wrote: > > > > hi all, > > > > i have written a special ioctl which writes data into a file from a buffer in > > kernel memory. it invokes fo->fo_write() and involves one

Question about file write????

2000-05-17 Thread Joy Ganguly
hi all, i have written a special ioctl which writes data into a file from a buffer in kernel memory. it invokes fo->fo_write() and involves one copy from kernel mem to disk cache. however this takes substantially more time than an ordinary write which copies from user space to the disk cache. a