Trisodium phosphate (TSP) is generally available as a white granular powder. It is a very powerful degreaser and cleanser that is usually used to clean walls prior to painting. TSP is widely available in painting supply or larger home improvement stores. It makes a very basic solution; the pH of a 1 percent solution of trisodium phosphate is 12.
You can use a trisodium phosphate solution to remove both smoke stains and the lingering smell of smoke. The power of trisodium phosphate lies in its ability to break up oils and other compounds that are insoluble in water. This saponification allows the solution to easily remove the smoke stain. It also helps to eliminate the bleed-through of any permanent stains through new coats of paint.
Trisodium phosphate's caustic nature makes it somewhat dangerous to the unwary user. TSP should not be used without adequate protective gear. A face mask and clothes that cover most of the body are highly recommended. Gloves, sturdy footwear and safety goggles as well as a head covering are also necessary to protect from inadvertent drips from the ceiling. Any spills on the body should be rinsed immediately with running water. If inadvertently swallowed, do not induce vomiting. Contact 911 and Poison Control immediately.
If TSP is not a viable option, there are other options that are not as effective but may handle your stains. You can remove soot with a chemically-treated sponge. Magic eraser cleaning sponges can be used on small areas. A weak ammonia or washing soda solution might remove your smoke stains. Though they are also caustic, ammonia and washing soda are much milder than TSP; however, this also makes them much less effective. As a last resort, you can hire a professional restoration service.