?? migrating to linux kernel 2_6 -- part 5 migrating apps to the 2_6 kernel and nptl.htm
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0050)http://linuxdevices.com/articles/AT6753699732.html -->
<HTML><HEAD><TITLE>Migrating to Linux kernel 2.6 -- Part 5: Migrating apps to the 2.6 kernel and NPTL</TITLE>
<META http-equiv=Content-Type content="text/html; charset=gb2312"><LINK
title="LinuxDevices News"
href="http://www.LinuxDevices.com/backend/headlines.rss"
type=application/rss+xml rel=alternate><LINK title=MyCSS
href="Migrating to Linux kernel 2_6 -- Part 5 Migrating apps to the 2_6 kernel and NPTL.files/style.css"
type=text/css rel=stylesheet><LINK href="/images/favicon.ico"
rel="shortcut icon">
<META
content="Linux, embedded, mobile, devices, uClinux, RTLinux, RTAI, real time, realtime, real-time, embedding, embed, computing, software, operating system, systems, device drivers, distributions, open source, GPL, news, links, articles, FAQ, forum, hardware, computer, chips, processors, system-on-chip, boards, single board computer, SBC, PC/104, PC-104, PC104, PC 104, PCI-104, CPCI, CompactPCI, EBX, ETX, XTX, ETX Express, COM Express, VoIP, ATCA, PDA, UMPC, set top box"
name=keywords>
<META
content="News, views, articles, and discussion on using Linux in mobile and embedded devices."
name=description>
<META content="MSHTML 6.00.2900.3243" name=GENERATOR></HEAD>
<BODY text=#000000 bgColor=#ffffff topMargin=0><FONT size=1><!-- START OF OMNITURE CODE -><!-- SiteCatalyst code version: G.9.Copyright 1997-2004 Omniture, Inc. More info available at http://www.omniture.com -->
<SCRIPT language=JavaScript><!-- var s_pageName=""var s_server=""var s_channel=""var s_pageType=""var s_prop1=""var s_prop2=""var s_prop3=""var s_prop4=""var s_prop5=""var s_campaign=""var s_state=""var s_zip=""var s_events=""var s_products=""var s_purchaseID=""var s_eVar1=""var s_eVar2=""var s_eVar3=""var s_eVar4=""var s_eVar5=""var s_account="ziffdavisglobal, ziffdavislinuxdevices, ziffdavisenterpriseglobal"//--></SCRIPT>
<SCRIPT language=JavaScript
src="Migrating to Linux kernel 2_6 -- Part 5 Migrating apps to the 2_6 kernel and NPTL.files/s_code_remote.js"></SCRIPT>
<!-- End SiteCatalyst code version: G.9. --><!-- END OF OMNITURE CODE --></FONT><!-- begin banner tag -->
<TABLE cellSpacing=0 cellPadding=0 width=728 align=center border=0>
<TBODY>
<TR>
<TD>
<CENTER><IFRAME border=0 marginWidth=0 marginHeight=0
src="Migrating to Linux kernel 2_6 -- Part 5 Migrating apps to the 2_6 kernel and NPTL.files/script_.htm"
frameBorder=no width=728 scrolling=no
height=90> <a href="http://ad.doubleclick.net/jump/entzd.linuxdevices/desktop;pos=top;dcopt=ist;zdid=a221772;tile=1;sz=728x90;ord=<script=JavaScript>document.write(Math.round(Math.random()*10000000000));</script>?"" style="border-width:0px;height:90px;width:728px;"><img src="http://ad.doubleclick.net/ad/entzd.linuxdevices/desktop;pos=top;dcopt=ist;zdid=a221772;tile=1;sz=728x90;ord=<script=JavaScript>document.write(Math.round(Math.random()*10000000000));</script>?" style="border:0; height: 90; width:728;" /></a> </IFRAME></CENTER></TD></TR></TBODY></TABLE><!-- End banner tag -->
<TABLE cellSpacing=0 cellPadding=0 width="100%" align=center border=0>
<TBODY>
<TR>
<TD vAlign=center align=left width=410>
<TABLE cellSpacing=0 cellPadding=0 border=0 valign="bottom">
<TBODY>
<TR>
<TD height=5></TD></TR>
<TR>
<TD><A href="http://linuxdevices.com/"><IMG
src="Migrating to Linux kernel 2_6 -- Part 5 Migrating apps to the 2_6 kernel and NPTL.files/ld-logo-short.gif"
border=0></A></TD></TR></TBODY></TABLE></TD>
<TD vAlign=center align=right>
<TABLE cellSpacing=0 cellPadding=0 width=150 border=0><!-- vertical spacer follows - remove if not required -->
<TBODY>
<TR>
<TD height=5></TD></TR>
<TR>
<TD noWrap align=middle width=200><FONT face=Arial,Helvetica
size=1>Click here to learn<BR>about this Sponsor:</FONT></TD></TR>
<TR>
<TD align=middle><!-- begin tagline-ad tag -->
<TABLE cellSpacing=0 cellPadding=0 width=170 border=1>
<TBODY>
<TR>
<TD align=middle><IFRAME border=0 marginWidth=0 marginHeight=0
src="F:\Migrating to Linux kernel 2_6 -- Part 5 Migrating apps to the 2_6 kernel and NPTL.files\script_(1).htm"
frameBorder=no width=170 scrolling=no
height=60> <a href="http://ad.doubleclick.net/jump/entzd.linuxdevices/desktop;pos=top;dcopt=ist;zdid=a221772;tile=1;sz=170x60;ord=<script=JavaScript>document.write(Math.round(Math.random()*10000000000));</script>?"" style="border-width:0px;height:170px;width:60px;"><img src="http://ad.doubleclick.net/ad/entzd.linuxdevices/desktop;pos=top;dcopt=ist;zdid=a221772;tile=1;sz=170x60;ord=<script=JavaScript>document.write(Math.round(Math.random()*10000000000));</script>?" style="border:0; height: 170; width:60;" /></a> </IFRAME></TD></TR></TBODY></TABLE><!-- end ad tag --></TD></TR></TBODY></TABLE></TD></TR>
<TR>
<TD height=5></TD></TR>
<TR>
<TD align=left colSpan=2><FONT face=Arial,Helvetica size=2><A
href="http://linuxdevices.com/"><B>Home</B></A> | <A
href="http://linuxdevices.com/news"><B>News</B></A> | <A
href="http://linuxdevices.com/articles"><B>Articles</B></A> |
<A
href="http://linuxdevices.com/cgi-bin/survey/survey.cgi"><B>Polls</B></A>
| <A
href="http://linuxdevices.com/cgi-bin/board/UltraBoard.pl"><B>Forum</B></A>
</FONT></TD></TR>
<TR>
<TD height=5></TD></TR></TBODY></TABLE><!-- Search Form ================== -->
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=0 width="100%" bgColor=#fcec9c
border=1><TBODY>
<TR>
<FORM action=/cgi-bin/article_view.cgi method=post>
<TD align=middle><BR><SMALL>Keywords:</SMALL> <INPUT size=25
name=sk> <SMALL>Match:</SMALL> <SELECT size=1 name=st> <OPTION
value=all selected>All keywords</OPTION> <OPTION value=any>Any
keyword</OPTION> <OPTION value=exact>Exact phrase</OPTION></SELECT> <INPUT type=submit value="Search articles" name=view>
</TD></FORM></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
<TABLE cellPadding=2 width="100%">
<TBODY>
<TR><!-- to enable left column, uncomment the following line --><!-- <td valign="top" width="18%"> --><!-- also, add hash at left of include on next line and remove spacesaround the expression --><!-- include virtual="/files/columnleft.html" --><!-- finally, uncomment following line to enable left column --><!-- </td> -->
<TD vAlign=top width="64%">
<TABLE>
<TBODY>
<TR>
<TD>
<TABLE width="100%">
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=6 width="100%" border=1>
<TBODY>
<TR>
<TH width="100%" bgColor=#fcec9c><FONT
face=Arial,Helvetica size=2>Migrating to Linux kernel
2.6 -- Part 5: Migrating apps to the 2.6 kernel and
NPTL</FONT></TH></TR>
<TR>
<TD width="100%" height=20><FONT face=Arial,Helvetica
size=2>by Peter Dibble and Willian von Hagen (Mar. 11,
2004)</FONT><BR><BR><FONT face=Arial,Helvetica
size=3><B>Foreword</B> -- For most application
developers, changes between the 2.4 and 2.6 kernel
families have little direct impact. However, kernel and
system changes that affect how applications spawn and
manage other processes and threads are a significant
exception to this rule. This whitepaper discusses topics
related to migrating existing applications to the 2.6
kernel and the Native POSIX Threading Library (NPTL).
<BR><BR>This paper is the last in a <A
href="http://linuxdevices.com/articles/AT6753699732.html#series"><U>series</U></A>
of articles from TimeSys on migrating to the 2.6 Linux
kernel. Material is largely vendor-neutral.
<BR><BR>Enjoy! . . .<BR><BR>
<HR>
<BR>
<CENTER><B>Migrating applications to the 2.6 kernel and
NPTL</B></CENTER><BR>For most application developers,
the majority of the changes made to the Linux kernel
between the 2.4 and 2.6 kernel families have little
direct impact. Most kernel changes only manifest
themselves through increased system performance and
capacity. Kernel and system changes that affect how
applications spawn and manage other processes and
threads are a significant exception to this rule.
<BR><BR>The 2.6 Linux kernel introduces a new, improved
threading model that is implemented through the NPTL.
The adoption of a new threading model has significant
implications for developers, system run-time libraries
such as the GNU C library (glibc), shared application
libraries, and so on. This white paper provides an
overview of basic threading concepts, discusses new and
existing Linux threading models, and then highlights the
sorts of application changes that you might have to make
to existing multi-threaded applications in order to
enable them to work correctly with NPTL under the 2.6
Linux kernel.<BR><BR><B>Threading 101</B><BR><BR>On
multi-processing systems such as Linux, the concept of
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -