· KLDP.org · KLDP.net · KLDP Wiki · KLDP BBS ·
Submitting Patches

How to Get Your Change Into the Linux Kernel or Care And Operation Of Your Linus Torvalds

¸®´ª½º Ä¿³Î¿¡ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ ¹Ý¿µÇÏ´Â ¹ý ȤÀº ¿©·¯ºÐÀÇ Linux Torvalds¸¦ Ä¡·áÇÏ°í ¼ö¼úÇÏ´Â ¹ý


For a person or company who wishes to submit a change to the Linux kernel, the process can sometimes be daunting if you're not familiar with "the system." This text is a collection of suggestions which can greatly increase the chances of your change being accepted.

¸®´ª½º Ä¿³Î¿¡ ÆÐÄ¡¸¦ Àû¿ëÇÏ°í ½ÍÀº °³ÀÎÀ̳ª ȸ»çÀÇ °æ¿ì, "½Ã½ºÅÛ"¿¡ Àͼ÷ÇÏÁö ¾Ê´Ù¸é ±× ÀýÂ÷¿¡ ´Ù¼Ò Ç®ÀÌ Á×À» ¼öµµ ÀÖ´Ù. ÀÌ ¹®¼­´Â ¿©·¯ºÐÀÇ ÆÐÄ¡µéÀÌ ¸¹ÀÌ ¹Ý¿µµÉ ¼ö ÀÖµµ·Ï Çϱâ À§ÇÑ Á¦¾ÈµéÀ» ´ã°í ÀÖ´Ù.

Read Documentation/SubmitChecklist for a list of items to check before submitting code. If you are submitting a driver, also read Documentation/SubmittingDrivers.

Äڵ带 Á¦ÃâÇϱâ Àü, üũÇغ¼ ¸ñ·ÏµéÀ» À§ÇØ Documentation/SubmitChecklist¸¦ Àоî¶ó. ¿©·¯ºÐÀÌ µå¶óÀ̹ö¸¦ Á¦ÃâÇÏ°í ÀÖ´Ù¸é Documentation/SubmittingDrivers ¶ÇÇÑ Àоî¾ß ÇÑ´Ù.


SECTION 1 - CREATING AND SENDING YOUR CHANGE

¼½¼Ç 1 - ÆÐÄ¡¸¦ ¸¸µé¾î º¸³»±â


1) "diff -up"


1) "diff -up"


Use "diff -up" or "diff -uprN" to create patches.

ÆÐÄ¡¸¦ ¸¸µé±â À§ÇØ "diff -up" ³ª "diff -uprN"À» »ç¿ëÇ϶ó.

All changes to the Linux kernel occur in the form of patches, as generated by diff(1). When creating your patch, make sure to create it in "unified diff" format, as supplied by the '-u' argument to diff(1). Also, please use the '-p' argument which shows which C function each change is in - that makes the resultant diff a lot easier to read. Patches should be based in the root kernel source directory, not in any lower subdirectory.

¸®´ª½º Ä¿³ÎÀÇ ¸ðµç º¯°æ»çÇ×µéÀº diff(1)¿¡ ÀÇÇØ ¸¸À»¾îÁö±â ¶§¹®¿¡ ÆÐÄ¡ÀÇ ÇüÅ·Π³ªÅ¸³»¾îÁø´Ù. ÆÐÄ¡¸¦ ¸¸µé¶§´Â '-u' ¿É¼ÇÀ» »ç¿ëÇÏ¿© "unified diff" ¾ç½ÄÀ¸·Î ¸¸µé¾î¶ó. ¶ÇÇÑ '-p' ¿É¼ÇÀ» »ç¿ëÇÏ¿© º¯°æµÈ ¿µ¿ªÀÇ C ÇÔ¼öÀ̸§À» ³ªÅ¸³»¾î¶ó. ÀÌ·¸°Ô ÇÏ´Â °ÍÀº Àб⠽¬¿î ÆÐÄ¡¸¦ ¸¸µé¾î ³¾ °ÍÀÌ´Ù. ÆÐÄ¡´Â Ä¿³Î ¼Ò½ºÀÇ ÇÏÀ§ µð·ºÅ丮°¡ ¾Æ´Ñ ·çÆ® µð·ºÅ丮¸¦ ±âÁØÀ¸·Î ¸¸µé¾îÁ®¾ß ÇÑ´Ù.

To create a patch for a single file, it is often sufficient to do:

ÇϳªÀÇ ÆÄÀϸ¸À» À§ÇÑ ÆÐÄ¡¸¦ ¸¸µé·Á¸é ÈçÈ÷ ´ÙÀ½°ú °°ÀÌ ÇÑ´Ù.

SRCTREE= linux-2.6 MYFILE= drivers/net/mydriver.c

cd $SRCTREE cp $MYFILE $MYFILE.orig vi $MYFILE # make your change cd .. diff -up $SRCTREE/$MYFILE{.orig,} > /tmp/patch

SRCTREE= linux-2.6 MYFILE= drivers/net/mydriver.c

cd $SRCTREE cp $MYFILE $MYFILE.orig vi $MYFILE # make your change cd .. diff -up $SRCTREE/$MYFILE{.orig,} > /tmp/patch


To create a patch for multiple files, you should unpack a "vanilla", or unmodified kernel source tree, and generate a diff against your own source tree. For example:

º¹¼ö°³ÀÇ ÆÄÀϵéÀ» À§ÇÑ ÆÐÄ¡¸¦ ¸¸µé±â À§Çؼ­´Â "vanilla(¿ªÀÚÁÖ: ÀüÇô ¼Õ´ëÁö ¾ÊÀº ¿ø·¡ÀÇ ¾ÐÃà ÆÄÀÏ ÇüÅÂÀÇ Ä¿³Î ¼Ò½º)"¸¦ ¾ÐÃàÇØÁö Çϰųª Ä¿³Î ¼Ò½º Æ®¸®¸¦ º¯°æÇÏÁö ¸»¾Æ¾ß ÇÑ´Ù. ±×¸®°í ¿©·¯ºÐÀÇ ¼Ò½º Æ®¸®¿Í diff¸¦ ÇÏ¿© ¸¸µé¾î³½´Ù. ¿¹¸¦ µé¸é ´ÙÀ½°ú °°´Ù.

MYSRC= /devel/linux-2.6

tar xvfz linux-2.6.12.tar.gz mv linux-2.6.12 linux-2.6.12-vanilla diff -uprN -X linux-2.6.12-vanilla/Documentation/dontdiff \
linux-2.6.12-vanilla $MYSRC > /tmp/patch

MYSRC= /devel/linux-2.6

tar xvfz linux-2.6.12.tar.gz mv linux-2.6.12 linux-2.6.12-vanilla diff -uprN -X linux-2.6.12-vanilla/Documentation/dontdiff \
linux-2.6.12-vanilla $MYSRC > /tmp/patch


"dontdiff" is a list of files which are generated by the kernel during the build process, and should be ignored in any diff(1)-generated patch. The "dontdiff" file is included in the kernel tree in 2.6.12 and later. For earlier kernel versions, you can get it from <http://www.xenotime.net/linux/doc/dontdiff>.

"dontdiff"´Â build °úÁ¤ Áß¿¡ Ä¿³ÎÀÌ ¸¸µé¾î³»´Â ÆÄÀϵéÀÇ ¸®½ºÆ®ÀÌ¸ç ±× ÆÄÀϵéÀº diff(1)°¡ ¸¸µé¾î³»´Â ÆÐÄ¡¿¡¼­ ¹«½ÃµÈ´Ù. "dontdiff" ÆÄÀÏÀº 2.6.12 ÀÌ»óÀÇ Ä¿³Î Æ®¸®¿¡ Æ÷ÇԵǾî ÀÖ´Ù. ±×º¸´Ù ¾Õ¹öÁ¯µéÀÇ Ä¿³ÎÀÇ °æ¿ì, ¿©·¯ºÐÀº ´ÙÀ½¿¡¼­ dontdiffÆÄÀÏÀ» ¾òÀ» ¼ö ÀÖ´Ù. <http://www.xenotime.net/linux/doc/dontdiff>.

Make sure your patch does not include any extra files which do not belong in a patch submission. Make sure to review your patch -after- generated it with diff(1), to ensure accuracy.

¿©·¯ºÐÀÇ ÆÐÄ¡°¡ Á¦ÃâÇÏ·Á´Â ÆÐÄ¡¿¡ ÇØ´çµÇÁö ¾Ê´Â ±âŸ ´Ù¸¥ ÆÄÀϵéÀ» Æ÷ÇÔÇÏÁö ¾Êµµ·Ï Ç϶ó. diff(1)¸¦ ÅëÇØ ÆÐÄ¡¸¦ ¸¸µé¾î ³½ ÀÌÈÄ¿¡µµ Á¤È®ÇÏ°Ô Çϱâ À§ÇØ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ °ËÅäÇ϶ó.

If your changes produce a lot of deltas, you may want to look into splitting them into individual patches which modify things in logical stages. This will facilitate easier reviewing by other kernel developers, very important if you want your patch accepted. There are a number of scripts which can aid in this:

