so, how to correlate them? Any mapping files or mechanism inside the
device?

On Jul 1, 7:08 pm, Kristopher Micinski <krismicin...@gmail.com> wrote:
> No, that is all at the framework level, it's calling *into* the kernel
> through the standard posix system call interface... (namely, open,
> read, write, etc..)
>
> kris
>
>
>
>
>
>
>
> On Sun, Jul 1, 2012 at 10:07 PM, M <xuetao....@gmail.com> wrote:
> > you mean these system calls are from kernel?
>
> > // ---------------------------------------------------
> >     // Native Codes
> >     // ---------------------------------------------------
>
> >     static native void createSocketImpl(FileDescriptor fd,
> >             boolean preferIPv4Stack);
>
> >     /*
> >      * Allocate a datagram socket in the IP stack. The socket is
> > associated with
> >      * the <code>aFD</code>.
> >      *
> >      * @param aFD the FileDescriptor to associate with the socket
> > @param
> >      * preferIPv4Stack IP stack preference if underlying platform is
> > V4/V6
> >      * @exception SocketException upon an allocation error
> >      */
> >     static native void createDatagramSocketImpl(FileDescriptor aFD,
> >             boolean preferIPv4Stack) throws SocketException;
>
> >     static native int readSocketImpl(FileDescriptor aFD, byte[] data,
> >             int offset, int count, int timeout) throws IOException;
>
> >     static native int readSocketDirectImpl(FileDescriptor aFD, int
> > address,
> >             int offset, int count, int timeout) throws IOException;
>
> >     static native int writeSocketImpl(FileDescriptor fd, byte[] data,
> >             int offset, int count) throws IOException;
>
> >     static native int writeSocketDirectImpl(FileDescriptor fd, int
> > address,
> >             int offset, int count) throws IOException;
>
> >     static native void setNonBlockingImpl(FileDescriptor aFD,
> >             boolean block);
>
> > On Jun 30, 10:58 pm, Kristopher Micinski <krismicin...@gmail.com>
> > wrote:
> >> On Fri, Jun 29, 2012 at 12:15 PM, M <xuetao....@gmail.com> wrote:
> >> > Hi, alll,
>
> >> > Is there any mechanism inside the Android that could correlate
> >> > Framework API with its corresponding kernel system calls?
>
> >> > For example, one Internet API call:  java.net.Socket.<init>().  How
> >> > could we know which system calls from kernel support such api calls
> >> > from the framework?
>
> >> > Thanks for your help.
>
> >> > M
>
> >> In that specific example, and in many others, the framework is calling
> >> down into native code through system wrappers (from harmony, is it
> >> still called that...?)
>
> >> To handle these cases, when you get down to a baseline set of system
> >> calls (i.e., the traditional unix ones..), the code is in classes like
> >> OSNetworkSystem.java ..., for example (the first google result..):
>
> >>http://code.google.com/p/sipdroid/source/browse/trunk/src/org/sipdroi...
>
> >> There's a similar implementation for the filesystem, etc...
>
> >> kris
>
> > --
> > unsubscribe: android-kernel+unsubscr...@googlegroups.com
> > website:http://groups.google.com/group/android-kernel

-- 
unsubscribe: android-kernel+unsubscr...@googlegroups.com
website: http://groups.google.com/group/android-kernel

Reply via email to