From 84e1755ec31289aa7d23f204aeb448421acf3e9c Mon Sep 17 00:00:00 2001 From: TJ Date: Fri, 29 Oct 2010 13:53:15 +0100 Subject: [PATCH] Add formal declaration SOURCE, SOURCE_* to provide attributions for sources of chip-set and device specific settings and values. See README for how to use attributions and why they are necessary. --- README | 25 +++++++++++++++++++++++++ arch/msm7x30-init.S | 8 ++++++++ 2 files changed, 33 insertions(+) diff --git a/README b/README index 53b8b92..35c0258 100644 --- a/README +++ b/README @@ -11,3 +11,28 @@ system manufacturers and user's who prefer to install a custom boot-loader. Inspired by the HTC Vision device, known as the HTC Desire Z and T-Mobile G2. This device was locked by HTC to prevent easy customisation. + += Developer Notes = + +Gathering the chip-set specifications for some parts of this code can be challenging. Prudent use of +a search engine can uncover many fragments of open-source code patches to many Linux kernel projects +for embedded devices. + +To guard against any possible challenge as to the source of specifications and settings that +aren't publicly released by chip-set or device manufacturers there is a comment template to prefix +to any code that describes or uses those specifications or settings. Here's an example: + +/* + SOURCE: HTC Vision Linux kernel 2.6.32 source + SOURCE_FILE: arch/arm/mach-msm/arch-init-7x30.S + SOURCE_URL: http://dl3.htc.com/RomCode/Source_and_Binaries/vision-2.6.32-g814e0a1.tar.gz + SOURCE_FOR: MSM7x30 equates, status-codes, IOMEM addresses, CP15 functions +*/ + +... some code + +/* SOURCE_END */ + +By using pseudo-defines (SOURCE, SOURCE_*, SOURCE_END) inside a C-style comment block (/* ... */) it +makes it possible to use an automated tool to gather and document all sources of specifications and +settings. diff --git a/arch/msm7x30-init.S b/arch/msm7x30-init.S index 455af61..500f100 100644 --- a/arch/msm7x30-init.S +++ b/arch/msm7x30-init.S @@ -19,6 +19,12 @@ #include +/* + SOURCE: HTC Vision Linux kernel 2.6.32 source + SOURCE_FILE: arch/arm/mach-msm/arch-init-7x30.S + SOURCE_URL: http://dl3.htc.com/RomCode/Source_and_Binaries/vision-2.6.32-g814e0a1.tar.gz + SOURCE_FOR: MSM7x30 equates, status-codes, IOMEM addresses, CP15 functions +*/ #define DSB .byte 0x4f, 0xf0, 0x7f, 0xf5 #define ISB .byte 0x6f, 0xf0, 0x7f, 0xf5 @@ -89,6 +95,8 @@ .equ L2VR3F1_110, 0x00FCFC60 .equ L2VR3F1_111, 0x00FCFC40 +/* SOURCE_END */ + .section ".start", #alloc, #execinstr ENTRY(__init_msm_7x30) mov r4,#0 -- 2.17.1