Sorry, but yabu.
You had no right to look at your husbands phone and what he does in his downtime is none of your business.
I understand you may be annoyed at him, but putting a childlock on his phone though initially satisfying will not address the root of your anger.
So, be honest with yourself: is it the porn that's bothering you? If yes, it's tricky. Think about your objections to porn. Why does it bother you and what would you like your husband to do about it? Then have a calm conversation about it.
If your husband is massively into porn, he may not agree to stop watching it. So consider your options, if he refuses (or say "yes" to appease you and carry on as before).
Or is it the time he spends doing watching porn. Why does that bother you? Is it because you think he could fill his time with worthier pursuits or is he simply not pulling his weight and watching porn instead?
If it's the first: suck it up. You don't get to control your husbands downtime. If he is not pulling his weight, it's back to having a grown-up conversation. No need to even mention the porn. Not taking part in the running of the household is shitty whatever you fill your time with instead.
Having said that: if you can, remove the lock now before husband notices. Nothing is worth that fall-out.
If he has it back, apologise, explain and grovel (yes, it's you who fucked up - not him) and maybe even use it as an opportunity to start a conversation about what's really bothering you.
Just for illustration: my partner has left The house at 9 this morning, I don't have to leave until 1.30pm. I relish the the time in which I have the place to myself as does he (i'm coming back later). This morning I have drunk the coffee so brought me before leaving, fed the cats and wasted time on my phone. I'd be incredibly unimpressed if my DP tried to control this time. If he had snooped on my phone and put a childlock (or similar) on my phone I would seriously consider leaving.