¿©·¯ºÐÀÇ º¯°æÀÌ ¸¹Àº µ¨Å¸(¿ªÀÚÁÖ:ºÎ¼öÀûÀÎ °Í)¸¦ ¸¸µé¾î³½´Ù¸é ³í¸®ÀûÀÎ ´Ü°è·Î ±¸ºÐÇÏ¿© °¢°¢ÀÇ ÆÐÄ¡µé·Î ³ª´©°í ½ÍÀ» °ÍÀÌ´Ù. ±×·¸°ÔÇÏ´Â °ÍÀº ´Ù¸¥ Ä¿³Î °³¹ßÀÚµéÀÇ °ËÅ並 ´õ ½±°ÔÇϸç ÀÌ´Â ¿©·¯ºÐÀÇ ÆÐÄ¡°¡ ¹Ý¿µµÇ±æ ¹Ù¶õ´Ù¸é ¸Å¿ì Áß¿äÇÑ °ÍÀÌ´Ù. ±×·± ³ë·ÂÀ» µµ¿ï¼ö ÀÖ´Â ¸¹Àº ½ºÅ©¸³Æ®µéÀÌ ÀÖ´Ù.


Andrew Morton's patch scripts: http://www.zip.com.au/~akpm/linux/patches/ Instead of these scripts, quilt is the recommended patch management tool (see above). ÀÌ ½ºÅ©¸³Æ®µé ´ë½Å quilt°¡ ÃßõµÇ´Â ÆÐÄ¡°ü¸® ÅøÀÌ´Ù.(À§¸¦ º¸¶ó)


Andrew Morton's patch scripts: http://www.zip.com.au/~akpm/linux/patches/


2) Describe your changes.

2) ÆÐÄ¡¿¡ ´ëÇÑ ¼³¸í

Describe the technical detail of the change(s) your patch includes.

¿©·¯ºÐÀÇ ÆÐÄ¡°¡ Æ÷ÇÔÇÏ°í ÀÖ´Â ¼öÁ¤»çÇ׵鿡 ´ëÇÏ¿© ±â¼úÀûÀ¸·Î ÀÚ¼¼ÇÏ°Ô ¼³¸íÇ϶ó.

Be as specific as possible. The WORST descriptions possible include things like "update driver X", "bug fix for driver X", or "this patch includes updates for subsystem X. Please apply."

°¡´ÉÇÑ ÇÑ ¸íÈ®ÇÏ°Ô Ç϶ó. ÁÁÁö ¾ÊÀº ¼³¸íµéÀº ´ÙÀ½°ú °°Àº °ÍµéÀ» Æ÷ÇÔÇÒ °ÍÀÌ´Ù. "µå¶óÀ̹ö XÀÇ ¾÷µ¥ÀÌÆ®", "µå¶óÀ̹ö XÀÇ ¹ö±× ¼öÁ¤", "ÀÌ ÆÐÄ¡´Â subsystem X¿¡ ´ëÇÑ ¾÷µ¥ÀÌÆ®¸¦ Æ÷ÇÔÇÑ´Ù. ¹Ý¿µÇØ´Þ¶ó"

If your description starts to get long, that's a sign that you probably need to split up your patch. See #3, next.

¿©·¯ºÐÀÇ ¼³¸íÀÌ ±æ°Ô ½ÃÀÛÇÑ´Ù¸é ¾Æ¸¶µµ ¿©·¯ºÐÀº ÆÐÄ¡¸¦ ´õ ³ª´©¾î¾ß ÇÒ ÇÊ¿ä°¡ ÀÖ´Ù´Â ½ÅÈ£ÀÏ °ÍÀÌ´Ù. ´ÙÀ½, 3¹øÀ» ÂüÁ¶Ç϶ó.


3) Separate your changes.

3) ÆÐÄ¡ ³ª´©±â

Separate _logical changes_ into a single patch file.

³í¸®ÀûÀÎ ´ÜÀ§¸¶´Ù ÇϳªÀÇ ÆÐÄ¡ÆÄÀÏ·Î ³ª´©¾î¶ó

For example, if your changes include both bug fixes and performance enhancements for a single driver, separate those changes into two or more patches. If your changes include an API update, and a new driver which uses that new API, separate those into two patches.

¿¹¸¦µé¾î ¿©·¯ºÐÀÇ ¼öÁ¤ÀÌ ÇϳªÀÇ µå¶óÀ̹ö¿¡ ´ëÇÑ ¹ö±× ¼öÁ¤°ú ¼º´É Çâ»ó µÑ ´Ù¸¦ Æ÷ÇÔÇÏ°í ÀÖ´Ù¸é ±× ¼öÁ¤µéÀ» 2°³ ÀÌ»óÀÇ ÆÐÄ¡µé·Î ³ª´©¾î¶ó. ¿©·¯ºÐÀÇ ¼öÁ¤ÀÌ API ¾÷µ¥ÀÌÆ®¿Í »õ·Î¿î API¸¦ »ç¿ëÇÏ´Â »õ·Î¿î µå¶óÀ̹ö·Î ÀÌ·ç¾îÁ³´Ù¸é 2°³ÀÇ ÆÐÄ¡·Î ³ª´©¾î¶ó.

On the other hand, if you make a single change to numerous files, group those changes into a single patch. Thus a single logical change is contained within a single patch.

´Ù¸¥ ÇÑÆí, ¿©·¯ºÐÀÌ ÇϳªÀÇ ¼öÁ¤À» ¸¹Àº ÆÄÀϵé·Î ¸¸µé¾ú´Ù¸é ±×·¯ÇÑ ¼öÁ¤µéÀ» ÇϳªÀÇ ÆÐÄ¡ÆÄÀÏ·Î ¹­¾î¶ó. ±×·¸°ÔÇؼ­ ÇϳªÀÇ ³í¸®Àû ´ÜÀ§ÀÇ ¼öÁ¤Àº ÇϳªÀÇ ÆÐÄ¡³»¿¡ ´ã¾ÆÁú ¼ö ÀÖ°Ô µÈ´Ù.

If one patch depends on another patch in order for a change to be complete, that is OK. Simply note "this patch depends on patch X" in your patch description.

ÇÑ ÆÐÄ¡°¡ ¿ÏÀüÇØÁö±âÀ§ÇÏ¿© ´Ù¸¥ ÆÐÄ¡¿¡ ÀÇÁ¸ÀûÀÏ °æ¿ìµµ ¹®Á¦ ¾ø´Ù. °£´ÜÇÏ°Ô ¿©·¯ºÐÀÇ ÆÐÄ¡¼³¸í¿¡ ´Ù¸§°ú °°ÀÌ ÀÛ¼ºÇ϶ó. "ÀÌ ÆÐÄ¡´Â ÆÐÄ¡ X¿¡ ÀÇÁ¸ÀûÀÌ´Ù."

If you cannot condense your patch set into a smaller set of patches, then only post say 15 or so at a time and wait for review and integration.

¿©·¯ºÐÀÌ ÆÐÄ¡¸¦ ´õ ÀÛÀº ÆÐÄ¡µéÀÇ ¹­À½À¸·Î °£Ã߸± ¼ö ¾ø´Ù¸é ÀÏ´Ü Æ÷½ºÆ®Ç϶ó. ±×¸®°í 15ºÐ Á¤µµ °ËÅä¿Í ÅëÇÕÀ» ±â´Ù·Á¶ó.

4) Style check your changes.

4) ¼öÁ¤µé¿¡ ´ëÇÑ ½ºÅ¸ÀÏ Ã¼Å©

Check your patch for basic style violations, details of which can be found in Documentation/CodingStyle. Failure to do so simply wastes the reviewers time and will get your patch rejected, probably without even being read.

¿©·¯ºÐÀÇ ÆÐÄ¡°¡ Documentation/CodingStyle ÆÄÀÏ¿¡ ÀÖ´Â ±âº»ÀûÀÎ ½ºÅ¸ÀÏÀ» À§¹ÝÇÏ°í ÀÖ´ÂÁö üũÇ϶ó. ½ºÅ¸ÀÏÀ» ÁöÅ°Áö ¾Ê°Ô µÇ¸é °ËÅäÇØÁÖ´Â »ç¶÷µéÀÌ ½Ã°£À» ³¶ºñÇÏ°Ô µÉ °ÍÀÌ°í ¿©·¯ºÐÀÇ ÆÐÄ¡´Â ¾Æ¸¶µµ ÀÐÇôÁö±â´Â Ä¿³ç ¹Þ¾Æµé¿©ÁöÁöµµ ¾ÊÀ» °ÍÀÌ´Ù.

At a minimum you should check your patches with the patch style checker prior to submission (scripts/checkpatch.pl). You should be able to justify all violations that remain in your patch.

¿©·¯ºÐÀº ÃÖ¼ÒÇÑ ÆÐÄ¡¸¦ Á¦ÃâÇϱâ Àü¿¡ ½ºÅ¸ÀÏ Ã¼Ä¿(scripts/checkpatch.pl)¸¦ °¡Áö°í ¿©·¯ºÐÀÇ ÆÐÄ¡µéÀ» äũÇغÁ¾ß ÇÑ´Ù. ¿©·¯ºÐÀº ÆÐÄ¡¿¡ ³²¾ÆÀÖ´Â ¸ðµç À§¹Ý»çÇ×µéÀ» Á¤´çÈ­ÇÒ ¼ö ÀÖ¾î¾ß ÇÑ´Ù.

5) Select e-mail destination.

5) À̸ÞÀÏ ¼ö½Å ¼±ÅÃ

