Re: sosend() and mbuf

2009-08-04 Thread Maslan
> When you did kern_open() without creating kernel thread, it worked, > because kern_open() used file descriptor table from your current > (userland) process. In FreeBSD 7.x kthread_create() creates a process > without file descriptor table, so you can't use kern_open() and actually > you shouldn't

Re: sosend() and mbuf

2009-08-04 Thread Maslan
Guys, Here is the code, just scroll down and change kthread_create2() to kthread_create() and it will crash NOTE: i'm still working on the socket part, u can commend it. Something wrong with proc0, and I can't figure it out khttp.c Description: Binary data _

Re: sosend() and mbuf

2009-08-04 Thread Maslan
> kernel threads may not have a file descriptor table. > so kern_open may not work on kernel processes.. > (just speculating) But the module's main thread belogs to proc, why this process could use kern_open() and proc0 don't ___ freebsd-hackers@freebsd.

Re: sosend() and mbuf

2009-08-04 Thread Maslan
lags, pages, &p2); OpenKETA:kthread_create() error = fork1(curthread, RFFDG | RFPROC | RFSTOPPED | flags, pages, &p2); I'll give it a try and see if it works. BUT i still can't understand why kern_open() don't work, except in the original thread. On Tue, Aug

Re: sosend() and mbuf

2009-08-04 Thread Maslan
yes kio http://people.freebsd.org/~pjd/misc/kernio/ However, It's outdated. On Tue, Aug 4, 2009 at 9:56 AM, Ed Schouten wrote: > * Maslan wrote: >> > Is it possible to call kern_open() from within a kernel thread anyway? >> I think yes, It worked on the parent threa

Re: sosend() and mbuf

2009-08-04 Thread Maslan
> Is it possible to call kern_open() from within a kernel thread anyway? I think yes, It worked on the parent thread before creating a new kthread. See OpenKETA source, its using the same approach. > kern_open() depends on a file descriptor table, right? Yes, it returns a fd in the curthread->td_re

Re: sosend() and mbuf

2009-08-04 Thread Maslan
I'm getting crazy, I don't know why kern_open() works in the module's main thread, but when I use it in another thread created by kthread_create() it crashes the kernel ??? On Tue, Aug 4, 2009 at 9:30 AM, Ed Schouten wrote: > Hi, > > * Maslan wrote: >> man kthre

Re: sosend() and mbuf

2009-08-04 Thread Maslan
man kthread says: The kthread_create() function is used to create a kernel thread. The new thread shares its address space with process 0, the swapper process, and runs in kernel mode only. However, when i checked the pid & tid of the new created thread it was not the same as the parent

Re: sosend() and mbuf

2009-08-03 Thread Maslan
I'm running out 7.2-RELEASE-p2 Here is my bt GNU gdb 6.1.1 [FreeBSD] Copyright 2004 Free Software Foundation, Inc. GDB is free software, covered by the GNU General Public License, and you are welcome to change it and/or distribute copies of it under certain conditions. Type "show copying" to see

Re: sosend() and mbuf

