You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 637c4f6
Browse filesBrowse the repository at this point in the historyBrowse files
David Tadokoro
committed
paper: make citation to figures and listings in the text
Signed-off-by: David Tadokoro <davidbtadokoro@usp.br>
Copy file name to clipboardExpand all lines: paper/paper.md
+32-20Lines changed: 32 additions & 20 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -34,11 +34,11 @@ On a broader scope, the Kworkflow (`kw`) project [@kw-sbes-tools] is a hub of to
34
34
35
35
# Introduction
36
36
37
-
The development of the Linux kernel is a prominent example of a large-scale Free Software project. Dozens of subsystems and thousands of contributors have allowed Linux to continue evolving for decades, making it the foundation of most modern computing systems. The project follows a rigorous review and integration process before a contribution, also known as a _patch_, can reach the software's end users.
37
+
The development of the Linux kernel is a prominent example of a large-scale Free Software project. Dozens of subsystems interconnected in a complex _web of trust_ (Figure \ref{patchset-lifecycle}) and thousands of contributors have allowed Linux to continue evolving for decades, making it the foundation of most modern computing systems. The project follows a rigorous review and integration process before a contribution, also known as a _patch_, can reach the software's end users.
38
38
39
39
In general, kernel development involves many repetitive tasks, both for contributors who seek to have their code incorporated and for maintainers who must ensure the high quality of the contribution. Among these tasks, we emphasize compiling, running, and testing the Linux kernel, as well as organizing, sending, and responding to patches. In practice, this translates to executing long sequences of verbose commands, which waste considerable time to type, are incredibly error-prone, and must be repeated multiple times throughout the development and review of contributions.
40
40
41
-

41
+

42
42
43
43
Due to the repetitive nature of these tasks, it is common for kernel developers to create or adopt ad hoc scripts to automate such processes, thereby speeding up execution and reducing the likelihood of errors. As a result, this tooling is generally decentralized, leading to duplicated efforts and contributing to the lack of robust standardized solutions for some of these tasks.
44
44
@@ -60,33 +60,33 @@ It is worth noting that the project remains in continuous development, and some
60
60
61
61
### Integration with Linux development mailing lists
62
62
63
-

63
+

64
64
65
-
Users can browse the mailing lists of each subsystem available on lore.kernel.org. For each list, users can navigate through the submitted patches, clustered in their respective patchsets, from most recent to oldest, and analyze each one individually.
65
+
Users can browse the mailing lists of each subsystem available on lore.kernel.org (Figure \ref{mailing-lists-screen}). For each list, users can navigate through the submitted patches, clustered in their respective patchsets, from most recent to oldest, as shown in Figure \ref{latest-screen}. Each patchset can be analyzed individually, as described in the next feature.
66
66
67
-

67
+

68
68
69
69
### Patchset rendering
70
70
71
-
For every patchset, users can view its metadata, which includes the title, author, patchset version, and the number of _Reviewed-by_, _Tested-by_, and _Acked-by_ tags it has received. Users can also inspect each individual patch within the patchset, as well as the patchset's cover letter. For each patch, the commit message and the _code diff_ can be viewed using different renderers for syntax highlighting and colorization. This approach enables users to track the current review state of each patch and conduct their own review efficiently, without the need to set up tools like `mutt` and perform manual integrations with Lore.
71
+
For every patchset, users can view its metadata, which includes the title, author, patchset version, and the number of _Reviewed-by_, _Tested-by_, and _Acked-by_ tags it has received. Users can also inspect each individual patch within the patchset, as well as the patchset's cover letter. For each patch, the commit message and the _code diff_ can be viewed using different renderers for syntax highlighting and colorization. This approach enables users to track the current review state of each patch and conduct their own review efficiently, without the need to set up tools like `mutt` and perform manual integrations with Lore. This screen is shown in Figure \ref{patchset-rendering-screen}.
72
72
73
-

73
+

74
74
75
75
### Patchset management
76
76
77
77
Beyond simply viewing patchsets, users can actively interact with them. Three main actions are supported:
78
78
79
79
1. Bookmark a patchset to access it later.
80
-
2. Apply the patchset to a local kernel tree to validate and test the proposed changes.
80
+
2. Apply the patchset to a local kernel tree to validate and test the proposed changes (Figure \ref{apply-screen}).
81
81
3. Reply to a patchset (or individual patches in a patchset) with a _Reviewed-by_ tag, to indicate endorsement of the contribution.
82
82
83
-

83
+