Look through the MAINTAINERS file and the source code, and determine if your change applies to a specific subsystem of the kernel, with an assigned maintainer. If so, e-mail that person.

MAINTAINERS ÆÄÀÏ°ú ¼Ò½ºÄڵ带 Äf¾îº¸°í ¿©·¯ºÐÀÇ ¼öÁ¤ÀÌ Ä¿³ÎÀÇ ¾î¶² subsystem¿¡ ±¹ÇÑµÈ °ÍÀÎÁö, ƯÁ¤ ¸ÞÀÎÅ×ÀÌ³Ê¿Í °ü·ÃµÈ ºÎºÐÀÎÁö¸¦ »ìÆì¶ó. ±×¸®°í³ª¼­ ±× »ç¶÷¿¡°Ô ¸ÞÀÏÀ» º¸³»¶ó.

If no maintainer is listed, or the maintainer does not respond, send your patch to the primary Linux kernel developer's mailing list, linux-kernel@vger.kernel.org. Most kernel developers monitor this e-mail list, and can comment on your changes.

¾î¶² ¸ÞÀÎÅ×À̳ʵµ ¸í½ÃµÇÁö ¾Ê¾Ò°Å³ª ¸ÞÀÎÅ×À̳ʰ¡ ÀÀ´äÇÏÁö ¾Ê´Â´Ù¸é ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ °¡Àå ÁÖ¿äÇÑ ¸®´ª½º Ä¿³ÎÀÇ ¸ÞÀϸµ ¸®½ºÆ®ÀÎ linux-kernel@vger.kernel.org ·Î º¸³»¶ó. ´ëºÎºÐÀÇ Ä¿³Î °³¹ßÀÚµéÀº ÀÌ ¸ÞÀϸµ ¸®½ºÆ®¸¦ º¸°í ÀÖÀ¸¹Ç·Î ¿©·¯ºÐÀÇ ¼öÁ¤¿¡ ´ëÇÑ ÀÇ°ßÀ» °³ÁøÇÒ °ÍÀÌ´Ù.

Do not send more than 15 patches at once to the vger mailing lists!!!

Çѹø¿¡ 15°³ ÀÌ»óÀÇ ÆÐÄ¡¸¦ vger ¸ÞÀϸµ ¸®½ºÆ®·Î º¸³»Áö ¸¶¶ó!!!

Linus Torvalds is the final arbiter of all changes accepted into the Linux kernel. His e-mail address is <torvalds@linux-foundation.org>. He gets a lot of e-mail, so typically you should do your best to -avoid- sending him e-mail.

Linux Torvalds´Â ¸®´ª½º Ä¿³Î¿¡ ¹Þ¾Æµé¿©Áú ¸ðµç ¼öÁ¤µéÀÇ ¸¶Áö¸· ÁßÀçÀÎÀÌ´Ù. ±×ÀÇ À̸ÞÀÏ ÁÖ¼Ò´Â <torvalds@linux-foundation.org>ÀÌ´Ù. ±×´Â ¸¹Àº ¸ÞÀÏÀ» ¹Þ±â ¶§¹®¿¡ ¿©·¯ºÐÀº ±×¿¡°Ô ¸ÞÀÏÀ» º¸³»´Â °ÍÀ» ÃÖ´ëÇÑ ÇÇÇØ¾ß ÇÑ´Ù.

Patches which are bug fixes, are "obvious" changes, or similarly require little discussion should be sent or CC'd to Linus. Patches which require discussion or do not have a clear advantage should usually be sent first to linux-kernel. Only after the patch is discussed should the patch then be submitted to Linus.

¹ö±×¸¦ ¼öÁ¤ÇÏ´Â ÆÐÄ¡¿Í °°Àº "¸í¹éÇÑ" ¼öÁ¤ ÆÐÄ¡µé ¶Ç´Â ±×¿Í ºñ½ÁÇÏ°Ô °ÅÀÇ Åä·ÐÀ» ÇÊ¿ä·Î ÇÏÁö ¾Ê´Â ¼öÁ¤µéÀº Linux¸¦ ÂüÁ¶·Î(CC)·Î Çؼ­ º¸³»¾ß ÇÑ´Ù. Åä·ÐÀ» ÇÊ¿ä·Î Çϰųª ºÐ¸íÇÑ ÀÌÁ¡ÀÌ ¾ø´Â ÆÐÄ¡µéÀº ´ë°³ linux-kernel·Î ¸ÕÀú º¸³»Á®¾ß ÇÑ´Ù. ÆÐÄ¡¸¦ ÃæºÐÈ÷ Åä·ÐÇÑ ÈÄ¿¡ Linux¿¡°Ô º¸³»¾ß ÇÑ´Ù.

6) Select your CC (e-mail carbon copy) list.

6) ÂüÁ¶¸ñ·ÏÀÇ ¼±ÅÃ

Unless you have a reason NOT to do so, CC linux-kernel@vger.kernel.org.

Ưº°ÇÑ ÀÌÀ¯°¡ ¾ø´Ù¸é Ç×»ó linux-kernel@vger.kernel.org¸¦ ÂüÁ¶·Î ³Ö¾î¶ó.

Other kernel developers besides Linus need to be aware of your change, so that they may comment on it and offer code review and suggestions. linux-kernel is the primary Linux kernel developer mailing list. Other mailing lists are available for specific subsystems, such as USB, framebuffer devices, the VFS, the SCSI subsystem, etc. See the MAINTAINERS file for a mailing list that relates specifically to your change.

Linus ÁÖÀ§ÀÇ ´Ù¸¥ Ä¿³Î °³¹ßÀڵ鵵 ¿©·¯ºÐÀÌ ¼öÁ¤ÇÏ´Â °Í¿¡ °üÇØ ¾Ë ÇÊ¿ä°¡ ÀÖ´Ù. ±×·¸°ÔµÇ¸é ´Ù¸¥ Ä¿³Î °³¹ßÀÚµéÀº ¿©·¯ºÐÀÇ ÆÐÄ¡¿¡ ´ëÇÏ¿© ÀڽŵéÀÇ ÀÇ°ßÀ» °³ÁøÇÒ °ÍÀ̸ç Äڵ带 °ËÅäÇÏ°í »õ·Î¿î Á¦¾ÈÀ» ÇÒ °ÍÀÌ´Ù. linux-kernelÀº ÁÖ¿äÇÑ ¸®´ª½º Ä¿³Î °³¹ß ¸ÞÀϸµ ¸®½ºÆ®ÀÌ´Ù. USB, framebuffer ÀåÄ¡µé, VFS, SCSI subsystem°ú °°ÀÌ ´Ù¸¥ ƯÁ¤ ÇÏÀ§½Ã½ºÅÛ¿¡ °ü·ÃµÈ ¸ÞÀϸµ ¸®½ºÆ®µµ ÀÖ´Ù. ¿©·¯ºÐÀÇ ÆÐÄ¡¿Í °ü·ÃÀÖ´Â ¸ÞÀϸµ ¸®½ºÆ®¸¦ ã±âÀ§ÇØ MAINTAINERS ÆÄÀÏÀ» ºÁ¶ó.

Majordomo lists of VGER.KERNEL.ORG at: VGER.KERNEL.ORGÀÇ Majordomo ¸®½ºÆ®µé If changes affect userland-kernel interfaces, please send the MAN-PAGES maintainer (as listed in the MAINTAINERS file) a man-pages patch, or at least a notification of the change, so that some information makes its way into the manual pages.

¼öÁ¤ÀÌ userland-kernel ÀÎÅÍÆäÀ̽º¿¡ ¿µÇâÀ» Áشٸé MAN-PAGES ¸ÞÀÎÅ×À̳ʿ¡°Ô man-pages ÆÐÄ¡¸¦ º¸³»Áְųª Àû¾îµµ ¼öÁ¤ÀÌ ÀÖ´Ù´Â »ç½ÇÀ» ¾Ë·Á ¸Þ´º¾ó ÆäÀÌÁö¿¡ ¹Ý¿µµÇ°Ô µÇ°ÔÇ϶ó.

Even if the maintainer did not respond in step #4, make sure to ALWAYS copy the maintainer when you change their code.

¸ÞÀÎÅ×À̳ʰ¡ ÀÀ´äÇÏÁö ¾Ê¾Ò¾îµµ ¼öÁ¤À» ÇÒ¶§´Â ¸ÞÀÎÅ×À̳ʸ¦ Ç×»ó ÂüÁ¶·Î ³Ö¾î¶ó.

For small patches you may want to CC the Trivial Patch Monkey trivial@kernel.org managed by Adrian Bunk; which collects "trivial" patches. Trivial patches must qualify for one of the following rules:

¼Ò¼ÒÇÑ ÆÐÄ¡ÀÇ °æ¿ì Adrian Bunk¿¡ ÀÇÇØ °ü¸®µÇ´Â trivial@kernel.org ÁÖ¼Ò¸¦ °¡Áö°í ÀÖ´Â rivial Patcch Monkey¸¦ ÂüÁ¶(CC)·Î ³Ö¾î¶ó. ±×°÷Àº "»ç¼ÒÇÑ"ÆÐÄ¡µéÀ» ¸ðÀº´Ù. »ç¼ÒÇÑ ÆÐÄ¡¶ó ÇÔÀº ´ÙÀ½ÀÇ Á¶°ÇµéÀ» ¸¸Á·ÇØ¾ß ÇÑ´Ù.