2009-08-03 Thread Maslan
return 1; } return 0; } I've to finish up this problem to go back for the first one. Can you figure out what's wrong with this code, it works when I call thread_main() rather than kthread_create((void *)thread_main, . Thanks a lot 2009/8/3 Dag-Erling Smørgrav : >

sosend() and mbuf

2009-08-03 Thread Maslan
Hello Guys, I can't find useful information on sosend(), I would like to send some plain text through sosend() Here is what i got so far, I don't know how to use mbuf with sosend() to achieve this. ret = socreate(PF_INET, &s, SOCK_STREAM, IPPROTO_TCP, curthread->td_ucred, curthread);

Re: Controlling a process

2008-12-02 Thread Maslan
setrlimit(2) Ok thanks a lot On Tue, Dec 2, 2008 at 10:37 AM, Eygene Ryabinkin <[EMAIL PROTECTED]> wrote: > Maslan, good day. > > Tue, Dec 02, 2008 at 09:53:09AM +, Maslan wrote: >> What is the best way to control a process (running in chroot env): >> 1- Execut

Controlling a process

2008-12-02 Thread Maslan
Hi guys, What is the best way to control a process (running in chroot env): 1- Execution time 2- Memory limit And to be able to kill the process when it breaks this limits. Finally, i would like to know the exit status of the process or the signal that killed it (sigfault, .) The idea is tha

Re: Is there any way to increase the KVM?

2008-05-31 Thread Maslan
Your are right PAE is for i386, i mean try running i386 freebsd with PAE enabled rather than amd64. PAE will let you access 64GB which is far than you got. On Sat, May 31, 2008 at 7:01 PM, Tz-Huan Huang <[EMAIL PROTECTED]> wrote: > On Sun, Jun 1, 2008 at 2:54 AM, Maslan <[EMAIL PROTE

Re: Is there any way to increase the KVM?

2008-05-31 Thread Maslan
Hi, is PAE enabled in your kernel config ? Thanks On Sat, May 31, 2008 at 5:52 AM, Tz-Huan Huang <[EMAIL PROTECTED]> wrote: > Hi, > > Our nfs server is running 7-stable/amd64 with 8G ram, the size of zfs > pool is 12T. We have set vm.kmem_size and vm.kmem_size_max to > 1.5G, but the kernel still

Re: vkernel & GSoC, some questions

2008-03-17 Thread Maslan
Hi all, Aren't we working on a FreeBSD/Xen port ??? I think we don't need a Linux like KVM or DragonFly's vkernel, if we could run FreeBSD in dom0. Thank a lot On Mon, Mar 17, 2008 at 3:09 AM, Kip Macy <[EMAIL PROTECTED]> wrote: > On Sun, Mar 16, 2008 at 8:06 PM, Adrian Chadd <[EMAIL PROTECTED]

Re: ATAPI dvdreader always fails on a particular DVD movie title

2008-01-19 Thread Maslan
Hi, I got some errors like this when trying to burn a data cd/dvd. I've filled a PR : http://www.freebsd.org/cgi/query-pr.cgi?pr=119374 Machine: HP Pavilion dv6000 CD/DVD: DVDR wrote: > I tried to make a backup copy of one DVD that I own and 'dvdbackup' > always fails at a particular point. > > R

Fwd: pgk_add segmentation fault

2007-11-08 Thread Maslan
-- Forwarded message -- From: Kris Kennaway <[EMAIL PROTECTED]> Date: Nov 8, 2007 1:44 PM Subject: Re: pgk_add segmentation fault To: Maslan <[EMAIL PROTECTED]> Maslan wrote: > Hi, > > It seems that pkg_add tries to executes ldconfig which itself cause >

Re: pgk_add segmentation fault

2007-11-08 Thread Maslan
Hi, It seems that pkg_add tries to executes ldconfig which itself cause the segmentation fault. On Nov 8, 2007 7:44 AM, Aharon Schkolnik <[EMAIL PROTECTED]> wrote: > Hi ! > > pkg_add is crashing with a segmentation fault: > > pkg_add -v mysql-client-5.1.22.tbz > Requested space: 3809856 bytes,

Re: pkg_add doesn't keep dependent pkgs

2007-11-06 Thread Maslan
That would be great. I'll wait for the patch On Nov 6, 2007 1:01 PM, Garrett Cooper <[EMAIL PROTECTED]> wrote: > Maslan wrote: > >> Package dependencies may change, depending on the user settings and > >> port maintainers configuration for the port (i.e. M

Re: pkg_add doesn't keep dependent pkgs

2007-11-06 Thread Maslan
> Package dependencies may change, depending on the user settings and > port maintainers configuration for the port (i.e. Makefiles). The same > sort of applies to packages as well. > Or were you referring to just packages instead of ports based > package metadata :)? > Or maybe a bette

pkg_add doesn't keep dependent pkgs

2007-11-03 Thread Maslan
Hi, pkg_add -rK seems not to keep the packages dependencies so as the package itself. i found this: http://lists.freebsd.org/pipermail/freebsd-bugbusters/2006-August/000178.html but no answer since then. I don't if this is a bug, or not even implemented feature? Thanks alot -- System Programm

Re: ``Stopping RAM access''

2007-10-30 Thread Maslan
> Can anyone give me a clue, how one can ``stop'' system from accessing RAM, > and then allow it again? I think this has no aim, RAM tests should be done during booting, but u could try to disable interrupts while in kernel mode 'cli' which will prevent any further context switching, then try to

Re: loading a firmware image

2007-07-17 Thread Maslan
I've attached what i did Thanks -- System Programmer -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) -- http://developer.berlios.de/projects/libosdk ___ freebsd-hackers@freebsd.org mailing list http://lists.freeb

Re: loading a firmware image

2007-07-15 Thread Maslan
The firmware is bundled in a seperate kernel module that can be loaded, read and then unloaded. See src/sys/modules/iwifw/iwi_bss for an example of the Makefile magic that creates the kld. if i wrote FIRMWS = filename:shortname:version in the Makefile then i should user firmware_get("shortname")

Re: loading a firmware image

2007-07-15 Thread Maslan
Have you seen the file2c(1) utility? I don't want to run into license troubles. -- System Programmer -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) -- http://libosdk.berlios.de/wiki/ ___ freebsd-hackers@freebsd.

loading a firmware image

2007-07-15 Thread Maslan
Hello, What is the best way to load a firmware image (microcode) ? AFAIK I've to load the image file first in memory then call firmware_register() but my problem is how should i load the image in memory ?? Thanks alot -- System Programmer -- I'm Searching For Perfection, So Even If U Need Porta

Ricoh r5u870

2007-06-10 Thread Maslan
Hi, Is there is any one working on Ricoh r5u870 webcam driver ? Ricoh r5u870 known as hp webcam. Thanks -- System Programmer I'm Searching For Perfection, So Even If U Need Potability U've To Use Assembly ;-) -- http://libosdk.berlios.de/wiki/ ___ fre