84
84
85
85
### Custom configuration
86
86
87
-
Another important feature is the ability to customize specific system settings. The main options include (i) selecting the tool to be used for rendering patchsets, (ii) configuring the number of patchsets displayed per page, (iii) defining directories for data and cache storage, and (iv) setting log retention periods. Users can also configure integration with Git commands, such as `git send-email` for replying to patchsets and `git am` for applying a patchset to the local kernel tree. This strategy ensures that the review and application workflow can be tailored to each user's preferences.
87
+
Another important feature is the ability to customize specific system settings within `patch-hub` itself, as displayed in Figure \ref{config-screen}. The main options include (i) selecting the tool to be used for rendering patchsets, (ii) configuring the number of patchsets displayed per page, (iii) defining directories for data and cache storage, and (iv) setting log retention periods. Users can also configure integration with Git commands, such as `git send-email` for replying to patchsets and `git am` for applying a patchset to the local kernel tree. This strategy ensures that the review and application workflow can be tailored to each user's preferences.
@@ -101,7 +101,7 @@ We developed the core of the application following the _Model–View–Controlle
101
101
102
102
#### Model
103
103
104
-
Practically speaking, `patch-hub` defines a struct named `App`, which implements the Model layer. In summary, it contains:
104
+
Practically speaking, `patch-hub` defines a struct named `App` (Listing 1), which implements the Model layer. In summary, it contains:
105
105
106
106
- A `CurrentScreen` attribute, indicating the application’s active screen.
107
107
- One struct for each possible screen the user can access (`MailingListSelection`, `BookmarkedPatchsets`, `LatestPatchsets`, `DetailsActions`, `EditConfig`).
@@ -120,16 +120,19 @@ pub struct App {
120
120
pubconfig:Config,
121
121
publore_api_client:BlockingLoreAPIClient,
122
122
123
-
/// other less relevant attributes omitted
123
+
/// other less relevant attributes omitted
124
124
}
125
125
```
126
-
Listing 1: `App` struct snippet.
126
+
127
+
\begin{center}
128
+
\textbf{Listing 1:} `App` struct snippet.
129
+
\end{center}
127
130
128
131
As expected, the Model layer does not handle either end of the application, user interaction, or terminal rendering, but only the core logic of the system. The `App` struct is responsible for storing each screen’s state, the loaded patchsets, configuration data, and for orchestrating transitions between states. However, it does not directly handle user input or screen rendering.
129
132
130
133
#### View
131
134
132
-
Since `patch-hub` is a TUI, the View layer focuses on rendering each screen in the terminal. Concretely, whenever a state change occurs, the terminal is redrawn with the relevant information for the user, via the `draw_ui()` function. This function retrieves the current screen from the `App` and renders it according to its definition and current state. To draw widgets, `patch-hub` utilizes the Rust library Ratatui, which provides definitions for colors, alignments, geometric shapes, and other UI components.
135
+
Since `patch-hub` is a TUI, the View layer focuses on rendering each screen in the terminal. Concretely, whenever a state change occurs, the terminal is redrawn with the relevant information for the user, via the `draw_ui()` function, as shown in Listing 2. This function retrieves the current screen from the `App` and renders it according to its definition and current state. To draw widgets, `patch-hub` utilizes the Rust library Ratatui, which provides definitions for colors, alignments, geometric shapes, and other UI components.
133
136
134
137
Besides rendering individual screens, some UI components, such as loading screens and pop-up windows, can appear across multiple views. Their rendering behavior is also handled within the View layer.
\textbf{Listing 2:} `draw\_ui()` function snippet.
172
+
\end{center}
167
173
168
174
The View layer is unaware of how information is stored or which user interactions have led to the current state. It only needs the current state to decide how to compose and display the interface elements.
169
175
170
176
#### Controller
171
177
172
-
The Controller layer coordinates the chain of operations triggered by user actions. In general, it captures keyboard events and routes them to their corresponding actions, which typically involve updating the App (Model) and then redrawing the screen (View). Each screen has its own event handler, and whenever a user action causes a screen transition, the corresponding handler function is invoked.
178
+
The Controller layer coordinates the chain of operations triggered by user actions. In general, it captures keyboard events and routes them to their corresponding actions (illustrated in Listing 3), which typically involve updating the App (Model) and then redrawing the screen (View). Each screen has its own event handler, and whenever a user action causes a screen transition, the corresponding handler function is invoked.
173
179
174
180
Thus, the Controller directly interacts with both the Model and the View, orchestrating their operation at a high level.
175
181
@@ -190,7 +196,10 @@ match key.code {
190
196
latest_patchsets.select_above_patchset();
191
197
}
192
198
```
193
-
Listing 3: Example of Key-to-action routing.
199
+
200
+
\begin{center}
201
+
\textbf{Listing 3:} Example of Key-to-action routing.
202
+
\end{center}
194
203
195
204
### Lore API
196
205
@@ -202,7 +211,7 @@ The HTTP client is represented by the `BlockingLoreAPIClient` struct, which is r
202
211
203
212
We implemented three primary endpoints to provide all the information patch-hub needs about patches from lore.kernel.org:
204
213
205
-
-**request_available_lists**: returns all mailing lists of kernel subsystems available on lore.kernel.org;
214
+
-**request_available_lists**: returns all mailing lists of kernel subsystems available on lore.kernel.org. Listing 4 displays its implementation;
206
215
207
216
-**request_patch_feed**: given a mailing list, returns the list of patchsets it contains;
0 commit comments