The one with the slotted adjustment screw is the oil pressure relief/regulator valve. It opens when the oil pressure goes too high (around 70 psi) and allows some oil to flow back into the pan.
The other one is the bypass valve, which opens when the filter gets clogged and allows oil into the engine galleries without going through the filter. ISTR it is supposed to open around 8 psi.