Here are some extra techniques you can use when masking a layer or adjustment layer.
While masking or erasing, right-clicking the mouse causes a context window of parameter settings of the brush, and includes additional controls for pen pressure sensitivity.
For handy reference, in the Layers panel on the upper right side of the Side Panel, you’ll see a thumbnail image of the current mask.
To quickly switch between Paint and Erase modes, use a shortcut key X.
To quickly change the Diameter of the brush, use the shortcut keys [ and ]. This is very convenient and greatly speeds up brush work.
To quickly change the Softness of the brush, use the shortcut keys Shift + [ and Shift + ].
If you hold down the space bar in Painting mode you can switch to Move the image mode. This is very convenient when zoomed in for detailed brush strokes.