History log of /linux-master/Documentation/translations/zh_CN/process/coding-style.rst
Revision Date Author Comments
# 932be49b 02-Feb-2024 Thorsten Blum <thorsten.blum@toblux.com>

Documentation: coding-style: Fix indentation in code-blocks

- Remove spaces in C code-blocks to align error labels consistently
- Replace tab characters with spaces in emacs-lisp code blocks

Signed-off-by: Thorsten Blum <thorsten.blum@toblux.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Link: https://lore.kernel.org/r/20240202231316.7606-1-thorsten.blum@toblux.com


# 54156734 29-Aug-2022 Wu XiangCheng <bobwxc@email.cn>

docs/zh_CN: Update zh_CN/process/coding-style.rst to 6.0-rc2

* update to commit c04639a7d2fb ("coding-style.rst: trivial: fix
location of driver model macros")

Signed-off-by: Wu XiangCheng <bobwxc@email.cn>
Reviewed-by: Yanteng Si <siyanteng@loongson.cn>
Reviewed-by: Alex Shi <alexs@kernel.org>
Link: https://lore.kernel.org/r/Yw2ewM4wfaDDLjTk@bobwxc.mipc
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# 341968c6 03-Jul-2021 Hu Jialun <hujialun@comp.nus.edu.sg>

docs/zh_CN: Remove the Microsoft rhetoric

Update Chinese translation on par with original English coding-style.rst
Related commit b7592e5b82db19b72a34b471f3296ad3f651c8b9

Signed-off-by: Hu Jialun <hujialun@comp.nus.edu.sg>
Reviewed-by: Hu Haowen <src.res@email.cn>
Link: https://lore.kernel.org/r/20210703164834.460447-1-hujialun@comp.nus.edu.sg
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# cc3496bf 15-May-2021 Wei Ming Chen <jj251510319013@gmail.com>

docs: Use fallthrough pseudo-keyword

Replace /* fall through */ comment with fallthrough, make
it align with original process/coding-style.rst

Signed-off-by: Wei Ming Chen <jj251510319013@gmail.com>
Link: https://lore.kernel.org/r/20210515155142.2490-1-jj251510319013@gmail.com
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# cf37fc4a 08-Jun-2020 Alexander A. Klimov <grandmaster@al2klimov.de>

Replace HTTP links with HTTPS ones: Documentation/translations/zh_CN

Rationale:
Reduces attack surface on kernel devs opening the links for MITM
as HTTPS traffic is much harder to manipulate.

Deterministic algorithm:
For each file:
For each line:
If doesn't contain `\bxmlns\b`:
For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:
If both the HTTP and HTTPS versions
return 200 OK and serve the same content:
Replace HTTP with HTTPS.

Signed-off-by: Alexander A. Klimov <grandmaster@al2klimov.de>
Reviewed-by: Alex Shi <alex.shi@linux.alibaba.com>
Link: https://lore.kernel.org/r/20200608181649.74883-1-grandmaster@al2klimov.de
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# c593642c 09-Dec-2019 Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>

treewide: Use sizeof_field() macro

Replace all the occurrences of FIELD_SIZEOF() with sizeof_field() except
at places where these are defined. Later patches will remove the unused
definition of FIELD_SIZEOF().

This patch is generated using following script:

EXCLUDE_FILES="include/linux/stddef.h|include/linux/kernel.h"

git grep -l -e "\bFIELD_SIZEOF\b" | while read file;
do

if [[ "$file" =~ $EXCLUDE_FILES ]]; then
continue
fi
sed -i -e 's/\bFIELD_SIZEOF\b/sizeof_field/g' $file;
done

Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
Link: https://lore.kernel.org/r/20190924105839.110713-3-pankaj.laxminarayan.bharadiya@intel.com
Co-developed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: David Miller <davem@davemloft.net> # for net


# cd238eff 12-Jun-2019 Mauro Carvalho Chehab <mchehab+samsung@kernel.org>

docs: kbuild: convert docs to ReST and rename to *.rst

The kbuild documentation clearly shows that the documents
there are written at different times: some use markdown,
some use their own peculiar logic to split sections.

Convert everything to ReST without affecting too much
the author's style and avoiding adding uneeded markups.

The conversion is actually:
- add blank lines and identation in order to identify paragraphs;
- fix tables markups;
- add some lists markups;
- mark literal blocks;
- adjust title markups.

At its new index.rst, let's add a :orphan: while this is not linked to
the main index.rst file, in order to avoid build warnings.

Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# 5e3ec254 02-Apr-2019 Jonathan Corbet <corbet@lwn.net>

docs: Fix a build error in coding-style.rst

A reference typo caused an unsightly build error; fix it.

Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# efd298e4 01-Apr-2019 Alex Shi <alex.shi@linux.alibaba.com>

docs/zh_CN: update coding-sytle.rst

Replace the disclaimer part and give the link name of this file:
cn_codingsytle.

Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Harry Wei <harryxiyou@gmail.com>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Bart Van Assche <bvanassche@acm.org>
Cc: linux-doc@vger.kernel.org
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Jonathan Corbet <corbet@lwn.net>


# aa3b3690 13-Mar-2019 Alex Shi <alex.shi@linux.alibaba.com>

docs/zh_CN: move process related docs into process dir

Much process documents spread here isn't neat. It's good to put them together
in their directory: process

So create 'process' directory and move docs:
email-clients stable_kernel_rules stable_api_nosense
submittingpatches submittingdrivers HOWTO
volatile-considered-harmful
there.

Signed-off-by: Alex Shi <alex.shi@linux.alibaba.com>
Cc: Li Zefan <lizefan@huawei.com>
Cc: Shawn Guo <shawn.guo@linaro.org>
Cc: Fengguang Wu <fengguang.wu@intel.com>
Cc: Harry Wei <harryxiyou@gmail.com>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Coly Li <colyli@suse.de>
Signed-off-by: Weiwei Jia <harryxiyou@gmail.com>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>