Spelling fixes in documentation ¹®¼­¿¡ À߸øµÈ ½ºÆ縵 ±³Á¤

Spelling fixes which could break grep(1) grep(1)À» Çϱ⠾î·Æ°Ô ¸¸µå´Â ½ºÆ縵 ±³Á¤

Warning fixes (cluttering with useless warnings is bad) Warning ±³Á¤(¾µ¸ð¾ø´Â warningÀ¸·Î ¾îÁö·´Çô Áö´Â °ÍÀº ³ª»Ú´Ù)

Compilation fixes (only if they are actually correct) ÄÄÆÄÀÏ ±³Á¤(±³Á¤ÇÑ °ÍÀÌ ½ÇÁ¦·Î ¿ÇÀ» °æ¿ì¿¡ ÇÑÇØ)

Runtime fixes (only if they actually fix things) ½ÇÇà½ÃÀÇ ¹®Á¦Á¡ ±³Á¤(½ÇÁ¦·Î ¹®Á¦¸¦ ±³Á¤ÇÑ °æ¿ì¿¡ ÇÑÇØ)

Removing use of deprecated functions/macros (eg. check_region) ¾ÕÀ¸·Î ¾ø¾îÁú°Ô µÉ ÇÔ¼ö³ª ¸ÅÅ©·ÎÀÇ »ç¿ëÀ» Á¦°Å(¿¹. check_region)

Contact detail and documentation fixes ¹®ÀÇó³ª ¹®¼­ÀÇ ±³Á¤

Non-portable code replaced by portable code (even in arch-specific, À̽ļºÀÌ ÁÁÁö ¾ÊÀº Äڵ带 À̽ļºÀÌ ÁÁÀº ÄÚµå·Î ¼öÁ¤(arch¿¡¼­¸¸ »ç¿ëÇÑ´Ù ÇÒÁö¶óµµ)

TODO : since people copy, as long as it's trivial)

Any fix by the author/maintainer of the file (ie. patch monkey in re-transmission mode) ÆÄÀÏÀÇ ÀúÀÚ³ª ¸ÞÀÎÅ×À̳ʿ¡ ÀÇÇÑ ¼öÁ¤(TODO)
URL: <http://www.kernel.org/pub/linux/kernel/people/bunk/trivial/>

7) No MIME, no links, no compression, no attachments. Just plain text.

7) MIME, ¸µÅ©, ¾ÐÃà, ÷ºÎ¸¦ »ç¿ëÇÏÁö ¸»°í text¸¸ »ç¿ëÇ϶ó.

Linus and other kernel developers need to be able to read and comment on the changes you are submitting. It is important for a kernel developer to be able to "quote" your changes, using standard e-mail tools, so that they may comment on specific portions of your code.

Linux¿Í ´Ù¸¥ Ä¿³Î °³¹ßÀÚµéÀº ¿©·¯ºÐÀÌ Á¦ÃâÇÑ ÆÐÄ¡µéÀ» Àаí ÄÚ¸àÆ®ÇØ¾ß ÇÑ´Ù. Ä¿³Î °³¹ßÀÚµéÀº ±âº»ÀûÀÎ À̸ÞÀÏ ÅøÀ» »ç¿ëÇÏ¿© ¿©·¯ºÐÀÇ ¼öÁ¤¿¡ quote(¿ªÀÚÁÖ: ÆÐÄ¡ÀÇ Áß°£Áß°£ ÀοëºÎÈ£¸¦ ³Ö¾î ÀÚ½ÅÀÇ »ý°¢À» ÀÛ¼ºÇÔ)¸¦ ÇÏ¿© ¿©·¯ºÐÀÇ ÄÚµå ÀϺκп¡ ÄÚ¸àÆ®¸¦ ÇÒ ¼ö ÀÖ¾î¾ß ÇÑ´Ù.

For this reason, all patches should be submitting e-mail "inline". WARNING: Be wary of your editor's word-wrap corrupting your patch, if you choose to cut-n-paste your patch.

±×·± ÀÌÀ¯·Î ¸ðµç ÆÐÄ¡µéÀº À̸ÞÀÏÀÇ ³»¿ë¿¡ Á÷Á¢ Æ÷ÇԵǴ ÇüÅ·ΠÁ¦ÃâµÇ¾ß¸¸ ÇÑ´Ù. ÁÖÀÇ: ¿©·¯ºÐÀÌ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ cut-n-pasteÇϱâ·Î Çß´Ù¸é ¿©·¯ºÐÀÌ »ç¿ëÇÏ´Â ÆíÁý±âÀÇ word-wrap ±â´ÉÀÌ ÆÐÄ¡¸¦ ¸Á°¡¶ß¸®Áö ¾ÊÀ»Áö ÁÖÀÇÇØ¾ß ÇÑ´Ù.

Do not attach the patch as a MIME attachment, compressed or not. Many popular e-mail applications will not always transmit a MIME attachment as plain text, making it impossible to comment on your code. A MIME attachment also takes Linus a bit more time to process, decreasing the likelihood of your MIME-attached change being accepted.

ÆÐÄ¡¸¦ ¾ÐÃàÀ¯¹«¿Í´Â »ó°ü¾øÀÌ MIME ÇüÅ·δ ÷ºÎÇÏÁö ¸»¶ó. ³Î¸® »ç¿ëµÇ´Â ¸¹Àº À̸ÞÀÏ ÀÀ¿ëÇÁ·Î±×·¥µéÀÌ Ç×»ó MIME ÷ºÎÆÄÀÏÀ» ¼ø¼öÇÑ text·Î º¸³»Áö ¾ÊÀ» °ÍÀÌ¸ç ±×·Î ÀÎÇÏ¿© ´Ù¸¥ »ç¶÷µéÀº ¿©·¯ºÐÀÇ Äڵ忡 ÄÚ¸àÆ®ÇÒ ¼ö ¾ø°Ô µÉ °ÍÀÌ´Ù. ¶ÇÇÑ MIME ÷ºÎ´Â Linus°¡ ÆÐÄ¡¸¦ ó¸®ÇÏ´Â ½Ã°£À» ´õ µéÀ̵µ·Ï ÇÏ°í ÆÐÄ¡°¡ ¹Þ¾Æµé¿©Áú È®·üÀº ´õ ÁÙ¾îµé°Ô ¸¸µç´Ù.

Exception: If your mailer is mangling patches then someone may ask you to re-send them using MIME.

¿¹¿Ü: ¿©·¯ºÐÀÇ mailer°¡ ÆÐÄ¡µéÀ» ¾û¸ÁÀ¸·Î ¸¸µç´Ù¸é ´©±º°¡´Â ¿©·¯ºÐ¿¡°Ô MIMEÀ» »ç¿ëÇÏ¿© ´Ù½Ã º¸³»´Þ¶ó°í ¿äûÇÒ ¼öµµ ÀÖ´Ù.

WARNING: Some mailers like Mozilla send your messages with -- message header -- Content-Type: text/plain; charset=us-ascii; format=flowed -- message header --

The problem is that "format=flowed" makes some of the mailers on receiving side to replace TABs with spaces and do similar changes. Thus the patches from you can look corrupted.

¹®Á¦´Â "format=flowed"ÀÌ´Ù. ÀÌ°ÍÀº ¹Þ´Â ÃøÀÇ mailerÁßÀÇ ÀϺΰ¡ TABÀ» space·Î ¹Ù²Ùµµ·Ï ¸¸µé¸ç À¯»çÇÑ ´Ù¸¥ ¹®Á¦µéÀ» ¹ß»ýŲ´Ù. ±×·¡¼­ ¿©·¯ºÐÀÇ ÆÐÄ¡°¡ ±úÁ® º¸ÀÏ °ÍÀÌ´Ù.

To fix this just make your mozilla defaults/pref/mailnews.js file to look like: pref("mailnews.send_plaintext_flowed", false); // RFC 2646======= pref("mailnews.display.disable_format_flowed_support", true);

ÀÌ ¹®Á¦¸¦ ¼öÁ¤Çϱâ À§Çؼ­ ¿©·¯ºÐÀÇ ¸ðÁú¶ó defaults/pref/mailnews.js ÆÄÀÏÀ» ´ÙÀ½°ú °°ÀÌ ¼öÁ¤Ç϶ó. pref("mailnews.send_plaintext_flowed", false); // RFC 2646======= pref("mailnews.display.disable_format_flowed_support", true);


8) E-mail size.

8) E-mail Å©±â

When sending patches to Linus, always follow step #7.

Linus¿¡°Ô ÆÐÄ¡¸¦ º¸³¾ ¶§´Â Ç×»ó ¼½¼Ç 7¹ø¿¡¼­ ¸í½ÃÇÑ ´ë·Î Ç϶ó.

Large changes are not appropriate for mailing lists, and some maintainers. If your patch, uncompressed, exceeds 40 kB in size, it is preferred that you store your patch on an Internet-accessible server, and provide instead a URL (link) pointing to your patch.

