I solved it in the following way, just want make sure I'm not missing something obvious:.
Set up a portfolio PF$PF$ consisting of long S$S$ and short P$P$ at time t = 0$t = 0$. Choose arbitrary time 0 < t < T$0 < t < T$. If S_t > P_t$S_t > P_t$ then PF_t = S_t - P_t$PF_t = S_t - P_t$ which coincides with the value of the option. If S_t$S_t$ hits P_t$P_t$ from above, then dissolve the portfolio by selling S$S$ and buying P$P$. Again both the portfolio PF$PF$ and the option have the same value 0 in this case.
So we have a self-financing portfolio which has the same payoff at time T$T$ as the option. So the option value at t=0$t=0$ must be the same as the portfolio value in the absence of arbitrage, i.e. option value is S_0 - P_0$S_0 - P_0$.