Re: Problems compiling BUILDING from STABLE

2007-05-26 Thread Maslan
Have u missed with the CFLAGS ? Sorry, i mean "messed up" --- OS Developer I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) --- http://libosdk.berlios.de ___ freebsd-hackers@freebsd.org mailing list http://lists.fre

Re: Problems compiling BUILDING from STABLE

2007-05-26 Thread Maslan
What's my error? Have u missed with the CFLAGS ? --- OS Developer I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) --- http://libosdk.berlios.de ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.o

FBSD on HP Pavillion dv6000 Family

2007-05-12 Thread Maslan
Hi all, I want to install freebsd-6.2 on my new laptop rather than win vista, but by doing some googling i found that almost everything will not work. any resources/links for drivers even if still untested, i would like to help. Thanks -- I'm Searching For Perfection, So Even If U Need Portabi

Re: Floating-point in kernel space

2007-03-10 Thread Maslan
It would be helpful to know why you need this support as well I just wanted to know the idea behind not having FP in kernel-space. Thanks, Maslan ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers

Floating-point in kernel space

2007-03-09 Thread Maslan
Hello, I think i've seen somewhere but i don't remember that floating point arithmetic is not allowed in kernel space, if that's right, can anyone please tell why ??? and why not not emulate the floating point in kernel space ??? Thanks -- I'm Searching For Perfection, So Even If U Need Portabi

Re: fsck

2006-09-25 Thread Maslan
I've got a /usr partition with some problems. During boot it fails and I'm prompted to run fsck manually. I do so and when fsck has finished it asks me to run it again, and again, and again...it seems to find the same errors each time. It never seems to repair anything. It worked fine on errors it

Re: ARP Spoofing

2006-09-03 Thread Maslan
You can use static arp entries on all the involved hosts/routers, to hardwire a MAC-address to an IP-address. This can be done with 'arp -s ' on FreeBSD. Such static arp entries will not be overridden by incoming arp replies and will ensure that outgoing IP packets are sent to the right mac addre