Å« ÆÐÄ¡´Â ¸ÞÀϸµ ¸®½ºÆ®¿Í ÀϺΠ¸ÞÀÎÅ×À̳ʵ鿡°Ô´Â ÀûÀýÇÏÁö ¾Ê´Ù. ¿©·¯ºÐÀÇ ÆÐÄ¡°¡ ¾ÐÃàÇÏÁö ¾ÊÀº »óÅ·Πũ±â°¡ 40 kB¸¦ ³Ñ°ÔµÈ´Ù¸é ÆÐÄ¡¸¦ ÀÎÅͳÝÀ¸·Î Á¢±Ù °¡´ÉÇÑ ¼­¹ö¿¡ ÀúÀåÇÏ°í ÆÐÄ¡¸¦ °¡¸®Å°´Â URL(link) ·Î ´ëÄ¡ÇÏ´Â °ÍÀÌ ´õ ÁÁÀº ¹æ¹ýÀÌ´Ù.

9) Name your kernel version.

9) ¿©·¯ºÐÀÌ »ç¿ëÇÏ´Â Ä¿³Î ¹öÁ¯ÀÇ ¸í±â

It is important to note, either in the subject line or in the patch description, the kernel version to which this patch applies.

ÆÐÄ¡ÀÇ Á¦¸ñÁÙ ¶Ç´Â ÆÐÄ¡ÀÇ ¼³¸í¿¡ ÆÐÄ¡°¡ Àû¿ëµÇ´Â Ä¿³Î ¹öÁ¯À» ¸í½ÃÇÏ´Â °ÍÀº Áß¿äÇÏ´Ù.

If the patch does not apply cleanly to the latest kernel version, Linus will not apply it.

ÆÐÄ¡°¡ ÃֽŠĿ³Î ¹öÁ¯¿¡ ¿Ã¹Ù¸£°Ô Àû¿ëµÇÁö ¾Ê´Â´Ù¸é Linus´Â ±× ÆÐÄ¡¸¦ Àû¿ëÇÏÁö ¾ÊÀ» °ÍÀÌ´Ù.

10) Don't get discouraged. Re-submit.

10) ÁÂÀýÇÏÁö ¸»°í ´Ù½Ã º¸³»¶ó.

After you have submitted your change, be patient and wait. If Linus likes your change and applies it, it will appear in the next version of the kernel that he releases.

ÆÐÄ¡¸¦ Á¦ÃâÇÑ ÈÄ¿¡ Àγ»½ÉÀ» °¡Áö°í ±â´Ù·Á¶ó. Linus°¡ ¿©·¯ºÐÀÇ ÆÐÄ¡°¡ ¸¾¿¡ µé°í ÆÐÄ¡¸¦ Àû¿ëÇÑ´Ù¸é ¹èÆ÷µÇ´Â ´ÙÀ½ ¹öÁ¯ÀÇ Ä¿³Î¿¡¼­ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ º¸°Ô µÉ °ÍÀÌ´Ù.

However, if your change doesn't appear in the next version of the kernel, there could be any number of reasons. It's YOUR job to narrow down those reasons, correct what was wrong, and submit your updated change.

±×·¯³ª, ¿©·¯ºÐÀÇ ÆÐÄ¡°¡ ´ÙÀ½ Ä¿³Î ¹öÁ¯¿¡ ³ªÅ¸³ªÁö ¾ÊÀ¸¸é ¾Æ¸¶ ¸¹Àº ÀÌÀ¯°¡ ÀÖÀ» °ÍÀÌ´Ù. ±× ÀÌÀ¯¸¦ ã¾Æ À߸øµÈ °ÍÀ» ¼öÁ¤ÇÏ°í ¾÷µ¥ÀÌÆ®ÇÏ¿© ´Ù½Ã º¸³»´Â °ÍÀº ¿©·¯ºÐÀÌ ÇØ¾ß ÇÒ ÀÏÀÌ´Ù.

It is quite common for Linus to "drop" your patch without comment. That's the nature of the system. If he drops your patch, it could be due to

Linus°¡ ¾Æ¹« ¾ð±Þ¾øÀÌ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ "¹ö¸®´Â °Í"Àº ´Ã»ó ÀÖ´Â ÀÏÀÌ´Ù. ±×°ÍÀº ÀÚ¿¬½º·¯¿î °ÍÀÌ´Ù. Linus°¡ ¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ ¹ö¸°´Ù¸é ¾Æ¸¶ ´ÙÀ½ ¹®Á¦µé ¶§¹®ÀÏ °ÍÀÌ´Ù.

* Your patch did not apply cleanly to the latest kernel version. * Your patch was not sufficiently discussed on linux-kernel. * A style issue (see section 2). * An e-mail formatting issue (re-read this section). * A technical problem with your change. * He gets tons of e-mail, and yours got lost in the shuffle. * You are being annoying.

* ¿©·¯ºÐÀÇ ÆÐÄ¡´Â ÃֽŠĿ³Î ¹öÁ¯¿¡ ±ú²ýÀÌ Àû¿ëµÇÁö ¾Ê¾Ò´Ù. * ¿©·¯ºÐÀÇ ÆÐÄ¡´Â linux-kernel¿¡¼­ ÃæºÐÈ÷ Åä·ÐµÇÁö ¾Ê¾Ò´Ù. * ½ºÅ¸ÀÏ ¹®Á¦(2Àý ÂüÁ¶) * À̸ÞÀÏ ¾ç½Ä ¹®Á¦(À̹ø ÀýÀ» ´Ù½Ã Àоî¶ó) * ¿©·¯ºÐÀÇ ÆÐÄ¡ÀÇ ±â¼úÀûÀÎ ¹®Á¦ * Linus´Â ¼öõÅëÀÇ ¸ÞÀÏÀ» ¹Þ¾Ò°í µÚ¼¯¿©¼­ °á±¹ ¿©·¯ºÐÀÇ °ÍÀ» ÀÒ¾î¹ö·È´Ù. * ¿©·¯ºÐÀº Linus¸¦ ±ÍÂú°Ô ÇÏ°í ÀÖ´Ù.


When in doubt, solicit comments on linux-kernel mailing list.

ÀǽɵǸé linux-kernel ¸ÞÀϸµ ¸®½ºÆ®¿¡ È®ÀÎ ¸ÞÀÏÀ» º¸³»ºÁ¶ó.

11) Include PATCH in the subject

11) Á¦¸ñ¿¡ PATCH¶ó´Â ¹®±¸¸¦ Æ÷ÇÔÇ϶ó

Due to high e-mail traffic to Linus, and to linux-kernel, it is common convention to prefix your subject line with PATCH. This lets Linus and other kernel developers more easily distinguish patches from other e-mail discussions.

Linus¿Í linux-kernel¿¡´Â ¸¹Àº ¸ÞÀÏ Æ®·¡ÇÈÀÌ Àֱ⠶§¹®¿¡ ¿©·¯ºÐÀÇ Á¦¸ñ¾Õ¿¡ PATCH¶ó°í ¸í½ÃÇÏ´Â °ÍÀÌ ÀϹÝÀûÀÎ °ü·Ê´Ù. ÀÌ·¸°Ô ÇÔÀ¸·Î½á Linus¿Í ´Ù¸¥ Ä¿³Î °³¹ßÀÚµéÀº ÆÐÄ¡ ¸ÞÀÏÀ» ´Ù¸¥ ¸ÞÀϵé°ú ±¸º°Çϱ⠼ö¿ùÇØÁø´Ù.

12) Sign your work

12) ¿©·¯ºÐÀÇ ÀÛ¾÷¿¡ ´ëÇÑ ½ÎÀÎ

To improve tracking of who did what, especially with patches that can percolate to their final resting place in the kernel through several layers of maintainers, we've introduced a "sign-off" procedure on patches that are being emailed around.

´©°¡ ¹«¾ùÀ» Çß´ÂÁö¸¦ ÆľÇÇϱâ À§Çؼ­(ƯÈ÷, °¢°¢ÀÇ ¸ÞÀÎÅ×À̳ʵéÀÌ °ü¸®ÇÏ´Â ¿©·¯ ·¹À̾îµéÀ» °ÅÄ¡¸ç ÃÖÁ¾º»À» ¸¸µé¾î°¡´Â °æ¿ì) À̸ÞÀÏ¿¡ "sigh-off"¸¦ ÇÏ´Â ÀýÂ÷¸¦ µµÀÔÇß´Ù.

The sign-off is a simple line at the end of the explanation for the patch, which certifies that you wrote it or otherwise have the right to pass it on as a open-source patch. The rules are pretty simple: if you can certify the below:

sign-off´Â ÆÐÄ¡¿¡ ´ëÇÑ ¼³¸í ³¡¿¡ °£´ÜÈ÷ ÇÑ ¶óÀÎÀ¸·Î µé¾î°¡¸ç ¿©·¯ºÐÀÌ ±× ÆÐÄ¡¸¦ ÀÛ¼ºÇß´Ù´Â °ÍÀ̳ª ¶Ç´Â ±× ÆÐÄ¡¸¦ open-source ÆÐÄ¡·Î½á Á¦ÃâÇÒ ±Ç¸®¸¦ °¡Áö°í ÀÖ´Ù´Â °ÍÀ» ÀÔÁõÇÏ´Â °ÍÀÌ´Ù. ±ÔÄ¢Àº »ó´çÈ÷ °£´ÜÇÏ´Ù. ¿©·¯ºÐÀÌ ¾Æ·¡¿Í °°Àº °ÍµéÀ» ÀÔÁõÇÒ ¼ö ÀÖ´Ù¸é TODO
Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:
(a) The contribution was created in whole or in part by me and I
have the right to submit it under the open source license indicated in the file; or

