Create a layer.
Draw the shape that you want to be a mask.
Create another new layer above that one.
Then hold ALT while moving the mouse pointer BETWEEN the 2 layers and you'll see the icon change.
Now whatever you draw on the newest layer, it'll be restricted to the shape of the one below.
Create a new layer.
Where you clicked the new layer icon on the layers palette / window, you'll see an icon that looks like a rectangle with a circle in the centre.
Click that while on the new layer.
This adds a layer mask to that layer.
Now, make sure the layer mask is selected for the layer.
Select BLACK colour to draw and hide parts of the layer.
WHITE colour shows parts of the layer.