ARP Spoofing

2006-09-03 Thread Maslan
Hello All I was trying to find a solution to ARP Spoofing on my local network, i've tried to use IPSTEALTH option, but this didn't help. Is there is any solution for preventing the ARP Spoofing inside the kernel such as in the tcp/ip layer or in the ethernet driver itself. i'm sorry if its not the

Re: Alternative compiler toolchain ?

2006-07-01 Thread Maslan
There is also NwCC under BSDL but it still not as mature as gcc http://nwcc.sf.net -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http://www.maslanlab.org http://libosdk.berlios.de ___ freebsd-hackers@freebsd.org

Re: Sysinstall sucks

2006-05-17 Thread Maslan
Strange enough, since sysinstall writes to disk ONLY after you set all options and press YES. BTW at (1) you write that sysinstall had finished before your MBR was wiped out. So did sysinstall finish, or it catch the some signal? Stas It didn't run at all fdisk, it catch a some signal and cr

Sysinstall sucks

2006-05-17 Thread Maslan
Hi I was updating my system from 5.4 to 6.1, i did a fresh install, but after sysinstall finishes it had damaged the MBR. I have 1 ext3 partitions and 2 ufs partitions, one for dfly and the other for fbsd. The other thing that during the installation i wanted to repartition, but when i click parti

Re: Zero Copy, FreeBSD and Linus Torvalds opinion

2006-05-01 Thread Maslan
On 5/1/06, Dag-Erling Smørgrav <[EMAIL PROTECTED]> wrote: Allen <[EMAIL PROTECTED]> writes: > If you watch Revolution OS, Linus points out that his main thing for > doing Linux was that he wanted something like he had used at the > university he was at and he says it was SunOS. Sun OS / Solaris,

Re: Accessing SSH from a C program

2006-02-24 Thread Maslan
> I try to copy some files securely from one machine to another. What is > the fastest and easiest way to accomplish this task? Can I access SSH > routines in C (is there a library) or is it better just to call "scp" > externally? You would better check this http://freshmeat.net/projects/libssh/

Config options

2005-11-15 Thread Maslan
hi hackers, i would appreciate if any one told me how to : 1- add a new option for config. 2- disable an option without removing it. 3- re-enable a disabled option. thanks alot -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http://libosdk.berlios.de http://

Re: Moving Files

2005-10-04 Thread Maslan
On 10/4/05, John Baldwin <[EMAIL PROTECTED]> wrote: > On Monday 03 October 2005 03:24 pm, Maslan wrote: > > hello, > > i was wondering what/where changes should i do to make files when > > moving a file from directory to another in the kernel source. > > for exa

Moving Files

2005-10-03 Thread Maslan
document or webpage that discuss this stuff ? thanks you very much Maslan -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http://www.maslanlab.org ___ freebsd-hackers@freebsd.org mailing list http://lists.f

Re: Bootstrapping install from GRUB

2005-07-15 Thread Maslan
You can chian load your BSD. root (hd0,0,a) # if hd0,0 is your kernel's UFS chainloader +1 boot or you can load the loader root (hd0,0,a) kernel /boot/loader boot On 7/15/05, Ryan Nowakowski <[EMAIL PROTECTED]> wrote: > On Fri, Jul 15, 2005 at 05:19:09PM +0200, Simon 'corecode' Schubert wrote: >

Re: Cross-Compiling FreeBSD

2005-07-11 Thread Maslan
> Hello Maslan, > > > hi guys > > what about cross-compiling freebsd-5.4 from a different BSD as openbsd > > or even linux. > > how can i accomplish this ??? > > AFAIK, only NetBSD allows to do this with their source. I've never > heard of suc

Cross-Compiling FreeBSD

2005-07-09 Thread Maslan
hi guys what about cross-compiling freebsd-5.4 from a different BSD as openbsd or even linux. how can i accomplish this ??? -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http://www.maslanlab.org ___ freebsd-hack

GmailFS