(b) The contribution is based upon previous work that, to the best
of my knowledge, is covered under an appropriate open source license and I have the right under that license to submit that work with modifications, whether created in whole or in part by me, under the same open source license (unless I am permitted to submit under a different license), as indicated in the file; or

(c) The contribution was provided directly to me by some other
person who certified (a), (b) or (c) and I have not modified it.

(d) I understand and agree that this project and the contribution
are public and that a record of the contribution (including all personal information I submit with it, including my sign-off) is maintained indefinitely and may be redistributed consistent with this project or the open source license(s) involved.

then you just add a line saying ¿©·¯ºÐÀº °£´ÜÈ÷ ´ÙÀ½°ú °°ÀÌ ½Ç¸íÀ» »ç¿ëÇÏ¿© ´ÙÀ½°ú °°Àº ¶óÀÎÀ» Ãß°¡ÇÏ¸é µÈ´Ù.
Signed-off-by: Random J Developer <random@developer.example.org>

using your real name (sorry, no pseudonyms or anonymous contributions.) (À¯°¨ÀÌÁö¸¸ °¡¸íÀ̳ª À͸íÀº ¾ÈµÈ´Ù)


Some people also put extra tags at the end. They'll just be ignored for now, but you can do this to mark internal company procedures or just point out some special detail about the sign-off.

ÀϺΠ»ç¶÷µéÀº ÆÐÄ¡ÀÇ ³¡¿¡ ´Ù¸¥ ²¿¸´¸»(tag)¸¦ µÎ±âµµ ÇÑ´Ù. ±×·± °ÍµéÀÌ Áö±ÝÀº ¹«½ÃµÉ °ÍÀÌÁö¸¸ ²¿¸´¸»À» ÅëÇÏ¿© ȸ»ç ³»ºÎ ÀýÂ÷¸¦ Ç¥½ÃÇϰųª sign-off¿¡ °üÇÑ ¸î¸î ¼¼ºÎ»çÇ×À» ³ªÅ¸³»±â À§ÇØ »ç¿ëÇÒ ¼ö ÀÖ´Ù.

13) When to use Acked-by:

TODO: ¿©±â¼­ºÎÅÍ

13) Acked-by¸¦ »ç¿ëÇØ¾ß ÇÒ ¶§

The Signed-off-by: tag indicates that the signer was involved in the development of the patch, or that he/she was in the patch's delivery path.

Signed-off-by: ÀÌ Å±״ ½ÎÀÎÀ» ÇÑ »ç¶÷ÀÌ ÆÐÄ¡ÀÇ °³¹ß¿¡ °ü°èµÇ¾ú°Å³ª ±× »ç¶÷ÀÌ ÆÐÄ¡¸¦ Àü´ÞÇÏ´Â °úÁ¤¿¡ °ü°èµÇ¾î ÀÖ¾ú´Ù´Â °ÍÀ» ³ªÅ¸³½´Ù.

If a person was not directly involved in the preparation or handling of a patch but wishes to signify and record their approval of it then they can arrange to have an Acked-by: line added to the patch's changelog.

¾î´À ÇÑ »ç¶÷ÀÌ ÆÐÄ¡ÀÇ Áغñ³ª 󸮰úÁ¤¿¡ Á÷Á¢ÀûÀ¸·Î °ü¿©ÇÏÁö ¾Ê¾ÒÁö¸¸ ÆÐÄ¡¿¡ ´ëÇÑ ½ÂÀÎÀ» ±â·ÏÇϰųª ³ªÅ¸³»±æ ¿øÇÑ´Ù¸é Acked-by¸¦ »ç¿ëÇÏ¿© ±×·¸°Ô ÇÒ ¼ö ÀÖ´Ù. Acked-by´Â ÆÐÄ¡ÀÇ changelog¿¡ µ¡ºÙ¿©Áö´Â ¶óÀÎÀÌ´Ù.

Acked-by: is often used by the maintainer of the affected code when that maintainer neither contributed to nor forwarded the patch.

Acked-by´Â ÀϹÝÀûÀ¸·Î ¸ÞÀÎÅ×À̳ʰ¡ ÆÐÄ¡¸¦ ¸¸µå´Â µ¥ °øÇåÇÏÁö ¾Ê¾Ò°Å³ª ÆÐÄ¡¸¦ Àü´ÞÇÏ´Â °ÍÀÌ ¾Æ´Ò ¶§ °ü·ÃµÈ ÄÚµåÀÇ ¸ÞÀÎÅ×À̳ʿ¡ ÀÇÇØ »ç¿ëµÈ´Ù.

Acked-by: is not as formal as Signed-off-by:. It is a record that the acker has at least reviewed the patch and has indicated acceptance. Hence patch mergers will sometimes manually convert an acker's "yep, looks good to me" into an Acked-by:.

Acked-by´Â Signed-off-by°ú °°ÀÌ ¾î¶² °ø½ÄÀûÀÎ °ÍÀº ¾Æ´Ï´Ù. ±×°ÍÀº ack¸¦ ÇÏ´Â »ç¶÷ÀÌ Àû¾îµµ ±× ÆÐÄ¡¸¦ °ËÅäÇÏ¿´À¸¸ç ½ÂÀÎÀ» Çß´Ù´Â °ÍÀ» ³ªÅ¸³»´Â °ÍÀÌ´Ù. ±×·¯¹Ç·Î ÆÐÄ¡¸¦ º´ÇÕÇÏ´Â »ç¶÷Àº(merger) ¶§·Ð Á÷Á¢ ½ÂÀÎÇÑ »ç¶÷ÀÇ "À½, ÁÁ¾Æ º¸ÀÌ´Â °É" °ú °°Àº ¹®±¸¸¦ Acked-by·Î º¯È¯ÇÒ °ÍÀÌ´Ù.

Acked-by: does not necessarily indicate acknowledgement of the entire patch. For example, if a patch affects multiple subsystems and has an Acked-by: from one subsystem maintainer then this usually indicates acknowledgement of just the part which affects that maintainer's code. Judgement should be used here.
When in doubt people should refer to the original discussion in the mailing
list archives.

Acked-by°¡ Àý´ëÀûÀ¸·Î ¸ðµç ÆÐÄ¡¸¦ ½ÂÀÎÇß´Ù´Â °ÍÀ» ÀǹÌÇÏ´Â °ÍÀº ¾Æ´Ï´Ù. ¿¹¸¦ µé¾î ÇϳªÀÇ ÆÐÄ¡°¡ ¿©·¯°³ÀÇ subsystem¿¡ ¿µÇâÀ» ÁÖ°í ÇÑ subsystemÀÇ ¸ÞÀÎÅ×À̳ʷκÎÅ͸¸ Acked-by¸¦ ¹Þ¾Ò´Ù¸é ÀÌ°ÍÀº ´ÜÁö ±× ¸ÞÀÎÅ×À̳ÊÀÇ Äڵ忡 ¿µÇâÀ» ÁÖ´Â ºÎºÐ¸¸À» ½ÂÀι޾Ҵٴ °ÍÀ» ÀǹÌÇÏ´Â °ÍÀÌ´Ù. ÆÇ´ÜÀº ¿©±â¼­ ÇؾßÇÑ´Ù. Àǽɽº·¯¿ì¸é ¸ÞÀϸµ ¸®½ºÆ® ¾ÆÄ«À̺꿡 Åä·ÐµÇ¾ú´ø ¿øº»À» ÂüÁ¶ÇØ¾ß ÇÑ´Ù.


14) The canonical patch format 14) Ç¥ÁØ ÆÐÄ¡ Æ÷¸Ë

The canonical patch subject line is: Ç¥ÁØ ÆÐÄ¡ Á¦¸ñÀº ´ÙÀ½°ú °°´Ù.

Subject: PATCH 001/123 subsystem: summary phrase

The canonical patch message body contains the following: Ç¥ÁØ ÆÐÄ¡ ³»¿ëÀº ´ÙÀ½°ú °°´Ù.

- A "from" line specifying the patch author.
- "from"Àº ÆÐÄ¡ ÀúÀÚ¸¦ ¸í½ÃÇÏ´Â ¶óÀÎÀÌ´Ù.

- An empty line.
- ÇÑ ÁÙÀÇ ºó ¶óÀÎ.

- The body of the explanation, which will be copied to the
permanent changelog to describe this patch.
- ÀÌ ÆÐÄ¡¸¦ ¼³¸íÇÏ´Â changelog¿¡ ¿µ¿øÈ÷ ±â·ÏµÉ ³»¿ë

- The "Signed-off-by:" lines, described above, which will
also go in the changelog.
- À§¿¡¼­ ¼³¸íÇß´ø "Signed-off-by"¶óÀεé, ÀÌ ¶óÀε鵵 changelog¿¡
±â·ÏµÊ

- A marker line containing simply "---".
- °£´ÜÈ÷ "---"¸¦ Æ÷ÇÔÇϴ ǥ½Ã ¶óÀÎ

- Any additional comments not suitable for the changelog.
- changelog¿¡ ¾Ë¸ÂÁö ¾ÊÀº ºÎ°¡ÀûÀÎ ÄÚ¸àÆ®

- The actual patch (diff output).
- ½ÇÁ¦ ÆÐÄ¡(diffÀÇ »êÃâ¹°)

