"It is better, if it is God's will, to suffer for doing good than for doing evil." NIV translation
Do you ever get the feeling that, no matter what you do, there will be someone who isn't happy with you? Peter is talking about that and saying that, since there will be people that don't like your actions either way, you may as well be disliked for doing good things rather than bad things. At least God will be pleased with you if you are doing good things (things that glorify Him).
"For Christ died for sins once for all, the righteous for the unrighteous, to bring you to God." NIV translation
Peter reminds us here that we are bought and paid for by the death of Jesus Christ.
He has called us to do good things to glorify God and, since he bought us, we are to follow His instructions.
"He was put to death in the body but made alive by the Spirit, through whom also he went and preached to the spirits in prison who disobeyed long ago when God waited patiently in the days of Noah while the ark was being built." NIV translation
What a picture of God's grace and mercy we see in this passage. This passage speaks of the events after Jesus died on the cross and before He rose again. This describes how the Spirit went and preached the message of salvation to those that had already died but had not had the opportunity to hear that Jesus died for their sins. They had been able to see the man made ark being built that would rescue the people from judgment and had not believed but now they got to hear about the spiritual ark which is Jesus Christ. Those that believed were saved just as we are through faith and taken to be with Jesus in Paradise. Those that did not will remain in that place until the final judgment described in the book of Revelation.