2005-06-26 Thread Maslan
hello guys can not the FUSE http://fuse.sourceforge.net ported to freebsd ? it would be nice to test the gmail fs on freebsd http://richard.jones.name/google-hacks/gmail-filesystem/gmail-filesystem.html -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http

Re: To C++ or not to C++

2005-06-25 Thread Maslan
>To quote the mailing list charter: > This is a forum for technical discussions related to FreeBSD. This is > the primary technical mailing list. It is for individuals actively > working on FreeBSD, to bring up problems or discuss alternative > solutions. Individuals interested in following the

Re: To C++ or not to C++

2005-06-24 Thread Maslan
i don't think this is the suitable mailling list to ask this question On 6/24/05, Seán C. Farley <[EMAIL PROTECTED]> wrote: > On Fri, 24 Jun 2005, Ryan Sommers wrote: > > > Greetings all... I'm about to undertake a major software engineering > > project and I can't decide between C or C++ and wa

Re: kld problem

2005-06-22 Thread Maslan
i don't know if kld should check if the module is used or not before unloading it. but i should. On 6/22/05, Mauser <[EMAIL PROTECTED]> wrote: > Unloading syscall kernel module can cause a system crash. It occurs when we > unload the module while a process is executing our syscall. Example: > >

Re: Screen Resolution

2005-05-24 Thread Maslan
i think freebsd 5.3 is using Xfree86 not Xorg while 5.4 uses XOrg, but i cann't remember On 5/24/05, Max Laier <[EMAIL PROTECTED]> wrote: > On Tuesday 24 May 2005 15:16, Hervé Kergourlay wrote: > > Just one simple question on the screen resolution on FreeBSD 5.3 > > > > I change the xinitrc to la

which function

2005-05-22 Thread Maslan
hi what and where is the function that is responsible for printing the bsd logo on startup? sorry for than question but i'm a new in hacking the bsd and my time is very limited. -- I'm Searching For Perfection, So Even If U Need Portability U've To Use Assembly ;-) http://www.maslanlab.org

Re: files refused to delete

2005-05-11 Thread Maslan
i've booted in single mode and ran fsck but this didn't fixed the problem but fsck prints the inode of the corrupted file, so i used clri and removed the inode then ran fsck again , and everything was ok. but after rebooting : 1)in multiuser: and running fsck it output an error 2)in single: and run

Re: files refused to delete

2005-05-09 Thread Maslan
(703 frags, 242147 blocks, 0.0% fragmentation) ** /dev/ad0s3e (NO WRITE) ** Last Mounted on /usr ** Phase 1 - Check Blocks and Sizes INCORRECT BLOCK COUNT I=196742 (4 should be 0) CORRECT? no ** Phase 2 - Check Pathnames MISSING '.' I=197304 OWNER=maslan MODE=40755 SIZE=512 MTIME=May 5

Re: files refused to delete

2005-05-06 Thread Maslan
(703 frags, 242147 blocks, 0.0% fragmentation) ** /dev/ad0s3e (NO WRITE) ** Last Mounted on /usr ** Phase 1 - Check Blocks and Sizes INCORRECT BLOCK COUNT I=196742 (4 should be 0) CORRECT? no ** Phase 2 - Check Pathnames MISSING '.' I=197304 OWNER=maslan MODE=40755 SIZE=512 MTIME=May 5

files refused to delete

2005-05-04 Thread Maslan
when i've extract a bz2 file containing filenames in other encodings (arabic), the file names appears ??? and it refuses to delete , however i deleted them from linux but the fsck created a hard link to them in lost+found and this hard links refused to deleted, it also created a hard link to my hom

Re: about execute assembly exapmles under freebsd

2005-04-25 Thread Maslan
hey if u need u to use linux calling way u will need to brandelf the executable (if it's elf) On 4/24/05, Tetsuji Maverick Rai <[EMAIL PROTECTED]> wrote: > I refined my code to make the binary shorter. Your code is in Linux > system call convention (ie, arguments are in eax,ebx,ecx...), however