The Subject line format makes it very easy to sort the emails alphabetically by subject line - pretty much any email reader will support that - since because the sequence number is zero-padded, the numerical and alphabetic sort is the same. =======================================================================??? ¿©±îÁö Á¦¸ñ ¶óÀÎ Æ÷¸ËÀº À̸ÞÀÏÀ» Á¦¸ñ ¶óÀο¡ ÀÇÇØ ¾ËÆĺª¼øÀ¸·Î Á¤·ÄÇϱ⠽±°Ô ¸¸µç´Ù. ¸¹Àº À̸ÞÀÏ ¸®´õµéÀÌ ±×·¯ÇÑ °ÍÀ» Áö¿øÇÒ °ÍÀÌ´Ù. ¤±¤¤ÀÌ·¯¤¿À̳Ѹ®¸Ó´Ï ¸µ¤¤¸Ö


The "subsystem" in the email's Subject should identify which area or subsystem of the kernel is being patched. À̸ÞÀÏÀÇ Á¦¸ñ¿¡ "subsystem"Àº Ä¿³ÎÀÇ ¾î¶² ¿µ¿ªÀ̳ª subsystemÀÌ ÆÐÄ¡µÇ°í ÀÖ´ÂÁö¸¦ ±¸ºÐÇØ¾ß ÇÑ´Ù.

The "summary phrase" in the email's Subject should concisely describe the patch which that email contains. The "summary phrase" should not be a filename. Do not use the same "summary phrase" for every patch in a whole patch series (where a "patch series" is an ordered sequence of multiple, related patches).

À̸ÞÀÏÀÇ Á¦¸ñ¿¡ "summary phrase"´Â À̸ÞÀÏÀÌ ´ã°í ÀÖ´Â ÆÐÄ¡¸¦ °£°áÇÏ°Ô ¼³¸íÇØ¾ß ÇÑ´Ù. "summary phrase"´Â ÆÄÀÏÀ̸§ÀÌ µÇ¼­´Â ¾ÈµÈ´Ù. Àüü ÆÐÄ¡ ½Ã¸®Áî¿¡ ¸ðµç ÆÐÄ¡¸¶´Ù °°Àº "summary phrase"¸¦ »ç¿ëÇÏÁö ¸¶¶ó. (¤±¤¤À̶ó¤Ã¹Ì ·¯¤Ó¸Á³Ê¸®¸¸¤©)

Bear in mind that the "summary phrase" of your email becomes a globally-unique identifier for that patch. It propagates all the way into the git changelog. The "summary phrase" may later be used in developer discussions which refer to the patch. People will want to google for the "summary phrase" to read discussion regarding that patch.

¿©·¯ºÐÀÇ À̸ÞÀÏ¿¡ "summary phrase"°¡ ±× ÆÐÄ¡¸¦ ±¸ºÐÇÏ´Â ¼¼°è¿¡¼­ À¯ÀÏÇÑ ½Äº°ÀÚ°Ô µÈ´Ù´Â °ÍÀ» À¯³äÇضó. "summary phrase"´Â ³ªÁß¿¡ ±× ÆÐÄ¡¸¦ ÂüÁ¶ÇÏ´Â °³¹ßÀڵ鰣ÀÇ Åä·Ð¿¡¼­ »ç¿ëµÉ ¼öµµ ÀÖ´Ù. »ç¶÷µéÀº ±× ÆÐÄ¡¿Í °ü·ÃµÈ Åä·Ð ³»¿ëµéÀ» Àбâ À§ÇÏ¿© "summary phrase"¸¦ ±¸±Û¸µ ÇÏ±æ ¿øÇÒ °ÍÀÌ´Ù.

A couple of example Subjects: µÎ°³ÀÇ Á¦¸ñ ¿¹Á¦:
Subject: patch 2/5 ext2: improve scalability of bitmap searching Subject: PATCHv2 001/207 x86: fix eflags tracking

The "from" line must be the very first line in the message body, and has the form: "from"¶óÀÎÀº ¹Ýµå½Ã ³»¿ëÀÇ Ã¹ ¶óÀο¡ À§Ä¡ÇØ¾ß ÇÏ¸ç ´ÙÀ½°ú °°Àº ÇüŸ¦ °¡Á®¾ß ÇÑ´Ù.
From: Original Author <author@example.com> From: Original Author <author@example.com>

The "from" line specifies who will be credited as the author of the patch in the permanent changelog. If the "from" line is missing, then the "From:" line from the email header will be used to determine the patch author in the changelog.

"from"¶óÀÎÀº ¿µ¿øÈ÷ ³²°Ô µÉ changelog¿¡ ÆÐÄ¡ÀÇ ÀúÀÚ·Î½á ´©°¡ ÀÚ¶û½º·´°Ô ¿Ã¶ó°¥ °ÍÀÎÁö¸¦ ¸í½ÃÇÏ´Â °ÍÀÌ´Ù. "from"¶óÀÎÀÌ ¾ø´Ù¸é À̸ÞÀÏ Çì´õÀÇ "From" ¶óÀÎÀÌ changelog¿¡ ÆÐÄ¡ÀÇ ÀúÀڷμ­ ±â·ÏµÉ °ÍÀÌ´Ù.

The explanation body will be committed to the permanent source changelog, so should make sense to a competent reader who has long since forgotten the immediate details of the discussion that might have led to this patch.

³»¿ëÀº ¿µ¿øÇÑ sourceÀÇ changelog¿¡ ³²°Ô µÉ °ÍÀÌ´Ù. ±×·¡¼­ ÀÌ ÆÐÄ¡¸¦ ¤±¤·¤¤¤©;¤Ó¸Á;´Ï¶ó ¤±¤¤ÀÌ;¶ó;¤±¤¤

The "---" marker line serves the essential purpose of marking for patch handling tools where the changelog message ends. "---" Ç¥½Ã ¶óÀÎÀº changelog ³»¿ëÀÌ ³¡³µ´Ù´Â °ÍÀ» ³ªÅ¸³½´Ù.

One good use for the additional comments after the "---" marker is for a diffstat, to show what files have changed, and the number of inserted and deleted lines per file. A diffstat is especially useful on bigger patches. Other comments relevant only to the moment or the maintainer, not suitable for the permanent changelog, should also go here. Use diffstat options "-p 1 -w 70" so that filenames are listed from the top of the kernel source tree and don't use too much horizontal space (easily fit in 80 columns, maybe with some indentation).

"---" Ç¥½Ã ÀÌÈÄ¿¡ ºÎ°¡ÀûÀÎ ÄÚ¸àÆ®µéÀÇ ÁÁÀº ¿¹´Â diffstatÀÌ´Ù. diffstatÀº º¯°æµÈ ÆÄÀϵ鸶´Ù »õ·Î Ãß°¡µÈ ¶óÀΰú »èÁ¦µÈ ¶óÀÎÀ» º¸¿©ÁØ´Ù. diffstat´Â ƯÈ÷ Å« ÆÐÄ¡¿¡ À¯¿ëÇÏ´Ù. ¿µ±¸È÷ ±â·ÏµÇ´Â changelog¿¡´Â ÀûÇÕÇÏÁö ¾ÊÀ¸¸ç ´ÜÁö ±×¶§¿¡¸¸, ȤÀº ¸ÞÀÎÅ×À̳ʿ¡°Ô¸¸ °ü·ÃµÈ ÄÚ¸àÆ®µéÀÌ ÀÌ°÷¿¡ ¿Í¾ß ÇÑ´Ù. diffstat ¿É¼ÇÀ» "-p 1 -w 70" À¸·Î »ç¿ëÇؼ­ ÆÄÀÏ À̸§µéÀÌ Ä¿³Î ¼Ò½º Æ®¸®ÀÇ ¸Ç À§¿¡ ³ª¿­µÇµµ·ÏÇÏ°í ³Ê¹« ¸¹Àº horizontal space¸¦ »ç¿ëÇÏÁö ¸»°Ô Ç϶ó. (´ëÃæ 80°³ÀÇ Ä÷³ÀÌ Àû´çÇÏ¸ç ¾Æ¸¶ ¾à°£ÀÇ µé¿©¾²±â

See more details on the proper patch format in the following references.

¿Ã¹Ù¸¥ ÆÐÄ¡ Æ÷¸Ë¿¡ °üÇÑ ´õ ÀÚ¼¼ÇÑ »çÇ×Àº ´ÙÀ½À» ÂüÁ¶Ç϶ó.


SECTION 2 - HINTS, TIPS, AND TRICKS



SECTION 2 - ÈùÆ®, ÆÁ°ú Æ®¸¯


This section lists many of the common "rules" associated with code submitted to the kernel. There are always exceptions... but you must have a really good reason for doing so. You could probably call this section Linus Computer Science 101.

ÀÌ ¼½¼ÇÀº Ä¿³Î¿¡ Á¦ÃâµÈ ÄÚµå¿Í °ü·ÃµÈ ÀϹÝÀûÀÎ ¸¹Àº "±ÔÄ¢"µéÀ» ³ª¿­ÇÑ´Ù. Ç×»ó ¿¹¿Ü°¡ ÀÖ±ä ÇÏÁö¸¸ ¿©·¯ºÐÀº ¿©·¯ºÐÀº ±×·¸°Ô ÇÑ ÀÌÀ¯¸¦ °¡Áö°í ÀÖ¾î¾ß ÇÑ´Ù. ¾Æ¸¶µµ ¿©·¯ºÐÀº ÀÌ ¼½¼ÇÀ» TODO Linux Computer Science 101À̶ó ºÎ¸¦ °ÍÀÌ´Ù.


1) Read Documentation/CodingStyle

1) Documentation/CodingStyleÀ» Àоî¶ó.

Nuff said. If your code deviates too much from this, it is likely to be rejected without further review, and without comment.

ÃæºÐÈ÷ ¸»Çß´Ù. ¿©·¯ºÐÀÇ Äڵ尡 CodingStyle ¹®¼­¿¡¼­ ¸¹ÀÌ ¹þ¾î³ª°Ô µÇ¸é ´õ ÀÌ»óÀÇ °ËÅ䳪 ÄÚ¸àÆ®¾øÀÌ °ÅÀýµÉ °ÍÀÌ´Ù.

One significant exception is when moving code from one file to another -- in this case you should not modify the moved code at all in the same patch which moves it. This clearly delineates the act of moving the code and your changes. This greatly aids review of the actual differences and allows tools to better track the history of the code itself.

ÇÑ°¡Áö È®½ÇÇÑ ¿¹¿Ü´Â ÇÑ ÆÄÀÏ¿¡¼­ ´Ù¸¥ ÆÄÀÏ·Î Äڵ带 ¿Å±æ ¶§ÀÌ´Ù. ÀÌ·± °æ¿ì ¿©·¯ºÐÀº ¿Å±â´Â ÄÚµåÀÇ ³»¿ëÀ» Àý´ë º¯°æÇÏÁö ¸»¾Æ¾ß ÇÑ´Ù. TODO ÀÌ·¸°Ô ÇÏ´Â °ÍÀº Äڵ带 ´ÜÁö ¿Å±â¸ç ¼öÁ¤ÇÏ´Â ¿©·¯ºÐÀÇ Àǵµ¸¦ ±×´ë·Î ³ªÅ¸³½´Ù. ÀÌ·¸°Ô ÇÏ´Â °ÍÀº ½ÇÁ¦ º¯°æµÈ ³»¿ë¸¸À» °ËÅäÇÒ ¼ö ÀÖµµ·Ï µµ¿ÍÁÖ´Â °ÍÀÌ¸ç ´Ù¸¥ µµ±¸µé·Î ÄÚµåÀÇ º¯°æ³»¿ëµéÀ» ´õ ÃßÀûÇϱâ ÁÁ°Ô ¸¸µç´Ù.

Check your patches with the patch style checker prior to submission (scripts/checkpatch.pl). The style checker should be viewed as a guide not as the final word. If your code looks better with a violation then its probably best left alone.

¿©·¯ºÐÀÇ ÆÐÄ¡¸¦ Á¦Ãâ Àü¿¡ ÆÐÄ¡ ½ºÅ¸ÀÏ Ã¼Ä¿·Î üũÇ϶ó.(scripts/checkpatch.pl) ½ºÅ¸ÀÏ Ã¼Ä¿´Â ÃÖÁ¾º»ÀÌ ¾Æ´Ñ ´ÜÁö ¾È³»ÀÚ·Î ºÁ¾ß ÇÑ´Ù. ¿©·¯ºÐÀÇ Äڵ尡 Á» À§¹ÝÀ» Çß´õ¶óµµ ´õ ÁÁ¾Æº¸ÀÎ´Ù¸é ±×°ÍÀ» ³²°Ü ³õ´Â °ÍÀÌ ¾Æ¸¶ ´õ ÀßÇÏ´Â ÀÏÀÏ °ÍÀÌ´Ù.

The checker reports at three levels:

üĿ´Â 3°¡Áö ·¹º§·Î º¸°íÇÑ´Ù.

- ERROR: things that are very likely to be wrong - WARNING: things requiring careful review - CHECK: things requiring thought

- ERROR : ³ªºüÁú °Í °°Àº Ç׸ñ - WARNING : ¼¼½ÉÇÑ °ËÅä°¡ ÇÊ¿äÇÑ Ç׸ñ - CHECK : »ý°¢Çغ¼ Ç׸ñ

You should be able to justify all violations that remain in your patch.

¿©·¯ºÐÀº ¿©·¯ºÐÀÇ ÆÐÄ¡¿¡ ³²¾Æ ÀÖ´Â ¸ðµç À§¹Ý»çÇ×À» Á¤´çÈ­ ½Ãų ¼ö ÀÖ¾î¾ß ÇÑ´Ù.

2) #ifdefs are ugly

2) #ifdefsÀº ÁÁÁö¾Ê´Ù.

Code cluttered with ifdefs is difficult to read and maintain. Don't do it. Instead, put your ifdefs in a header, and conditionally define 'static inline' functions, or macros, which are used in the code. Let the compiler optimize away the "no-op" case.

ifdef·Î ¾îÁö·´ÇôÁ® ÀÖ´Â ÄÚµå´Â Àаí À¯Áöº¸¼öÇϱⰡ ¾î·Æ´Ù. ±×·¸°Ô ÇÏÁö¸¶¶ó. ´ë½Å¿¡ ¿©·¯ºÐÀÇ ifdefµéÀ» ÇϳªÀÇ Çì´õ·Î ³Ö°í Á¶°Ç¿¡ µû¶ó 'static inline'ÇÔ¼ö³ª ¸ÅÅ©·Î·Î µÎ¾î¶ó. ÄÄÆÄÀÏ·¯°¡ "no-op"ÀÇ °æ¿ì¸¦ ÃÖÀûÇÏÇÏ¿© ¾ø¾Ö¹ö¸®µµ·Ï ÇÏÀÚ.

Simple example, of poor code:

dev = alloc_etherdev (sizeof(struct funky_private)); if (!dev)
return -ENODEV;
#ifdef CONFIG_NET_FUNKINESS init_funky_net(dev); #endif

Cleaned-up example:

(in header)
#ifndef CONFIG_NET_FUNKINESS static inline void init_funky_net (struct net_device *d) {} #endif

(in the code itself)
dev = alloc_etherdev (sizeof(struct funky_private)); if (!dev)
return -ENODEV;
init_funky_net(dev);



3) 'static inline' is better than a macro

3) 'static inline'Àº ¸ÅÅ©·Îº¸´Ù ´õ ¼±È£µÈ´Ù.

Static inline functions are greatly preferred over macros. They provide type safety, have no length limitations, no formatting limitations, and under gcc they are as cheap as macros.

Static inline ÇÔ¼öµéÀÌ ¸ÅÅ©·Îº¸´Ù´Â ÈξÀ ¼±È£µÈ´Ù. Static inline ÇÔ¼öµéÀº Çü ¾ÈÁ¤¼º(type safety)À» Á¦°øÇÏ¸ç ¾î¶² ±æÀÌÁ¦ÇÑÀ̳ª Çü½Ä Á¦Çѵµ ÀÖÁö ¾ÊÀ¸¸ç gccÀÇ °æ¿ì ¸ÅÅ©·Î¸¸Å­À̳ª °¡º±´Ù.

Macros should only be used for cases where a static inline is clearly suboptimal there a few, isolated cases of this in fast paths, or where it is impossible to use a static inline function [such as string-izing].

¸ÅÅ©·ÎµéÀº static inlineÀÌ ºÐ¸íÈ÷ suboptimalTODO ÇÒ °æ¿ì³ª static inline ÇÔ¼ö¸¦ »ç¿ëÇÒ ¼ö ¾ø´Â °æ¿ì¿¹¸¦µé¾î ¹®ÀÚ¿­È­(string-izing)¿¡¸¸ »ç¿ëµÇ¾îÁ®¾ß ÇÑ´Ù.

'static inline' is preferred over 'static inline', 'extern inline', and 'extern inline'.

'staic inline'ÀÌ 'static inline', 'extern inline', 'extern inline'º¸´Ù ¼±È£ µÈ´Ù.


4) Don't over-design.

4) ³Ê¹« ¸Ö¸® º¸´Â ¼³°è´Â ÇÇÇÏÀÚ.

Don't try to anticipate nebulous future cases which may or may not be useful: "Make it as simple as you can, and no simpler."

À¯¿ëÇÏ°Ô µÉÁö, ±×·¸Áö ¾ÊÀ» Áöµµ ¸ð¸£´Â ºÒÈ®½ÇÇÑ ¹Ì·¡¸¦ ¿¹ÃøÇÏ·Á°í ½ÃµµÇÏÁö ¸¶¶ó. "ÇÒ¼ö ÀÖ´Â ÇÑ ÃÖ´ëÇÑ °£´ÜÇÏ°Ô ¸¸µé¾î¶ó."




SECTION 3 - REFERENCES


Andrew Morton, "The perfect patch" (tpp). Jeff Garzik, "Linux kernel patch submission format". Greg Kroah-Hartman, "How to piss off a kernel subsystem maintainer". NO!!!! No more huge patch bombs to linux-kernel@vger.kernel.org people! Kernel Documentation/CodingStyle: Linus Torvalds's mail on the canonical patch format:

ID
Password
Join
You have an ambitious nature and may make a name for yourself.


sponsored by andamiro
sponsored by cdnetworks
sponsored by HP

Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2015-08-28 16:10:29
Processing time 0.0252 sec